[Scummvm-git-logs] scummvm master -> 313c3ef89a71643ec054cae94b30ebb70bbaa969

antoniou79 noreply at scummvm.org
Wed May 25 10:43:55 UTC 2022


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
313c3ef89a HDB: Comment out the modify controls button


Commit: 313c3ef89a71643ec054cae94b30ebb70bbaa969
    https://github.com/scummvm/scummvm/commit/313c3ef89a71643ec054cae94b30ebb70bbaa969
Author: antoniou79 (a.antoniou79 at gmail.com)
Date: 2022-05-25T13:26:46+03:00

Commit Message:
HDB: Comment out the modify controls button

This was uncommented in previous commit for testing and was kept by mistake

In this commit, some of the functions for the modify controls screen are not implemented at a basic level. The modify controls screen is just a picture, but other than the remapping of keys, which would need more work to implement and probably synch with the ScummVM keymapped, it contains useful info on how the game controls work.

Changed paths:
    engines/hdb/menu.cpp
    engines/hdb/menu.h


diff --git a/engines/hdb/menu.cpp b/engines/hdb/menu.cpp
index 8649ead337c..e394e7b8fce 100644
--- a/engines/hdb/menu.cpp
+++ b/engines/hdb/menu.cpp
@@ -720,7 +720,7 @@ void Menu::drawMenu() {
 			_menuBackoutGfx->drawMasked(_backoutX, _backoutY);
 
 			// Ignore Controls Screen Button
-			_controlButtonGfx->drawMasked(centerPic(_controlButtonGfx), _mControlsY);
+			//_controlButtonGfx->drawMasked(centerPic(_controlButtonGfx), _mControlsY);
 		} else if (_optionsScreenId == kOptionsScreenModifyControls) {
 			//
 			// Draw CONTROLS screen
@@ -1427,7 +1427,7 @@ void Menu::processInput(int x, int y) {
 		// Controls screen
 		//
 		if (_optionsScreenId == kOptionsScreenModifyControls) {
-			controlsInput(x, y);
+			controlsInput(x, y, xit);
 			return;
 		}
 
@@ -1628,10 +1628,17 @@ void Menu::processInput(int x, int y) {
 	}
 }
 
-void Menu::controlsInput(int x, int y) {
+void Menu::controlsInput(int x, int y, int xit) {
+	if (y >= _menuExitY || y < _menuExitYTop || xit) {
+		_optionsScreenId = kOptionsScreenMain;
+		_clickDelay = 20;
+		g_hdb->_sound->playSound(SND_MENU_BACKOUT);
+	}
 }
 
 void Menu::controlsDraw() {
+	_controlsGfx->drawMasked(centerPic(_controlsGfx), _oBannerY);
+	_menuBackoutGfx->drawMasked(_backoutX, _backoutY);
 }
 
 void Menu::drawNebula() {
diff --git a/engines/hdb/menu.h b/engines/hdb/menu.h
index de8e6025111..a6887b29230 100644
--- a/engines/hdb/menu.h
+++ b/engines/hdb/menu.h
@@ -86,7 +86,7 @@ public:
 	void freeMenu();
 
 	void processInput(int x, int y);	// this is where the items are clicked!
-	void controlsInput(int x, int y);	// take mouse input and pass through to menu
+	void controlsInput(int x, int y, int xit); // take mouse input and pass through to menu
 	void controlsDraw();
 	void drawNebula();
 	void drawRocketAndSelections();		// draw the background stuff




More information about the Scummvm-git-logs mailing list