[Scummvm-git-logs] scummvm master -> 3304c829c2c77f1eea2b65aeae8d3c9bc9289161
dreammaster
noreply at scummvm.org
Mon Jan 15 19:30:37 UTC 2024
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:
3304c829c2 M4: RIDDLE: Fix clicking menu buttons
Commit: 3304c829c2c77f1eea2b65aeae8d3c9bc9289161
https://github.com/scummvm/scummvm/commit/3304c829c2c77f1eea2b65aeae8d3c9bc9289161
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2024-01-15T11:30:26-08:00
Commit Message:
M4: RIDDLE: Fix clicking menu buttons
Changed paths:
engines/m4/riddle/rooms/section4/room494.cpp
diff --git a/engines/m4/riddle/rooms/section4/room494.cpp b/engines/m4/riddle/rooms/section4/room494.cpp
index ad78b3fc199..7ec2f94362b 100644
--- a/engines/m4/riddle/rooms/section4/room494.cpp
+++ b/engines/m4/riddle/rooms/section4/room494.cpp
@@ -70,7 +70,7 @@ void Room494::init() {
void Room494::daemon() {
int selectedBtn = getSelectedButton();
- bool flag = false;
+ bool btnClicked = false;
switch (_G(kernel).trigger) {
case 111:
@@ -131,8 +131,8 @@ void Room494::daemon() {
}
if (!_machine2) {
- _machine2 = series_show_sprite("494 menu buttons", 0x100,
- selectedBtn * 3 + 2);
+ _machine2 = series_show_sprite("494 menu buttons",
+ selectedBtn * 3 + 2, 0x100);
_selectedBtn2 = selectedBtn;
digi_play("950_s51", 2);
}
@@ -143,8 +143,8 @@ void Room494::daemon() {
}
if (selectedBtn != -1) {
- _machine2 = series_show_sprite("494 menu buttons", 0x100,
- selectedBtn * 3 + 2);
+ _machine2 = series_show_sprite("494 menu buttons",
+ selectedBtn * 3 + 2, 0x100);
_selectedBtn2 = selectedBtn;
digi_play("950_s51", 2);
}
@@ -159,7 +159,7 @@ void Room494::daemon() {
}
_selectState = 0;
- flag = true;
+ btnClicked = true;
}
if (selectedBtn != -1) {
@@ -168,9 +168,11 @@ void Room494::daemon() {
_selectedBtn1 = -1;
}
- if (_selectedBtn1 == -1 && !_machine2)
- _machine1 = series_show_sprite("494 menu buttons", 0x100,
- selectedBtn * 3 + 1);
+ if (_selectedBtn1 == -1 && !_machine2) {
+ _selectedBtn1 = selectedBtn;
+ _machine1 = series_show_sprite("494 menu buttons",
+ selectedBtn * 3 + 1, 0x100);
+ }
} else {
if (selectedBtn != _selectedBtn1) {
terminateMachineAndNull(_machine1);
@@ -178,7 +180,7 @@ void Room494::daemon() {
}
}
- if (flag) {
+ if (btnClicked) {
switch (selectedBtn) {
case 0:
player_set_commands_allowed(false);
More information about the Scummvm-git-logs
mailing list