[Scummvm-git-logs] scummvm master -> 9dbb9879815506993d13951b45c8051ed5c37d89

dreammaster noreply at scummvm.org
Wed Feb 5 05:19:36 UTC 2025


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

Summary:
3482000d68 M4: RIDDLE: Fixes for arriving in Sakkim
9dbb987981 M4: RIDDLE: Fix flag references


Commit: 3482000d68c5402208e6f3dc27130e9aae2527bb
    https://github.com/scummvm/scummvm/commit/3482000d68c5402208e6f3dc27130e9aae2527bb
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2025-02-04T20:47:26-08:00

Commit Message:
M4: RIDDLE: Fixes for arriving in Sakkim

Changed paths:
    engines/m4/riddle/rooms/section7/room701.cpp
    engines/m4/riddle/rooms/section7/room701.h


diff --git a/engines/m4/riddle/rooms/section7/room701.cpp b/engines/m4/riddle/rooms/section7/room701.cpp
index 6f0638ca7ff..7c01e851447 100644
--- a/engines/m4/riddle/rooms/section7/room701.cpp
+++ b/engines/m4/riddle/rooms/section7/room701.cpp
@@ -113,9 +113,9 @@ void Room701::parser() {
 		if (_G(kernel).trigger == 1) {
 			int32 who = conv_whos_talking();
 			if (who == 1)
-				_field98_should = 1103;
+				_ripleyShould = 1103;
 			else if (who <= 0)
-				_field6C_should = 2102;
+				_agentShould = 2102;
 
 			conv_resume(conv_get_handle());
 		} else {
@@ -127,8 +127,8 @@ void Room701::parser() {
 		player_set_commands_allowed(false);
 		_field88 = true;
 		_field72_triggerNum = -1;
-		_field94_mode = 1000;
-		_field98_should = 1100;
+		_ripleyMode = 1000;
+		_ripleyShould = 1100;
 		_G(kernel).trigger_mode = KT_DAEMON;
 		kernel_timing_trigger(1, 102, nullptr);
 		_G(kernel).trigger_mode = KT_PARSE;
@@ -696,8 +696,8 @@ void Room701::daemon() {
 		break;
 
 	case 101:
-		_field94_mode = 1000;
-		_field98_should = 1105;
+		_ripleyMode = 1000;
+		_ripleyShould = 1105;
 
 		break;
 
@@ -711,19 +711,19 @@ void Room701::daemon() {
 		break;
 
 	case 103:
-		switch (_field94_mode) {
+		switch (_ripleyMode) {
 		case 1000:
-			switch (_field98_should) {
+			switch (_ripleyShould) {
 			case 1100:
 				player_set_commands_allowed(false);
-				_field68_mode = 2000;
-				_field6C_should = 2100;
+				_agentMode = 2000;
+				_agentShould = 2100;
 				kernel_timing_trigger(1, 110, nullptr);
 				player_update_info(_G(my_walker), &_G(player_info));
 				_safariShadow3Mach = series_place_sprite("SAFARI SHADOW 3", 0, _G(player_info).x, _G(player_info).y, _G(player_info).scale, 3840);
 				ws_hide_walker(_G(my_walker));
 				_ripTalksAgentMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, _G(player_info).x, _G(player_info).y, _G(player_info).scale, 256, false, triggerMachineByHashCallback, "rip talks agent");
-				_field98_should = 1103;
+				_ripleyShould = 1103;
 				sendWSMessage_10000(1, _ripTalksAgentMach, _ripTrekTalkerPos3Series, 5, 5, 102, _ripTrekTalkerPos3Series, 5, 5, 1);
 				conv_load("conv701a", 10, 10, 101);
 				_lastInventoryCheck = inventoryCheck();
@@ -784,7 +784,7 @@ void Room701::daemon() {
 				terminateMachine(_ripTalksAgentMach);
 				terminateMachine(_safariShadow3Mach);
 				ws_unhide_walker(_G(my_walker));
-				_field6C_should = 2103;
+				_agentShould = 2103;
 				kernel_timing_trigger(1, 2700, nullptr);
 
 				break;
@@ -796,65 +796,59 @@ void Room701::daemon() {
 			break;
 
 		case 3000:
-			switch (_field98_should) {
+			switch (_ripleyShould) {
 			case 3100:
 				player_set_commands_allowed(false);
-				_field98_should = 3101;
+				_ripleyShould = 3101;
+				kernel_timing_trigger(10, 102);
 				break;
 
 			case 3101:
 				terminateMachine(_agentPoshExpressMach02);
 				sendWSMessage_10000(1, _agentPoshExpressMach, _agentGetTelegramSeries, 1, 60, 102, _agentGetTelegramSeries, 60, 60, 0);
-				_field98_should = 3102;
-
+				_ripleyShould = 3102;
 				break;
 
 			case 3102:
 				digi_play("950_S06", 2, 255, 102, 950);
 				inv_give_to_player("MESSAGE LOG");
 				sendWSMessage_10000(1, _agentPoshExpressMach, _agentGetTelegramSeries, 69, 69, -1, _agentGetTelegramSeries, 69, 69, 0);
-				kernel_timing_trigger(1, 2204, nullptr);
-				_field98_should = 3103;
-
+				kernel_timing_trigger(1, 2201);
+				_ripleyShould = 3103;
 				break;
 
 			case 3103:
 				sendWSMessage_10000(1, _agentPoshExpressMach, _agentGetTelegramSeries, 71, 71, -1, _agentGetTelegramSeries, 71, 71, 0);
-				_field98_should = 3103;
-
+				_ripleyShould = 3103;
 				break;
 
 			case 3105:
 				sendWSMessage_10000(1, _agentPoshExpressMach, _agentGetTelegramSeries, 71, 86, 102, _agentGetTelegramSeries, 86, 86, 0);
-				_field98_should = 3107;
-
+				_ripleyShould = 3107;
 				break;
 
 			case 3106:
 				digi_play("950_S06", 2, 255, -1, 950);
 				sendWSMessage_10000(1, _agentPoshExpressMach, _agentGetTelegramSeries, 70, 71, -1, _agentGetTelegramSeries, 71, 71, 0);
-				_field98_should = 3103;
-
+				_ripleyShould = 3103;
 				break;
 
 			case 3107:
 				if (_field130) {
-					kernel_timing_trigger(1, 2501, nullptr);
+					kernel_timing_trigger(1, 2501);
 					_field130 = false;
 				} else {
-					_field98_should = 3108;
+					_ripleyShould = 3108;
 					_agentPoshExpressMach02 = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 768, false, triggerMachineByHashCallback, "agent posh express");
 					sendWSMessage_10000(1, _agentPoshExpressMach02, _701rp01Series, 11, 1, 102, _701rp01Series, 1, 1, 0);
 					sendWSMessage_10000(1, _agentPoshExpressMach, _agentTalkLoopTjSeries, 1, 1, -1, _agentTalkLoopTjSeries, 1, 1, 0);
 				}
-
 				break;
 
 			case 3108:
 				terminateMachine(_agentPoshExpressMach02);
-				kernel_timing_trigger(1, _alreadyBeenHereFl ? 45 : 95, nullptr);
+				kernel_timing_trigger(1, _alreadyBeenHereFl ? 45 : 95);
 				ws_unhide_walker(_G(my_walker));
-
 				break;
 
 			default:
@@ -863,11 +857,11 @@ void Room701::daemon() {
 			break;
 
 		case 3500:
-			switch (_field98_should) {
+			switch (_ripleyShould) {
 			case 3501:
 				_agentSignsForMoneySeries = series_load("AGENT  SIGNS FOR MONEY", -1, nullptr);
-				_field98_should = 3502;
-				_field6C_should = 2101;
+				_ripleyShould = 3502;
+				_agentShould = 2101;
 
 				terminateMachine(_ripTalksAgentMach);
 				player_set_commands_allowed(false);
@@ -878,15 +872,15 @@ void Room701::daemon() {
 				break;
 
 			case 3502:
-				_field6C_should = 2103;
+				_agentShould = 2103;
 				kernel_timing_trigger(1, 103, nullptr);
-				_field98_should = 3504;
+				_ripleyShould = 3504;
 
 				break;
 
 			case 3503:
 				terminateMachine(_agentPoshExpressMach02);
-				_field98_should = 3504;
+				_ripleyShould = 3504;
 				_agentPoshExpressMach02 = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 768, false, triggerMachineByHashCallback, "agent posh express");
 				sendWSMessage_10000(1, _agentPoshExpressMach02, _701rp01Series, 1, 11, 102, _701rp01Series, 11, 11, 0);
 
@@ -895,7 +889,7 @@ void Room701::daemon() {
 			case 3504:
 				terminateMachine(_agentPoshExpressMach);
 				terminateMachine(_agentPoshExpressMach02);
-				_field98_should = 3505;
+				_ripleyShould = 3505;
 				_ripTalksAgentMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 256, false, triggerMachineByHashCallback, "rip talks agent");
 				sendWSMessage_10000(1, _ripTalksAgentMach, _agentSignsForMoneySeries, 1, 70, 102, _agentSignsForMoneySeries, 70, 70, 0);
 
@@ -903,28 +897,28 @@ void Room701::daemon() {
 
 			case 3505:
 				digi_play("950_S06", 2, 255, -1, 950);
-				_field98_should = 3506;
+				_ripleyShould = 3506;
 				sendWSMessage_10000(1, _ripTalksAgentMach, _agentSignsForMoneySeries, 70, 94, 102, _agentSignsForMoneySeries, 94, 94, 0);
 
 				break;
 
 			case 3506:
 				terminateMachine(_ripTalksAgentMach);
-				_field98_should = 3507;
+				_ripleyShould = 3507;
 				_agentPoshExpressMach02 = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 768, false, triggerMachineByHashCallback, "agent posh express");
 				sendWSMessage_10000(1, _agentPoshExpressMach02, _701rp01Series, 11, 1, 102, _701rp01Series, 1, 1, 0);
 				_agentPoshExpressMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 1792, false, triggerMachineByHashCallback, "agent posh express");
-				_field68_mode = 2000;
-				_field6C_should = 2102;
+				_agentMode = 2000;
+				_agentShould = 2102;
 				sendWSMessage_10000(1, _agentPoshExpressMach, _agentTalkLoopTjSeries, 13, 13, 110, _agentTalkLoopTjSeries, 13, 13, 0);
 
 				break;
 
 			case 3507:
-				_field94_mode = 1000;
+				_ripleyMode = 1000;
 				inv_give_to_player("US DOLLARS");
 				terminateMachine(_agentPoshExpressMach02);
-				_field98_should = 1103;
+				_ripleyShould = 1103;
 				player_update_info(_G(my_walker), &_G(player_info));
 				_ripTalksAgentMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, _G(player_info).x, _G(player_info).y, _G(player_info).scale, 256, false, triggerMachineByHashCallback, "rip talks agent");
 				sendWSMessage_10000(1, _ripTalksAgentMach, _ripTrekTalkerPos3Series, 5, 5, 102, _ripTrekTalkerPos3Series, 5, 5, 0);
@@ -939,17 +933,17 @@ void Room701::daemon() {
 
 			break;
 		case 3600:
-			switch (_field98_should) {
+			switch (_ripleyShould) {
 			case 3601:
 				_agentExchangeMoneySeries = series_load("AGENT  EXCHANGE MONEY", -1, nullptr);
 				sendWSMessage_10000(1, _ripTalksAgentMach, _ripTrekTalkerPos3Series, 1, 5, -1, _ripTrekHandTalkPos3Series, 1, 5, 1);
-				_field98_should = 3602;
+				_ripleyShould = 3602;
 				digi_play_loop(_convDigiName_2.c_str(), 1, 255, 103, -1);
 
 				break;
 
 			case 3602:
-				_field98_should = 3604;
+				_ripleyShould = 3604;
 				sendWSMessage_10000(1, _ripTalksAgentMach, _ripTrekTalkerPos3Series, 5, 5, 103, _ripTrekTalkerPos3Series, 5, 5, 1);
 
 				break;
@@ -957,7 +951,7 @@ void Room701::daemon() {
 			case 3603:
 				terminateMachine(_agentPoshExpressMach);
 				terminateMachine(_agentPoshExpressMach02);
-				_field98_should = 3605;
+				_ripleyShould = 3605;
 				_ripTalksAgentMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 256, false, triggerMachineByHashCallback, "rip talks agent");
 				sendWSMessage_10000(1, _ripTalksAgentMach, _agentExchangeMoneySeries, 1, 52, 102, _agentExchangeMoneySeries, 52, 52, 0);
 
@@ -966,20 +960,20 @@ void Room701::daemon() {
 			case 3604:
 				terminateMachine(_ripTalksAgentMach);
 				_agentPoshExpressMach02 = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 768, false, triggerMachineByHashCallback, "agent posh express");
-				_field98_should = 3603;
+				_ripleyShould = 3603;
 				sendWSMessage_10000(1, _agentPoshExpressMach02, _701rp01Series, 1, 11, 102, _701rp01Series, 11, 11, 0);
 
 				break;
 
 			case 3605:
 				digi_play("950_S06", 2, 255, -1, 959);
-				_field98_should = 33605;
+				_ripleyShould = 33605;
 				sendWSMessage_10000(1, _ripTalksAgentMach, _agentExchangeMoneySeries, 52, 19, 102, _agentExchangeMoneySeries, 19, 19, 0);
 
 				break;
 
 			case 3606:
-				_field98_should = 3607;
+				_ripleyShould = 3607;
 				terminateMachine(_ripTalksAgentMach);
 				_agentPoshExpressMach02 = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 768, false, triggerMachineByHashCallback, "agent posh express");
 				sendWSMessage_10000(1, _agentPoshExpressMach02, _701rp01Series, 11, 1, 102, _701rp01Series, 1, 1, 0);
@@ -992,8 +986,8 @@ void Room701::daemon() {
 				inv_give_to_player("SIKKIMESE RUPEE");
 				terminateMachine(_agentPoshExpressMach02);
 
-				_field94_mode = 1000;
-				_field98_should = 1103;
+				_ripleyMode = 1000;
+				_ripleyShould = 1103;
 
 				player_update_info(_G(my_walker), &_G(player_info));
 				_ripTalksAgentMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, _G(player_info).x, _G(player_info).y, _G(player_info).scale, 256, false, triggerMachineByHashCallback, "rip talks agent");
@@ -1005,7 +999,7 @@ void Room701::daemon() {
 
 			case 33605:
 				digi_play("950_S06", 2, 255, -1, 950);
-				_field98_should = 3606;
+				_ripleyShould = 3606;
 				sendWSMessage_10000(1, _ripTalksAgentMach, _agentExchangeMoneySeries, 19, 1, 102, _agentExchangeMoneySeries, 1, 1, 0);
 
 				break;
@@ -1016,11 +1010,11 @@ void Room701::daemon() {
 
 			break;
 		case 3700:
-			switch (_field98_should) {
+			switch (_ripleyShould) {
 			case 3701:
 				player_set_commands_allowed(false);
 				terminateMachine(_ripTalksAgentMach);
-				_field98_should = 3702;
+				_ripleyShould = 3702;
 				_agentPoshExpressMach02 = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 768, false, triggerMachineByHashCallback, "agent posh express");
 				sendWSMessage_10000(1, _agentPoshExpressMach02, _701rp01Series, 1, 11, 102, _701rp01Series, 11, 11, 0);
 
@@ -1029,7 +1023,7 @@ void Room701::daemon() {
 			case 3702:
 				terminateMachine(_agentPoshExpressMach);
 				terminateMachine(_agentPoshExpressMach02);
-				_field98_should = 3709;
+				_ripleyShould = 3709;
 				_ripTalksAgentMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 256, false, triggerMachineByHashCallback, "rip talks agent");
 				sendWSMessage_10000(1, _ripTalksAgentMach, _agentGiveParcelSeries, 1, 33, 102, _agentGiveParcelSeries, 33, 33, 0);
 
@@ -1091,9 +1085,9 @@ void Room701::daemon() {
 				}
 
 				_agentPoshExpressMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 1792, false, triggerMachineByHashCallback, "agent posh express");
-				_field6C_should = 2102;
-				_field68_mode = 2000;
-				_field98_should = 3705;
+				_agentShould = 2102;
+				_agentMode = 2000;
+				_ripleyShould = 3705;
 
 				kernel_timing_trigger(1, 102, nullptr);
 				sendWSMessage_10000(1, _agentPoshExpressMach, _agentTalkLoopTjSeries, 13, 13, 110, _agentTalkLoopTjSeries, 13, 13, 0);
@@ -1101,7 +1095,7 @@ void Room701::daemon() {
 				break;
 
 			case 3705:
-				_field98_should = 3706;
+				_ripleyShould = 3706;
 				terminateMachine(_ripTalksAgentMach);
 				_agentPoshExpressMach02 = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 768, false, triggerMachineByHashCallback, "agent posh express");
 				sendWSMessage_10000(1, _agentPoshExpressMach02, _701rp01Series, 11, 1, 102, _701rp01Series, 1, 1, 0);
@@ -1110,8 +1104,8 @@ void Room701::daemon() {
 
 			case 3706:
 				terminateMachine(_agentPoshExpressMach02);
-				_field94_mode = 1000;
-				_field98_should = 98;
+				_ripleyMode = 1000;
+				_ripleyShould = 98;
 				player_update_info(_G(my_walker), &_G(player_info));
 				_ripTalksAgentMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, _G(player_info).x, _G(player_info).y, _G(player_info).scale, 256, false, triggerMachineByHashCallback, "rip talks agent");
 				sendWSMessage_10000(1, _ripTalksAgentMach, _ripTrekTalkerPos3Series, 5, 5, 102, _ripTrekTalkerPos3Series, 5, 5, 0);
@@ -1120,7 +1114,7 @@ void Room701::daemon() {
 				break;
 
 			case 3709:
-				_field98_should = 3704;
+				_ripleyShould = 3704;
 				sendWSMessage_10000(1, _ripTalksAgentMach, _agentGiveParcelSeries, 34, 51, 102, _agentGiveParcelSeries, 51, 51, 0);
 				digi_play("950_S09", 2, 255, -1, 950);
 
@@ -1148,13 +1142,13 @@ void Room701::daemon() {
 		break;
 
 	case 111:
-		if (_field68_mode != 2000)
+		if (_agentMode != 2000)
 			return;
 
-		switch (_field6C_should) {
+		switch (_agentShould) {
 		case 2100:
 			sendWSMessage_10000(1, _agentPoshExpressMach, _agentTalkLoopTjSeries, 14, 14, 110, _agentTalkLoopTjSeries, 14, 14, 0);
-			_field6C_should = 2102;
+			_agentShould = 2102;
 
 			break;
 
@@ -1219,14 +1213,14 @@ void Room701::daemon() {
 		break;
 
 	case 2200:
-		_field98_should = 3100;
-		_field94_mode = 3000;
+		_ripleyShould = 3100;
+		_ripleyMode = 3000;
 		sendWSMessage_10000(1, _agentPoshExpressMach, _agentTalkLoopTjSeries, 13, 13, 102, _agentTalkLoopTjSeries, 13, 13, 0);
 
 		break;
 
 	case 2201:
-		_field98_should = 3103;
+		_ripleyShould = 3103;
 		kernel_timing_trigger(60, 2300, nullptr);
 
 		break;
@@ -1278,7 +1272,7 @@ void Room701::daemon() {
 		break;
 
 	case 2301:
-		_field98_should = 3106;
+		_ripleyShould = 3106;
 		kernel_timing_trigger(1, 2302, nullptr);
 
 		break;
@@ -1317,25 +1311,23 @@ void Room701::daemon() {
 
 	case 2306:
 		if (_field130) {
-			_field94_mode = 3000;
-			_field98_should = 3105;
+			_ripleyMode = 3000;
+			_ripleyShould = 3105;
 			kernel_timing_trigger(1, 102, nullptr);
 		} else {
 			--_field50_counter;
 			if (_field50_counter <= 0) {
-				_field98_should = 3106;
-				kernel_timing_trigger(1, 2300, nullptr);
+				kernel_timing_trigger(1, 2307);
 			} else {
-				kernel_timing_trigger(1, 2307, nullptr);
+				_ripleyShould = 3106;
+				kernel_timing_trigger(1, 2300);
 			}
 		}
-
 		break;
 
 	case 2307:
-		_field98_should = 3105;
+		_ripleyShould = 3105;
 		kernel_timing_trigger(10, 102, nullptr);
-
 		break;
 
 	case 2501:
@@ -1439,12 +1431,12 @@ void Room701::conv701a() {
 	if (who <= 0) {
 		if (_conv701aNode == 3 && entry == 0) {
 			_convDigiName_1 = Common::String(digiName);
-			_field94_mode = 3500;
-			_field98_should = 3501;
+			_ripleyMode = 3500;
+			_ripleyShould = 3501;
 			return;
 		}
 
-		_field6C_should = 2101;
+		_agentShould = 2101;
 
 	} else if (who == 1) {
 		if (_conv701aNode == 1 && entry == 1) {
@@ -1463,33 +1455,33 @@ void Room701::conv701a() {
 		case 1:
 			if (entry == 3) {
 				_convDigiName_2 = Common::String(digiName);
-				_field94_mode = 3600;
-				_field98_should = 3601;
+				_ripleyMode = 3600;
+				_ripleyShould = 3601;
 
 				return;
 			}
 
-			_field98_should = 1102;
+			_ripleyShould = 1102;
 
 			break;
 
 		case 6:
 			if (entry == 0) {
-				_field98_should = 1102;
+				_ripleyShould = 1102;
 				digi_play(digiName, 1, 255, 1, -1);
 				_field90 = true;
 
 				return;
 			}
 
-			_field98_should = 1102;
+			_ripleyShould = 1102;
 
 			break;
 
 		case 11:
 			if (entry != 12) {
-				_field94_mode = 3700;
-				_field98_should = 3701;
+				_ripleyMode = 3700;
+				_ripleyShould = 3701;
 
 				return;
 			}
@@ -1497,7 +1489,7 @@ void Room701::conv701a() {
 			break;
 
 		default:
-			_field98_should = 1102;
+			_ripleyShould = 1102;
 			break;
 		}
 	}
diff --git a/engines/m4/riddle/rooms/section7/room701.h b/engines/m4/riddle/rooms/section7/room701.h
index ca956976fdc..b78a55df7b1 100644
--- a/engines/m4/riddle/rooms/section7/room701.h
+++ b/engines/m4/riddle/rooms/section7/room701.h
@@ -61,11 +61,11 @@ private:
 	bool _alreadyBeenHereFl = false;
 
 	int32 _field50_counter = 0;
-	int32 _field68_mode = 0;
-	int32 _field6C_should = 0;
+	int32 _agentMode = 0;
+	int32 _agentShould = 0;
 	int32 _field72_triggerNum = -1; // Useless : always -1
-	int32 _field94_mode = 0;
-	int32 _field98_should = 0;
+	int32 _ripleyMode = 0;
+	int32 _ripleyShould = 0;
 	int32 _field9E_triggerNum = -1; // Useless : always -1
 	int32 _conv701aNode = 0;
 	int32 _travelDest = 0;


Commit: 9dbb9879815506993d13951b45c8051ed5c37d89
    https://github.com/scummvm/scummvm/commit/9dbb9879815506993d13951b45c8051ed5c37d89
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2025-02-04T21:19:28-08:00

Commit Message:
M4: RIDDLE: Fix flag references

Changed paths:
    engines/m4/riddle/rooms/section2/room204.cpp
    engines/m4/riddle/rooms/section5/room510.cpp
    engines/m4/riddle/rooms/section7/room701.cpp
    engines/m4/riddle/rooms/section7/room702.cpp
    engines/m4/riddle/rooms/section7/room703.cpp
    engines/m4/riddle/rooms/section7/room704.cpp
    engines/m4/riddle/rooms/section7/room705.cpp
    engines/m4/riddle/rooms/section7/room706.cpp
    engines/m4/riddle/rooms/section7/room710.cpp
    engines/m4/riddle/rooms/section7/room711.cpp
    engines/m4/riddle/rooms/section8/room807.cpp
    engines/m4/riddle/rooms/section8/room808.cpp
    engines/m4/riddle/rooms/section8/room809.cpp


diff --git a/engines/m4/riddle/rooms/section2/room204.cpp b/engines/m4/riddle/rooms/section2/room204.cpp
index c7acaa9682c..5e33c952204 100644
--- a/engines/m4/riddle/rooms/section2/room204.cpp
+++ b/engines/m4/riddle/rooms/section2/room204.cpp
@@ -787,7 +787,7 @@ void Room204::parser() {
 			break;
 
 		case 3:
-			_G(flags[V032]) = 1;
+			_G(flags)[V032] = 1;
 			inv_give_to_player("MALLET");
 			hotspot_set_active(_G(currentSceneDef).hotspots, "MALLET", false);
 			_field16C = 0;
@@ -1006,12 +1006,12 @@ void Room204::parser() {
 	else if (player_said("CHINESE YUAN", "ACOLYTE") || player_said("CHINESE YUAN", "YOUNG PRIEST"))
 		digi_play("204R25", 1, 255, -1, -1);
 	else if (player_said("journal") && !takeFl && !lookFl && !inv_player_has(_G(player).noun)) {
-		if (_G(flags[kTabletsCartoon]) != 0) {
+		if (_G(flags)[kTabletsCartoon] != 0) {
 			digi_play("204R15", 1, 255, -1, -1);
 		} else {
 			if (_G(kernel).trigger == 6) {
-				_G(flags[V089]) = 1;
-				_G(flags[kTabletsCartoon]) = 1;
+				_G(flags)[V089] = 1;
+				_G(flags)[kTabletsCartoon] = 1;
 			}
 			warning("Room204 Parser : sendWSMessage_multi(nullptr)");
 		}
@@ -3030,7 +3030,7 @@ void Room204::conv204a() {
 		_field134 = 2;
 	else if (who != 1) {
 		if (node == 5 && entry == 2) {
-			_G(flags[V285]) = 1;
+			_G(flags)[V285] = 1;
 		}
 
 		if ((node == 2 && entry == 0) || (node == 11 && entry == 0) || (node == 15 && entry == 0) || (node == 14 && entry == 3) || (node == 20 && entry == 3)) {
diff --git a/engines/m4/riddle/rooms/section5/room510.cpp b/engines/m4/riddle/rooms/section5/room510.cpp
index f64cc767ce8..66aee623d87 100644
--- a/engines/m4/riddle/rooms/section5/room510.cpp
+++ b/engines/m4/riddle/rooms/section5/room510.cpp
@@ -831,13 +831,13 @@ bool Room510::useAltarPost() {
 		ws_unhide_walker();
 		terminateMachineAndNull(_statue);
 
-		if (_G(flags[V169]) <= 0) {
+		if (_G(flags)[V169] <= 0) {
 			_statue = series_play(" 510 STATUE LAYED DOWN", 0xa00, 16, -1, 5, 0, 100, 0, 0, 0, -1);
 			kernel_timing_trigger(1, 2, nullptr);
 			hotspot_set_active("ALTAR POST", false);
 			hotspot_set_active("ALTAR POST ", true);
 			kernel_load_variant("510lock1");
-		} else if (_G(flags[V169]) <= 2) {
+		} else if (_G(flags)[V169] <= 2) {
 			_statue = series_play(" 510 STATUE", 0xa00, 16, -1, 5, 0, 100, 0, 0, 0, -1);
 			kernel_timing_trigger(1, 2);
 			hotspot_set_active("ALTAR POST", true);
@@ -847,9 +847,9 @@ bool Room510::useAltarPost() {
 		break;
 
 	case 2:
-		switch (_G(flags[V169])) {
+		switch (_G(flags)[V169]) {
 		case 0:
-			_G(flags[V169]) = 1;
+			_G(flags)[V169] = 1;
 			player_set_commands_allowed(true);
 			break;
 
@@ -871,13 +871,13 @@ bool Room510::useAltarPost() {
 		break;
 
 	case 4:
-		switch (_G(flags[V169])) {
+		switch (_G(flags)[V169]) {
 		case 0:
 			player_set_commands_allowed(true);
 			break;
 
 		case 1:
-			_G(flags[V169]) = 0;
+			_G(flags)[V169] = 0;
 			player_set_commands_allowed(true);
 
 			break;
@@ -944,7 +944,7 @@ bool Room510::useAltarPost() {
 
 	case 11:
 		series_unload(_ripLowReach4);
-		_G(flags[V169]) = 0;
+		_G(flags)[V169] = 0;
 		player_set_commands_allowed(true);
 		break;
 
@@ -967,10 +967,10 @@ bool Room510::useAltarPost() {
 		kernel_timing_trigger(130, 3);
 		ws_hide_walker();
 
-		if (_G(flags[V169]) <= 0) {
+		if (_G(flags)[V169] <= 0) {
 			terminateMachineAndNull(_statue);
 			_statue = series_play("510 RIP LOWERS STATUE", 0xa00, 16, 1, 5);
-		} else if (_G(flags[V169]) == 1) {
+		} else if (_G(flags)[V169] == 1) {
 			terminateMachineAndNull(_statue);
 			_statue = series_play("510 RIP LOWERS STATUE", 0xa00, 18, 1, 5);
 		}
diff --git a/engines/m4/riddle/rooms/section7/room701.cpp b/engines/m4/riddle/rooms/section7/room701.cpp
index 7c01e851447..b54212dac84 100644
--- a/engines/m4/riddle/rooms/section7/room701.cpp
+++ b/engines/m4/riddle/rooms/section7/room701.cpp
@@ -34,8 +34,8 @@ void Room701::preload() {
 }
 
 void Room701::init() {
-	if (_G(flags[V286]))
-		_G(flags[V224]) = 1;
+	if (_G(flags)[V286])
+		_G(flags)[V224] = 1;
 
 	_itemDigiName = nullptr;
 	_field8C_unusedFl = false;
@@ -71,7 +71,7 @@ void Room701::init() {
 		_agentPoshExpressMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, 0, 100, 1792, false, triggerMachineByHashCallback, "agent posh express");
 		sendWSMessage_10000(1, _agentPoshExpressMach, _agentTalkLoopTjSeries, 13, 13, -1, _agentTalkLoopTjSeries, 13, 13, 0);
 
-		++_G(flags[V006]);
+		++_G(flags)[V006];
 		if (setItemsPlacedFlags()) {
 			_field88 = true;
 			_itemDigiName = getItemsPlacedDigi();
@@ -134,7 +134,7 @@ void Room701::parser() {
 		_G(kernel).trigger_mode = KT_PARSE;
 	} else if (lookFl && player_said("COAT RACK")) {
 		digi_play("com130", 1, 255, -1, -1);
-	} else if (lookFl && player_said("Skin") && !_G(flags[V226])) {
+	} else if (lookFl && player_said("Skin") && !_G(flags)[V226]) {
 		switch (_G(kernel).trigger) {
 		case -1:
 			player_set_commands_allowed(false);
@@ -173,7 +173,7 @@ void Room701::parser() {
 
 		case 25:
 			sendWSMessage_150000(_G(my_walker), -1);
-			_G(flags[V226]) = 1;
+			_G(flags)[V226] = 1;
 			player_set_commands_allowed(true);
 
 			break;
@@ -181,14 +181,14 @@ void Room701::parser() {
 		default:
 			break;
 		}
-	} // ecx && player_said("Skin") && !_G(flags[V226])
+	} // ecx && player_said("Skin") && !_G(flags)[V226]
 
-	else if (lookFl && player_said("Skin") && _G(flags[V226])) {
+	else if (lookFl && player_said("Skin") && _G(flags)[V226]) {
 		player_set_commands_allowed(false);
 		digi_play("701R13", 1, 255, -1, -1);
 		player_set_commands_allowed(true);
 
-	} // ecx && player_said("Skin") && _G(flags[V226])
+	} // ecx && player_said("Skin") && _G(flags)[V226]
 
 	else if (lookFl && player_said("Window"))
 		digi_play("701R17", 1, 255, -1, -1);
@@ -294,7 +294,7 @@ void Room701::parser() {
 		||   (player_said("SIKKIMESE RUPEE", "Agent") && inv_player_has("SIKKIMESE RUPEE"))) {
 		digi_play("com012", 1, 255, -1, 997);
 	} else if (player_said("journal", "skin")) {
-		digi_play(_G(flags[V226]) ? "701R35" : "701R36", 1, 255, -1, -1);
+		digi_play(_G(flags)[V226] ? "701R35" : "701R36", 1, 255, -1, -1);
 	} else if (player_said("rm702")) {
 		if (_field88) {
 			switch (_G(kernel).trigger) {
@@ -590,10 +590,10 @@ void Room701::daemon() {
 		break;
 
 	case 82:
-		if (_G(flags[V286]) != 1 || _G(flags[V362]) || _G(flags[V372]) || _G(flags[V225])) {
+		if (_G(flags)[V286] != 1 || _G(flags)[V362] || _G(flags)[V372] || _G(flags)[V225]) {
 			kernel_timing_trigger(1, 75, nullptr);
 		} else {
-			_G(flags[V225]) = 1;
+			_G(flags)[V225] = 1;
 			kernel_timing_trigger(1, 83, nullptr);
 		}
 
@@ -672,8 +672,8 @@ void Room701::daemon() {
 		break;
 
 	case 95:
-		if (_G(flags[V286]) == 1 && !_G(flags[V362]))
-			_G(flags[V372]) = 1;
+		if (_G(flags)[V286] == 1 && !_G(flags)[V362])
+			_G(flags)[V372] = 1;
 
 		terminateMachine(_safariShadow3Mach);
 		player_set_commands_allowed(true);
@@ -729,7 +729,7 @@ void Room701::daemon() {
 				_lastInventoryCheck = inventoryCheck();
 				_fieldBC_unusedFl = true;
 
-				conv_export_value_curr((_G(flags[V088]) < 3) ? 0 : 1, 0);
+				conv_export_value_curr((_G(flags)[V088] < 3) ? 0 : 1, 0);
 				conv_export_pointer_curr(&_lastInventoryCheck, 1);
 
 				_hasCrystalSkull = inv_player_has("CRYSTAL SKULL") ? 1 : 0;
@@ -1239,32 +1239,32 @@ void Room701::daemon() {
 		if (_itemDigiName) {
 			_field58_digiName = _itemDigiName;
 			_itemDigiName = nullptr;
-		} else if (_G(flags[V364]) == 1) {
+		} else if (_G(flags)[V364] == 1) {
 			_field58_digiName = "201R26";
-		} else if (_G(flags[V365]) == 1) {
+		} else if (_G(flags)[V365] == 1) {
 			_field58_digiName = "201R61";
-		} else if (_G(flags[V366]) == 1) {
+		} else if (_G(flags)[V366] == 1) {
 			_field58_digiName = "401R31";
-		} else if (_G(flags[V373]) == 1) {
+		} else if (_G(flags)[V373] == 1) {
 			_field58_digiName = "401R36";
-		} else if (_G(flags[V370]) == 1) {
+		} else if (_G(flags)[V370] == 1) {
 			_field58_digiName = "501R02";
-		} else if (_G(flags[V371]) == 1) {
+		} else if (_G(flags)[V371] == 1) {
 			_field58_digiName = "501R03";
-		} else if (_G(flags[V372]) == 1) {
+		} else if (_G(flags)[V372] == 1) {
 			_field58_digiName = "701R39";
 			_field5C_digiName = "701R39A";
-		} else if (_G(flags[V367]) == 1) {
+		} else if (_G(flags)[V367] == 1) {
 			_field58_digiName = "401R37";
-			_G(flags[V367]) = 0;
+			_G(flags)[V367] = 0;
 			_field130 = true;
-		} else if (_G(flags[V368]) == 1) {
+		} else if (_G(flags)[V368] == 1) {
 			_field58_digiName = "401R38";
-			_G(flags[V368]) = 0;
+			_G(flags)[V368] = 0;
 			_field130 = true;
-		} else if (_G(flags[V369]) == 1) {
+		} else if (_G(flags)[V369] == 1) {
 			_field58_digiName = "401R39";
-			_G(flags[V369]) = 0;
+			_G(flags)[V369] = 0;
 			_field130 = true;
 		}
 
@@ -1372,19 +1372,19 @@ void Room701::daemon() {
 	case 2601:
 		switch (_travelDest) {
 		case 1:
-			_G(flags[kTravelDest]) = 1;
+			_G(flags)[kTravelDest] = 1;
 			break;
 
 		case 2:
-			_G(flags[kTravelDest]) = 0;
+			_G(flags)[kTravelDest] = 0;
 			break;
 
 		case 3:
-			_G(flags[kTravelDest]) = 4;
+			_G(flags)[kTravelDest] = 4;
 			break;
 
 		case 4:
-			_G(flags[kTravelDest]) = 2;
+			_G(flags)[kTravelDest] = 2;
 			break;
 
 		default:
@@ -1498,23 +1498,23 @@ void Room701::conv701a() {
 }
 
 void Room701::updateCounter() {
-	if (_G(flags[V364]) == 1) {
+	if (_G(flags)[V364] == 1) {
 		++_field50_counter;
-		switch (_G(flags[V005])) {
+		switch (_G(flags)[V005]) {
 		case 1:
-			_G(flags[V351]) = 1;
+			_G(flags)[V351] = 1;
 			break;
 
 		case 2:
-			_G(flags[V352]) = 1;
+			_G(flags)[V352] = 1;
 			break;
 
 		case 3:
-			_G(flags[V353]) = 1;
+			_G(flags)[V353] = 1;
 			break;
 
 		case 4:
-			_G(flags[V354]) = 1;
+			_G(flags)[V354] = 1;
 			break;
 
 		default:
@@ -1522,48 +1522,48 @@ void Room701::updateCounter() {
 		}
 	}
 
-	if (_G(flags[V365]) == 1) {
-		_G(flags[V355]) = 1;
+	if (_G(flags)[V365] == 1) {
+		_G(flags)[V355] = 1;
 		++_field50_counter;
 	}
 
-	if (_G(flags[V366]) == 1) {
-		_G(flags[V356]) = 1;
+	if (_G(flags)[V366] == 1) {
+		_G(flags)[V356] = 1;
 		++_field50_counter;
 	}
 
-	if (_G(flags[V367]) == 1) {
-		_G(flags[V357]) = 1;
+	if (_G(flags)[V367] == 1) {
+		_G(flags)[V357] = 1;
 		++_field50_counter;
 	}
 
-	if (_G(flags[V368]) == 1) {
-		_G(flags[V358]) = 1;
+	if (_G(flags)[V368] == 1) {
+		_G(flags)[V358] = 1;
 		++_field50_counter;
 	}
 
-	if (_G(flags[V369]) == 1) {
-		_G(flags[V359]) = 1;
+	if (_G(flags)[V369] == 1) {
+		_G(flags)[V359] = 1;
 		++_field50_counter;
 	}
 
-	if (_G(flags[V370]) == 1) {
-		_G(flags[V360]) = 1;
+	if (_G(flags)[V370] == 1) {
+		_G(flags)[V360] = 1;
 		++_field50_counter;
 	}
 
-	if (_G(flags[V371]) == 1) {
-		_G(flags[V361]) = 1;
+	if (_G(flags)[V371] == 1) {
+		_G(flags)[V361] = 1;
 		++_field50_counter;
 	}
 
-	if (_G(flags[V372]) == 1) {
-		_G(flags[V362]) = 1;
+	if (_G(flags)[V372] == 1) {
+		_G(flags)[V362] = 1;
 		++_field50_counter;
 	}
 
-	if (_G(flags[V373]) == 1) {
-		_G(flags[V363]) = 1;
+	if (_G(flags)[V373] == 1) {
+		_G(flags)[V363] = 1;
 		++_field50_counter;
 	}
 }
diff --git a/engines/m4/riddle/rooms/section7/room702.cpp b/engines/m4/riddle/rooms/section7/room702.cpp
index e203aeaf732..d1550650f54 100644
--- a/engines/m4/riddle/rooms/section7/room702.cpp
+++ b/engines/m4/riddle/rooms/section7/room702.cpp
@@ -35,7 +35,7 @@ void Room702::preload() {
 
 void Room702::init() {
 	_alreadyBeen702Fl = player_been_here(702);
-	_G(flags[V212]) = 0;
+	_G(flags)[V212] = 0;
 
 	if (_G(game).previous_room != KERNEL_RESTORING_GAME) {
 		_field40 = 0;
@@ -56,10 +56,10 @@ void Room702::init() {
 		_ripShowsRingSeries = series_load("RIP SHOWS RING", -1, nullptr);
 		_ripSafariWalkerPos1Series = series_load("RIP SAFARI WALKER POSITION 1", -1, nullptr);
 		_ringCloseupSeries = series_load("Ring closeup", -1, nullptr);
-		_G(flags[V210]) = 0;
+		_G(flags)[V210] = 0;
 		_field40 = 0;
 
-		if (_G(flags[V224]) == 0) {
+		if (_G(flags)[V224] == 0) {
 			_guardMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, -53, 100, 768, false, callback, "guard");
 			sendWSMessage_10000(1, _guardMach, _guardTalksAndBowsSeries, 1, 1, -1, _guardTalksAndBowsSeries, 1, 1, 0);
 			_guardShadowMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 487, 326, 100, 1024, false, callback, "guard shadow");
@@ -80,9 +80,9 @@ void Room702::init() {
 		_ripShowsRingSeries = series_load("RIP SHOWS RING", -1, nullptr);
 		_ripSafariWalkerPos1Series = series_load("RIP SAFARI WALKER POSITION 1", -1, nullptr);
 		_ringCloseupSeries = series_load("Ring closeup", -1, nullptr);
-		_G(flags[V210]) = 0;
+		_G(flags)[V210] = 0;
 		_field40 = 0;
-		if (_G(flags[V224]) == 0) {
+		if (_G(flags)[V224] == 0) {
 			_guardMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 0, -53, 100, 768, false, callback, "guard");
 			sendWSMessage_10000(1, _guardMach, _guardTalksAndBowsSeries, 1, 1, -1, _guardTalksAndBowsSeries, 1, 1, 0);
 			_guardShadowMach = TriggerMachineByHash(1, 1, 0, 0, 0, 0, 487, 326, 100, 1024, false, callback, "guard shadow");
@@ -101,13 +101,13 @@ void Room702::init() {
 }
 
 void Room702::pre_parser() {
-	if (player_said_any("  ", "   ") && _G(flags[V211]) && _G(flags[V210]) && _G(flags[V212])) {
+	if (player_said_any("  ", "   ") && _G(flags)[V211] && _G(flags)[V210] && _G(flags)[V212]) {
 		_G(player).need_to_walk = false;
 		_G(player).ready_to_walk = true;
 		_G(player).waiting_for_walk = false;
 	}
 
-	if (_G(flags[V224]) && player_said_any("  ", "   ")) {
+	if (_G(flags)[V224] && player_said_any("  ", "   ")) {
 		_G(player).need_to_walk = false;
 		_G(player).ready_to_walk = true;
 		_G(player).waiting_for_walk = false;
@@ -120,17 +120,17 @@ void Room702::parser() {
 	bool takeFl = player_said("take");
 	bool gearFl = player_said_any("push", "pull", "gear", "open", "close");
 
-	if (player_said("CIGAR BAND", "GUARD") && inv_player_has("CIGAR BAND") && !_G(flags[V211])) {
-		_G(flags[V211]) = 1;
-		_G(flags[V228]) = 1;
+	if (player_said("CIGAR BAND", "GUARD") && inv_player_has("CIGAR BAND") && !_G(flags)[V211]) {
+		_G(flags)[V211] = 1;
+		_G(flags)[V228] = 1;
 		_G(kernel).trigger_mode = KT_DAEMON;
 		kernel_timing_trigger(10, 40, nullptr);
 		_G(kernel).trigger_mode = KT_PARSE;
 	} else if (player_said("conv702a")) {
 		if (_G(kernel).trigger != 1) {
 			conv702a();
-			_G(flags[V211]) = 1;
-			_G(flags[V228]) = 1;
+			_G(flags)[V211] = 1;
+			_G(flags)[V228] = 1;
 		} else {
 			int32 who = conv_whos_talking();
 			if (who <= 0) {
@@ -153,7 +153,7 @@ void Room702::parser() {
 			_field40 = 0;
 			sendWSMessage_10000(1, _guardMach, _guardStepsAsideTalksSeries, 27, 1, 100, _guardStepsAsideTalksSeries, 1, 1, 0);
 			sendWSMessage_10000(1, _guardShadowMach, _702GuardShadow2Series, 1, 1, -1, _702GuardShadow2Series, 1, 1, 0);
-			_G(flags[V212]) = 0;
+			_G(flags)[V212] = 0;
 			_field58 = -1;
 			_field44_mode = 1000;
 			_field48_should = 1100;
@@ -184,7 +184,7 @@ void Room702::parser() {
 		switch (_G(kernel).trigger) {
 		case -1:
 			player_set_commands_allowed(false);
-			if (!_G(flags[V214]) && !_G(flags[V228])) {
+			if (!_G(flags)[V214] && !_G(flags)[V228]) {
 				digi_play("702R05", 1, 255, 2, -1);
 			} else {
 				digi_play("702R05", 1, 255, 3, -1);
@@ -229,7 +229,7 @@ void Room702::parser() {
 			break;
 		}
 	} // esi && _G(player).click_y <= 374
-	else if (player_said("  ") && _G(flags[V224])) {
+	else if (player_said("  ") && _G(flags)[V224]) {
 		player_set_commands_allowed(false);
 		switch (_G(kernel).trigger) {
 		case -1:
@@ -256,7 +256,7 @@ void Room702::parser() {
 		default:
 			break;
 		}
-	} // player_said("  ") && _G(flags[V224])
+	} // player_said("  ") && _G(flags)[V224]
 	if (player_said("exit")) {
 		switch (_G(kernel).trigger) {
 		case -1:
@@ -264,8 +264,8 @@ void Room702::parser() {
 			break;
 
 		case 4:
-			if (_G(flags[V211]) && !_G(flags[V210]))
-				_G(flags[V213]) = 1;
+			if (_G(flags)[V211] && !_G(flags)[V210])
+				_G(flags)[V213] = 1;
 
 			_G(game).new_room = 701;
 			break;
@@ -274,16 +274,16 @@ void Room702::parser() {
 			break;
 		}
 	} // player_said("exit")
-	else if (player_said_any("  ", "   ") || (player_said("CIGAR BAND", "GUARD") && _G(flags[V211]))) {
+	else if (player_said_any("  ", "   ") || (player_said("CIGAR BAND", "GUARD") && _G(flags)[V211])) {
 		switch (_G(kernel).trigger) {
 		case -1:
 			player_set_commands_allowed(false);
-			if (_G(flags[V224]))
+			if (_G(flags)[V224])
 				kernel_timing_trigger(10, 84, nullptr);
-			else if (!_G(flags[V211]))
+			else if (!_G(flags)[V211])
 				kernel_timing_trigger(10, 5, nullptr);
-			else if (_G(flags[V210]))
-				kernel_timing_trigger(10, _G(flags[V212]) ? 84 : 83, nullptr);
+			else if (_G(flags)[V210])
+				kernel_timing_trigger(10, _G(flags)[V212] ? 84 : 83, nullptr);
 			else {
 				setGlobals1(_ripShowsRingSeries, 1, 10, 10, 10, 0, 10, 19, 19, 19, 0, 19, 30, 30, 30, 0, 0, 0, 0, 0, 0);
 				sendWSMessage_110000(_G(my_walker), 80);
@@ -304,8 +304,8 @@ void Room702::parser() {
 		case 4:
 			adv_kill_digi_between_rooms(false);
 			digi_play_loop("950_s39", 3, 255, -1, -1);
-			if (_G(flags[V211]) && !_G(flags[V210])) {
-				_G(flags[V213]) = 1;
+			if (_G(flags)[V211] && !_G(flags)[V210]) {
+				_G(flags)[V213] = 1;
 			}
 
 			_G(game).new_room = 703;
@@ -359,7 +359,7 @@ void Room702::parser() {
 		default:
 			break;
 		}
-	} // player_said_any("  ", "   ") || (player_said("CIGAR BAND", "GUARD") && _G(flags[V211]))
+	} // player_said_any("  ", "   ") || (player_said("CIGAR BAND", "GUARD") && _G(flags)[V211])
 	else if (lookFl && player_said(" ")) {
 		switch (_G(kernel).trigger) {
 		case -1:
@@ -368,10 +368,10 @@ void Room702::parser() {
 			break;
 
 		case 2:
-			if (_G(flags[V227])) {
+			if (_G(flags)[V227]) {
 				kernel_timing_trigger(10, 3, nullptr);
 			} else {
-				_G(flags[V227]) = 1;
+				_G(flags)[V227] = 1;
 				digi_play("702R01A", 1, 255, 3, -1);
 			}
 			break;
@@ -399,10 +399,10 @@ void Room702::daemon() {
 	case 40:
 		player_set_commands_allowed(false);
 		setGlobals1(1, _ripShowsRingSeries, 10, 10, 10, 0, 10, 19, 19, 19, 0, 19, 30, 30, 30, 0, 0, 0, 0, 0, 0);
-		if (_G(flags[V210])) {
+		if (_G(flags)[V210]) {
 			sendWSMessage_110000(_G(my_walker), 41);
 		} else {
-			_G(flags[V210]) = 1;
+			_G(flags)[V210] = 1;
 			sendWSMessage_110000(_G(my_walker), 60);
 		}
 
@@ -454,7 +454,7 @@ void Room702::daemon() {
 	case 50:
 		sendWSMessage_10000(1, _guardMach, _guardStepsAsideTalksSeries, 29, 40, -1, _guardStepsAsideTalksSeries, 40, 40, 0);
 		sendWSMessage_10000(1, _guardShadowMach, _702GuardShadow2Series, 29, 40, -1, _702GuardShadow2Series, 40, 40, 0);
-		_G(flags[V212]) = 1;
+		_G(flags)[V212] = 1;
 
 		digi_play("702R11",1,255,51,-1);
 
@@ -544,9 +544,9 @@ void Room702::daemon() {
 
 			case 1102:
 				conv_load("conv702a",10,10,103);
-				conv_export_value_curr(_G(flags[V211]), 0);
-				conv_export_value_curr(_G(flags[V213]), 1);
-				conv_export_value_curr(_G(flags[V222]), 2);
+				conv_export_value_curr(_G(flags)[V211], 0);
+				conv_export_value_curr(_G(flags)[V213], 1);
+				conv_export_value_curr(_G(flags)[V222], 2);
 				conv_play(conv_get_handle());
 
 				_field48_should = 1103;
diff --git a/engines/m4/riddle/rooms/section7/room703.cpp b/engines/m4/riddle/rooms/section7/room703.cpp
index 91ad0a1dc82..67a732c7ede 100644
--- a/engines/m4/riddle/rooms/section7/room703.cpp
+++ b/engines/m4/riddle/rooms/section7/room703.cpp
@@ -39,7 +39,7 @@ void Room703::init() {
 	digi_preload("950_S40", -1);
 	digi_preload("950_S40a", -1);
 
-	if (_G(flags[V224])) {
+	if (_G(flags)[V224]) {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "MONK #1", false);
 		hotspot_set_active(_G(currentSceneDef).hotspots, "MONK #2", false);
 		hotspot_set_active(_G(currentSceneDef).hotspots, "MONK #3", false);
@@ -54,11 +54,11 @@ void Room703::init() {
 
 	case 702:
 		if (!player_been_here(703)) {
-			_G(flags[V217]) = 3;
-			_G(flags[V218]) = 1;
-			_G(flags[V219]) = 5;
-			_G(flags[V220]) = 2;
-			_G(flags[V221]) = 4;
+			_G(flags)[V217] = 3;
+			_G(flags)[V218] = 1;
+			_G(flags)[V219] = 5;
+			_G(flags)[V220] = 2;
+			_G(flags)[V221] = 4;
 		}
 
 		MoveScreenDelta(_G(game_buff_ptr), -320, 0);
@@ -96,13 +96,13 @@ void Room703::init() {
 		break;
 	}
 
-	if (_G(flags[V217])) {
+	if (_G(flags)[V217]) {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "EMPTY NICHE", false);
 	} else {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "PRAYER WHEEL #4", false);
 	}
 
-	switch (_G(flags[V217])) {
+	switch (_G(flags)[V217]) {
 	case 1:
 		_prayerWheelMach = series_place_sprite("703 PEACE PRAYER WHEEL", 0, 640, 0, 100, 1280);
 		break;
@@ -158,7 +158,7 @@ void Room703::parser() {
 	} else if (player_said("PRAYER WHEEL BROCHURE", "PRAYER WHEEL #3") && inv_player_has("PRAYER WHEEL BROCHURE")) {
 		playCheckBrochureAnim("703r10", _G(kernel).trigger);
 	} else if (player_said("PRAYER WHEEL BROCHURE", "PRAYER WHEEL #4") && inv_player_has("PRAYER WHEEL BROCHURE")) {
-		switch (_G(flags[V217])) {
+		switch (_G(flags)[V217]) {
 		case 1:
 			playCheckBrochureAnim("704r09", _G(kernel).trigger);
 			break;
@@ -203,7 +203,7 @@ void Room703::parser() {
 		player_set_commands_allowed(false);
 		digi_play("706r10", 1, 255, -1, -1);
 		player_set_commands_allowed(true);
-	} else if (talkFl && player_said_any("MONK #1", "MONK #2", "MONK #3", "MONK #4") && _G(flags[V286]))
+	} else if (talkFl && player_said_any("MONK #1", "MONK #2", "MONK #3", "MONK #4") && _G(flags)[V286])
 		digi_play("com142", 1, 255, -1, -1);
 	else if (talkFl && player_said("MONK #1")) {
 		switch (_G(kernel).trigger) {
@@ -538,10 +538,10 @@ void Room703::parser() {
 		digi_play("com127", 1, 255, -1, 997);
 	} else if (lookFl && player_said_any("PRAYER WHEEL #1", "PRAYER WHEEL #2", "PRAYER WHEEL #3")) {
 		digi_play("com076", 1, 255, -1, -1);
-	} else if (lookFl && player_said("PRAYER WHEEL #4") && _G(flags[V217])) {
+	} else if (lookFl && player_said("PRAYER WHEEL #4") && _G(flags)[V217]) {
 		digi_play("com076", 1, 255, -1, -1);
-	} else if (takeFl && player_said_any("PRAYER WHEEL #1", "PRAYER WHEEL #2", "PRAYER WHEEL #3", "PRAYER WHEEL #4") && _G(flags[V286])) {
-		if (_G(flags[V224]))
+	} else if (takeFl && player_said_any("PRAYER WHEEL #1", "PRAYER WHEEL #2", "PRAYER WHEEL #3", "PRAYER WHEEL #4") && _G(flags)[V286]) {
+		if (_G(flags)[V224])
 			digi_play("706r26", 1, 255, -1, -1);
 		else
 			digi_play("com143", 1, 255, -1, -1);
@@ -584,7 +584,7 @@ void Room703::parser() {
 		}
 	} // takeFl && _G(player).click_y <= 374
 	else if (lookFl && player_said(" ")) {
-		if (_G(flags[V224])) {
+		if (_G(flags)[V224]) {
 			digi_play("706r24", 1, 255, -1, -1);
 		} else {
 			digi_play("com075", 1, 255, -1, -1);
@@ -727,12 +727,12 @@ void Room703::daemon() {
 		break;
 
 	case 74:
-		if (_G(flags[V217])) {
+		if (_G(flags)[V217]) {
 			terminateMachine(_prayerWheelMach);
-			switch (_G(flags[V217])) {
+			switch (_G(flags)[V217]) {
 			case 1:
 				inv_give_to_player("PEACE WHEEL");
-				_G(flags[V217]) = 0;
+				_G(flags)[V217] = 0;
 				player_update_info(_G(my_walker), &_G(player_info));
 				digi_play("950_S40", 2, 255, -1, 950);
 				kernel_examine_inventory_object("PING PEACE WHEEL", _G(master_palette), 5, 1, 362, 225, 75, nullptr, -1);
@@ -741,7 +741,7 @@ void Room703::daemon() {
 
 			case 2:
 				inv_give_to_player("INSIGHT WHEEL");
-				_G(flags[V217]) = 0;
+				_G(flags)[V217] = 0;
 				player_update_info(_G(my_walker), &_G(player_info));
 				digi_play("950_S40", 2, 255, -1, 950);
 				kernel_examine_inventory_object("PING INSIGHT WHEEL", _G(master_palette), 5, 1, 362, 225, 75, nullptr, -1);
@@ -750,7 +750,7 @@ void Room703::daemon() {
 
 			case 3:
 				inv_give_to_player("SERENITY WHEEL");
-				_G(flags[V217]) = 0;
+				_G(flags)[V217] = 0;
 				player_update_info(_G(my_walker), &_G(player_info));
 				digi_play("950_S40", 2, 255, -1, 950);
 				kernel_examine_inventory_object("PING SERENITY WHEEL", _G(master_palette), 5, 1, 362, 225, 75, nullptr, -1);
@@ -759,7 +759,7 @@ void Room703::daemon() {
 
 			case 4:
 				inv_give_to_player("TRUTH WHEEL");
-				_G(flags[V217]) = 0;
+				_G(flags)[V217] = 0;
 				player_update_info(_G(my_walker), &_G(player_info));
 				digi_play("950_S40", 2, 255, -1, 950);
 				kernel_examine_inventory_object("PING TRUTH WHEEL", _G(master_palette), 5, 1, 362, 225, 75, nullptr, -1);
@@ -768,7 +768,7 @@ void Room703::daemon() {
 
 			case 5:
 				inv_give_to_player("WISDOM WHEEL");
-				_G(flags[V217]) = 0;
+				_G(flags)[V217] = 0;
 				player_update_info(_G(my_walker), &_G(player_info));
 				digi_play("950_S40", 2, 255, -1, 950);
 				kernel_examine_inventory_object("PING WISDOM WHEEL", _G(master_palette), 5, 1, 362, 225, 75, nullptr, -1);
@@ -867,9 +867,9 @@ void Room703::daemon() {
 			case 125:
 				conv_load("conv703a", 10, 10, 91);
 				conv_export_value_curr(0, 0);
-				conv_export_value_curr(_G(flags[V211]), 1);
-				conv_export_value_curr(_G(flags[V213]), 2);
-				conv_export_value_curr((_G(flags[V217]) == 5) ? 1 : 0, 0);
+				conv_export_value_curr(_G(flags)[V211], 1);
+				conv_export_value_curr(_G(flags)[V213], 2);
+				conv_export_value_curr((_G(flags)[V217] == 5) ? 1 : 0, 0);
 				conv_play(conv_get_handle());
 
 				break;
@@ -1036,7 +1036,7 @@ void Room703::useWheelOnNiche(int32 trigger, int val1) {
 	switch (_G(kernel).trigger) {
 	case -1:
 		player_set_commands_allowed(false);
-		if (_G(flags[V217])) {
+		if (_G(flags)[V217]) {
 			digi_play("com080", 1, 255, 114, -1);
 		} else {
 			setGlobals1(_ripTrekMedReachHandPos1Series, 1, 5, 5, 5, 0, 5, 10, 10, 10, 0, 10, 1, 1, 1, 0, 0, 0, 0, 0, 0);
@@ -1058,12 +1058,12 @@ void Room703::useWheelOnNiche(int32 trigger, int val1) {
 		break;
 
 	case 104:
-		if (_G(flags[V217]))
+		if (_G(flags)[V217])
 			break;
 		switch (val1) {
 		case 1:
 			inv_move_object("PEACE WHEEL", 703);
-			_G(flags[V217]) = 1;
+			_G(flags)[V217] = 1;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("703 PEACE PRAYER WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1071,7 +1071,7 @@ void Room703::useWheelOnNiche(int32 trigger, int val1) {
 
 		case 2:
 			inv_move_object("INSIGHT WHEEL", 703);
-			_G(flags[V217]) = 2;
+			_G(flags)[V217] = 2;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("703 INSIGHT PRAYER WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1079,7 +1079,7 @@ void Room703::useWheelOnNiche(int32 trigger, int val1) {
 
 		case 3:
 			inv_move_object("SERENITY WHEEL", 703);
-			_G(flags[V217]) = 3;
+			_G(flags)[V217] = 3;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("703 SERENITY PRAYER WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1087,7 +1087,7 @@ void Room703::useWheelOnNiche(int32 trigger, int val1) {
 
 		case 4:
 			inv_move_object("TRUTH WHEEL", 703);
-			_G(flags[V217]) = 4;
+			_G(flags)[V217] = 4;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("703 TRUTH PRAYER WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1095,7 +1095,7 @@ void Room703::useWheelOnNiche(int32 trigger, int val1) {
 
 		case 5:
 			inv_move_object("WISDOM WHEEL", 703);
-			_G(flags[V217]) = 5;
+			_G(flags)[V217] = 5;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("703 WISDOM PRAYER WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1181,7 +1181,7 @@ void Room703::useWheelOnNiche(int32 trigger, int val1) {
 		break;
 
 	case 113:
-		if (_G(flags[V217]) == 5) {
+		if (_G(flags)[V217] == 5) {
 			series_unload(_monk4Series);
 			terminateMachine(_monkMach);
 		}
diff --git a/engines/m4/riddle/rooms/section7/room704.cpp b/engines/m4/riddle/rooms/section7/room704.cpp
index 41e12e48469..bac3f9e36a1 100644
--- a/engines/m4/riddle/rooms/section7/room704.cpp
+++ b/engines/m4/riddle/rooms/section7/room704.cpp
@@ -39,7 +39,7 @@ void Room704::init() {
 	digi_preload("950_S40A", -1);
 	_ripTrekMedReachHandPos1Series = series_load("RIP TREK MED REACH HAND POS1", -1, nullptr);
 
-	if (_G(flags[V224])) {
+	if (_G(flags)[V224]) {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "MONK #5", false);
 		hotspot_set_active(_G(currentSceneDef).hotspots, "MONK #6", false);
 		hotspot_set_active(_G(currentSceneDef).hotspots, "MONK #7", false);
@@ -47,9 +47,9 @@ void Room704::init() {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "EMPTY NICHE", false);
 	}
 
-	hotspot_set_active(_G(currentSceneDef).hotspots, _G(flags[V218]) ? "EMPTY NICHE" : "PRAYER WHEEL #6", false);
+	hotspot_set_active(_G(currentSceneDef).hotspots, _G(flags)[V218] ? "EMPTY NICHE" : "PRAYER WHEEL #6", false);
 
-	switch (_G(flags[V218])) {
+	switch (_G(flags)[V218]) {
 	case 1:
 		_prayerWheelMach = series_place_sprite("704 PEACE PRAYER WHEEL", 0, 0, 0, 100, 1280);
 		break;
@@ -132,7 +132,7 @@ void Room704::parser() {
 	else if (player_said("PRAYER WHEEL BROCHURE", "PRAYER WHEEL #5") && inv_player_has("PRAYER WHEEL BROCHURE"))
 		playCheckBrochureAnim(_G(kernel).trigger, "704r04");
 	else if (player_said("PRAYER WHEEL BROCHURE", "PRAYER WHEEL #6") && inv_player_has("PRAYER WHEEL BROCHURE")) {
-		switch (_G(flags[V218])) {
+		switch (_G(flags)[V218]) {
 		case 1:
 			playCheckBrochureAnim(_G(kernel).trigger, "704r09");
 			break;
@@ -182,7 +182,7 @@ void Room704::parser() {
 		player_set_commands_allowed(false);
 		digi_play("706r10", 1, 255, -1, -1);
 		player_set_commands_allowed(true);
-	} else if (talkFl && player_said_any("MONK #5", "MONK #6", "MONK #7", "MONK #8") && _G(flags[V286]))
+	} else if (talkFl && player_said_any("MONK #5", "MONK #6", "MONK #7", "MONK #8") && _G(flags)[V286])
 		digi_play("com142", 1, 255, -1, -1);
 	else if (talkFl && player_said("MONK #5")) {
 		switch (_G(kernel).trigger) {
@@ -537,16 +537,16 @@ void Room704::parser() {
 		digi_play("com127", 1, 255, -1, -1);
 	} else if (lookFl && player_said_any("PRAYER WHEEL #5", "PRAYER WHEEL #7", "PRAYER WHEEL #8")) {
 		digi_play("com076", 1, 255, -1, -1);
-	} else if (lookFl && player_said("PRAYER WHEEL #6") && _G(flags[V218])) {
+	} else if (lookFl && player_said("PRAYER WHEEL #6") && _G(flags)[V218]) {
 		digi_play("com076", 1, 255, -1, -1);
-	} else if (takeFl && !player_said_any("PRAYER WHEEL #5", "PRAYER WHEEL #6", "PRAYER WHEEL #7", "PRAYER WHEEL #8") && _G(flags[V286])) {
-		digi_play(_G(flags[V224]) ? "706r26" : "com143", 1, 255, -1, -1);
+	} else if (takeFl && !player_said_any("PRAYER WHEEL #5", "PRAYER WHEEL #6", "PRAYER WHEEL #7", "PRAYER WHEEL #8") && _G(flags)[V286]) {
+		digi_play(_G(flags)[V224] ? "706r26" : "com143", 1, 255, -1, -1);
 	} else if (takeFl && player_said_any("PRAYER WHEEL #5", "PRAYER WHEEL #6", "PRAYER WHEEL #7", "PRAYER WHEEL #8")) {
 		_G(kernel).trigger_mode = KT_DAEMON;
 		kernel_trigger_dispatchx(kernel_trigger_create(player_said("PRAYER WHEEL #6") ? 70 : 80));
 		_G(kernel).trigger_mode = KT_DAEMON;
 	} else if (lookFl && player_said(" ")) {
-		digi_play(_G(flags[V224]) ? "706r24" : "com075", 1, 255, -1, -1);
+		digi_play(_G(flags)[V224] ? "706r24" : "com075", 1, 255, -1, -1);
 	} else if (player_said("CUPOLA")) {
 		switch (_G(kernel).trigger) {
 		case -1:
@@ -642,10 +642,10 @@ void Room704::daemon() {
 		break;
 
 	case 74:
-		switch (_G(flags[V218])) {
+		switch (_G(flags)[V218]) {
 		case 1:
 			inv_give_to_player("PEACE WHEEL");
-			_G(flags[V218]) = 0;
+			_G(flags)[V218] = 0;
 			terminateMachine(_prayerWheelMach);
 			player_update_info(_G(my_walker), &_G(player_info));
 			digi_play("950_S40", 2, 255, -1, 950);
@@ -655,7 +655,7 @@ void Room704::daemon() {
 
 		case 2:
 			inv_give_to_player("INSIGHT WHEEL");
-			_G(flags[V218]) = 0;
+			_G(flags)[V218] = 0;
 			terminateMachine(_prayerWheelMach);
 			player_update_info(_G(my_walker), &_G(player_info));
 			digi_play("950_S40", 2, 255, -1, 950);
@@ -665,7 +665,7 @@ void Room704::daemon() {
 
 		case 3:
 			inv_give_to_player("SERENITY WHEEL");
-			_G(flags[V218]) = 0;
+			_G(flags)[V218] = 0;
 			terminateMachine(_prayerWheelMach);
 			player_update_info(_G(my_walker), &_G(player_info));
 			digi_play("950_S40", 2, 255, -1, 950);
@@ -675,7 +675,7 @@ void Room704::daemon() {
 
 		case 4:
 			inv_give_to_player("TRUTH WHEEL");
-			_G(flags[V218]) = 0;
+			_G(flags)[V218] = 0;
 			terminateMachine(_prayerWheelMach);
 			player_update_info(_G(my_walker), &_G(player_info));
 			digi_play("950_S40", 2, 255, -1, 950);
@@ -685,7 +685,7 @@ void Room704::daemon() {
 
 		case 5:
 			inv_give_to_player("WISDOM WHEEL");
-			_G(flags[V218]) = 0;
+			_G(flags)[V218] = 0;
 			terminateMachine(_prayerWheelMach);
 			player_update_info(_G(my_walker), &_G(player_info));
 			digi_play("950_S40", 2, 255, -1, 950);
@@ -786,9 +786,9 @@ void Room704::daemon() {
 		case 125:
 			conv_load("conv704a", 10, 10, 91);
 			conv_export_value_curr(0, 0);
-			conv_export_value_curr(_G(flags[V211]), 1);
-			conv_export_value_curr(_G(flags[V213]), 2);
-			conv_export_value_curr((_G(flags[V218]) == 3) ? 1 : 0, 0);
+			conv_export_value_curr(_G(flags)[V211], 1);
+			conv_export_value_curr(_G(flags)[V213], 2);
+			conv_export_value_curr((_G(flags)[V218] == 3) ? 1 : 0, 0);
 			conv_play(conv_get_handle());
 
 			break;
@@ -957,7 +957,7 @@ void Room704::useWheelOnNiche(int32 trigger, int val1) {
 	switch (_G(kernel).trigger) {
 	case -1:
 		player_set_commands_allowed(false);
-		if (_G(flags[V218])) {
+		if (_G(flags)[V218]) {
 			digi_play("com080", 1, 255, 114, -1);
 		} else {
 			setGlobals1(_ripTrekMedReachHandPos1Series, 1, 5, 5, 5, 0, 5, 10, 10, 10, 0, 10, 1, 1, 1, 0, 0, 0, 0, 0, 0);
@@ -979,12 +979,12 @@ void Room704::useWheelOnNiche(int32 trigger, int val1) {
 		break;
 
 	case 104:
-		switch (_G(flags[V218])) {
+		switch (_G(flags)[V218]) {
 		case 0:
 			break;
 		case 1:
 			inv_move_object("PEACE WHEEL", 704);
-			_G(flags[V218]) = 1;
+			_G(flags)[V218] = 1;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("704 PEACE PRAYER WHEEL", 0, 0, 0, 100, 1280);
 			kernel_timing_trigger(5, 105);
@@ -993,7 +993,7 @@ void Room704::useWheelOnNiche(int32 trigger, int val1) {
 
 		case 2:
 			inv_move_object("INSIGHT WHEEL", 704);
-			_G(flags[V218]) = 2;
+			_G(flags)[V218] = 2;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("704 INSIGHT PRAYER WHEEL", 0, 0, 0, 100, 1280);
 			kernel_timing_trigger(5, 105);
@@ -1002,7 +1002,7 @@ void Room704::useWheelOnNiche(int32 trigger, int val1) {
 
 		case 3:
 			inv_move_object("SERENITY WHEEL", 704);
-			_G(flags[V218]) = 3;
+			_G(flags)[V218] = 3;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("704 SERENITY PRAYER WHEEL", 0, 0, 0, 100, 1280);
 			kernel_timing_trigger(5, 105);
@@ -1011,7 +1011,7 @@ void Room704::useWheelOnNiche(int32 trigger, int val1) {
 
 		case 4:
 			inv_move_object("TRUTH WHEEL", 704);
-			_G(flags[V218]) = 4;
+			_G(flags)[V218] = 4;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("704 TRUTH PRAYER WHEEL", 0, 0, 0, 100, 1280);
 			kernel_timing_trigger(5, 105);
@@ -1020,7 +1020,7 @@ void Room704::useWheelOnNiche(int32 trigger, int val1) {
 
 		case 5:
 			inv_move_object("WISDOM WHEEL", 704);
-			_G(flags[V218]) = 5;
+			_G(flags)[V218] = 5;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("704 WISDOM PRAYER WHEEL", 0, 0, 0, 100, 1280);
 			kernel_timing_trigger(5, 105);
@@ -1098,7 +1098,7 @@ void Room704::useWheelOnNiche(int32 trigger, int val1) {
 		break;
 
 	case 113:
-		if (_G(flags[V218]) == 3) {
+		if (_G(flags)[V218] == 3) {
 			terminateMachine(_monkMach);
 			series_unload(_704Monk2Series);
 		}
diff --git a/engines/m4/riddle/rooms/section7/room705.cpp b/engines/m4/riddle/rooms/section7/room705.cpp
index f1113f44ab3..8b76145d59c 100644
--- a/engines/m4/riddle/rooms/section7/room705.cpp
+++ b/engines/m4/riddle/rooms/section7/room705.cpp
@@ -39,7 +39,7 @@ void Room705::init() {
 	digi_preload("950_S40A", -1);
 	_ripTrekMedReachPos1Series = series_load("RIP TREK MED REACH HAND POS1", -1, nullptr);
 
-	if (_G(flags[V224])) {
+	if (_G(flags)[V224]) {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "MONK #9", false);
 		hotspot_set_active(_G(currentSceneDef).hotspots, "MONK #10", false);
 		hotspot_set_active(_G(currentSceneDef).hotspots, "MONK #11", false);
@@ -48,9 +48,9 @@ void Room705::init() {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "EMPTY NICHE ", false);
 	}
 
-	hotspot_set_active(_G(currentSceneDef).hotspots, _G(flags[V220]) ? "EMPTY NICHE" : "PRAYER WHEEL #9", false);
+	hotspot_set_active(_G(currentSceneDef).hotspots, _G(flags)[V220] ? "EMPTY NICHE" : "PRAYER WHEEL #9", false);
 
-	switch (_G(flags[V220])) {
+	switch (_G(flags)[V220]) {
 	case 1:
 		_leftWheelMach = series_place_sprite("705 LEFT PEACE WHEEL", 0, 0, 0, 100, 1280);
 		break;
@@ -75,9 +75,9 @@ void Room705::init() {
 		break;
 	}
 
-	hotspot_set_active(_G(currentSceneDef).hotspots, _G(flags[V221]) ? "EMPTY NICHE " : "PRAYER WHEEL #12", false);
+	hotspot_set_active(_G(currentSceneDef).hotspots, _G(flags)[V221] ? "EMPTY NICHE " : "PRAYER WHEEL #12", false);
 
-	switch (_G(flags[V221])) {
+	switch (_G(flags)[V221]) {
 	case 1:
 		_rightWheelMach = series_place_sprite("705 RT PEACE WHEEL", 0, 640, 0, 100, 1280);
 		break;
@@ -155,7 +155,7 @@ void Room705::parser() {
 	} else if ((player_said("PRAYER WHEEL BROCHURE", "EMPTY NICHE") || player_said("PRAYER WHEEL BROCHURE", "EMPTY NICHE ")) && inv_player_has("PRAYER WHEEL BROCHURE"))
 		digi_play("com123", 1, 255, -1, 997);
 	else if (player_said("PRAYER WHEEL BROCHURE", "PRAYER WHEEL #9") && inv_player_has("PRAYER WHEEL BROCHURE")) {
-		switch (_G(flags[V220])) {
+		switch (_G(flags)[V220]) {
 		case 1:
 			playCheckBrochureAnim(_G(kernel).trigger, "704r09");
 			break;
@@ -184,7 +184,7 @@ void Room705::parser() {
 	else if (player_said("PRAYER WHEEL BROCHURE", "PRAYER WHEEL #11") && inv_player_has("PRAYER WHEEL BROCHURE"))
 		playCheckBrochureAnim(_G(kernel).trigger, "705r13");
 	else if (player_said("PRAYER WHEEL BROCHURE", "PRAYER WHEEL #12") && inv_player_has("PRAYER WHEEL BROCHURE")) {
-		switch (_G(flags[V221])) {
+		switch (_G(flags)[V221]) {
 		case 1:
 			playCheckBrochureAnim(_G(kernel).trigger, "704r09");
 			break;
@@ -228,14 +228,14 @@ void Room705::parser() {
 		player_set_commands_allowed(false);
 		digi_play("706r10", 1, 255, -1, -1);
 		player_set_commands_allowed(true);
-	} else if (talkFl && player_said("MONK #9") && _G(flags[V219]) == 4 && _G(flags[V220]) == 1 && _G(flags[V221]) == 2 && _G(flags[V218]) == 3 && _G(flags[V217]) == 5 && _G(flags[V222]) == 0) {
-		_G(flags[V222]) = 1;
+	} else if (talkFl && player_said("MONK #9") && _G(flags)[V219] == 4 && _G(flags)[V220] == 1 && _G(flags)[V221] == 2 && _G(flags)[V218] == 3 && _G(flags)[V217] == 5 && _G(flags)[V222] == 0) {
+		_G(flags)[V222] = 1;
 		intr_cancel_sentence();
 		_G(kernel).trigger_mode = KT_DAEMON;
 		kernel_trigger_dispatchx(kernel_trigger_create(150));
 		_G(kernel).trigger_mode = KT_PARSE;
 		player_set_commands_allowed(false);
-	} else if (talkFl && player_said_any("MONK #9", "MONK #10", "MONK #11", "MONK #12") && _G(flags[V286])) {
+	} else if (talkFl && player_said_any("MONK #9", "MONK #10", "MONK #11", "MONK #12") && _G(flags)[V286]) {
 		digi_play("com142", 1, 255, -1, -1);
 	} else if (talkFl && player_said("MONK #9")) {
 		switch (_G(kernel).trigger) {
@@ -612,16 +612,16 @@ void Room705::parser() {
 		digi_play("com080", 1, 255, -1, -1);
 	} else if (lookFl && player_said_any("EMPTY NICHE", "EMPTY NICHE ")) {
 		digi_play("com127", 1, 255, -1, 997);
-	} else if (lookFl && player_said_any("EMPTY NICHE", "PRAYER WHEEL #9") && _G(flags[V220])) {
+	} else if (lookFl && player_said_any("EMPTY NICHE", "PRAYER WHEEL #9") && _G(flags)[V220]) {
 		digi_play("com076", 1, 255, -1, -1);
-	} else if (lookFl && player_said_any("EMPTY NICHE", "PRAYER WHEEL #12") && _G(flags[V221])) {
+	} else if (lookFl && player_said_any("EMPTY NICHE", "PRAYER WHEEL #12") && _G(flags)[V221]) {
 		digi_play("com076", 1, 255, -1, -1);
 	} else if (lookFl && player_said_any("EMPTY NICHE", "PRAYER WHEEL #10")) {
 		digi_play("com076", 1, 255, -1, -1);
 	} else if (lookFl && player_said_any("EMPTY NICHE", "PRAYER WHEEL #11")) {
 		digi_play("com076", 1, 255, -1, -1);
-	} else if (takeFl && player_said_any("PRAYER WHEEL #9", "PRAYER WHEEL #10", "PRAYER WHEEL #11", "PRAYER WHEEL #12") && _G(flags[V286])) {
-		digi_play(_G(flags[V224]) ? "706r26" : "com143", 1, 255, -1, -1);
+	} else if (takeFl && player_said_any("PRAYER WHEEL #9", "PRAYER WHEEL #10", "PRAYER WHEEL #11", "PRAYER WHEEL #12") && _G(flags)[V286]) {
+		digi_play(_G(flags)[V224] ? "706r26" : "com143", 1, 255, -1, -1);
 	} else if (takeFl && player_said("PRAYER WHEEL #9")) {
 		_G(kernel).trigger_mode = KT_DAEMON;
 		kernel_timing_trigger(10, 70, nullptr);
@@ -635,7 +635,7 @@ void Room705::parser() {
 		kernel_timing_trigger(10, 140, nullptr);
 		_G(kernel).trigger_mode = KT_PARSE;
 	} else if (lookFl && player_said(" ")) {
-		digi_play(_G(flags[V224]) ? "706r24" : "com075", 1, 255, -1, -1);
+		digi_play(_G(flags)[V224] ? "706r24" : "com075", 1, 255, -1, -1);
 	} else if (player_said("CUPOLA")) {
 		switch (_G(kernel).trigger) {
 		case -1:
@@ -731,10 +731,10 @@ void Room705::daemon() {
 		break;
 
 	case 74:
-		switch (_G(flags[V220])) {
+		switch (_G(flags)[V220]) {
 		case 1:
 			inv_give_to_player("PEACE WHEEL");
-			_G(flags[V220]) = 0;
+			_G(flags)[V220] = 0;
 			terminateMachine(_leftWheelMach);
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING PEACE WHEEL", _G(master_palette), 5, 1, 145, 225, 75, nullptr, -1);
@@ -743,7 +743,7 @@ void Room705::daemon() {
 
 		case 2:
 			inv_give_to_player("INSIGHT WHEEL");
-			_G(flags[V220]) = 0;
+			_G(flags)[V220] = 0;
 			terminateMachine(_leftWheelMach);
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING INSIGHT WHEEL", _G(master_palette), 5, 1, 145, 225, 75, nullptr, -1);
@@ -752,7 +752,7 @@ void Room705::daemon() {
 
 		case 3:
 			inv_give_to_player("SERENITY WHEEL");
-			_G(flags[V220]) = 0;
+			_G(flags)[V220] = 0;
 			terminateMachine(_leftWheelMach);
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING SERENITY WHEEL", _G(master_palette), 5, 1, 145, 225, 75, nullptr, -1);
@@ -761,7 +761,7 @@ void Room705::daemon() {
 
 		case 4:
 			inv_give_to_player("TRUTH WHEEL");
-			_G(flags[V220]) = 0;
+			_G(flags)[V220] = 0;
 			terminateMachine(_leftWheelMach);
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING TRUTH WHEEL", _G(master_palette), 5, 1, 145, 225, 75, nullptr, -1);
@@ -770,7 +770,7 @@ void Room705::daemon() {
 
 		case 5:
 			inv_give_to_player("WISDOM WHEEL");
-			_G(flags[V220]) = 0;
+			_G(flags)[V220] = 0;
 			terminateMachine(_leftWheelMach);
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING WISDOM WHEEL", _G(master_palette), 5, 1, 145, 225, 75, nullptr, -1);
@@ -871,9 +871,9 @@ void Room705::daemon() {
 			case 125:
 				conv_load("conv705a", 10, 10, 91);
 				conv_export_value_curr(0, 0);
-				conv_export_value_curr(_G(flags[V211]), 1);
-				conv_export_value_curr(_G(flags[V213]), 2);
-				conv_export_value_curr(_G(flags[V220]) == 1 ? 1 : 0, 0);
+				conv_export_value_curr(_G(flags)[V211], 1);
+				conv_export_value_curr(_G(flags)[V213], 2);
+				conv_export_value_curr(_G(flags)[V220] == 1 ? 1 : 0, 0);
 				conv_play(conv_get_handle());
 
 				break;
@@ -947,9 +947,9 @@ void Room705::daemon() {
 			case 135:
 				conv_load("conv705b", 10, 10, 94);
 				conv_export_value_curr(0, 0);
-				conv_export_value_curr(_G(flags[V211]), 1);
-				conv_export_value_curr(_G(flags[V213]), 2);
-				conv_export_value_curr(_G(flags[V221]) == 2 ? 1 : 0, 0);
+				conv_export_value_curr(_G(flags)[V211], 1);
+				conv_export_value_curr(_G(flags)[V213], 2);
+				conv_export_value_curr(_G(flags)[V221] == 2 ? 1 : 0, 0);
 				conv_play(conv_get_handle());
 
 				break;
@@ -1051,10 +1051,10 @@ void Room705::daemon() {
 		break;
 
 	case 144:
-		switch (_G(flags[V221])) {
+		switch (_G(flags)[V221]) {
 		case 1:
 			inv_give_to_player("PEACE WHEEL");
-			_G(flags[V221]) = 0;
+			_G(flags)[V221] = 0;
 			terminateMachine(_rightWheelMach);
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING PEACE WHEEL", _G(master_palette), 5, 1, 388, 225, 145, nullptr, -1);
@@ -1063,7 +1063,7 @@ void Room705::daemon() {
 
 		case 2:
 			inv_give_to_player("INSIGHT WHEEL");
-			_G(flags[V221]) = 0;
+			_G(flags)[V221] = 0;
 			terminateMachine(_rightWheelMach);
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING INSIGHT WHEEL", _G(master_palette), 5, 1, 388, 225, 145, nullptr, -1);
@@ -1072,7 +1072,7 @@ void Room705::daemon() {
 
 		case 3:
 			inv_give_to_player("SERENITY WHEEL");
-			_G(flags[V221]) = 0;
+			_G(flags)[V221] = 0;
 			terminateMachine(_rightWheelMach);
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING SERENITY WHEEL", _G(master_palette), 5, 1, 388, 225, 145, nullptr, -1);
@@ -1081,7 +1081,7 @@ void Room705::daemon() {
 
 		case 4:
 			inv_give_to_player("TRUTH WHEEL");
-			_G(flags[V221]) = 0;
+			_G(flags)[V221] = 0;
 			terminateMachine(_rightWheelMach);
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING TRUTH WHEEL", _G(master_palette), 5, 1, 388, 225, 145, nullptr, -1);
@@ -1090,7 +1090,7 @@ void Room705::daemon() {
 
 		case 5:
 			inv_give_to_player("WISDOM WHEEL");
-			_G(flags[V221]) = 0;
+			_G(flags)[V221] = 0;
 			terminateMachine(_rightWheelMach);
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING WISDOM WHEEL", _G(master_palette), 5, 1, 388, 225, 145, nullptr, -1);
@@ -1146,7 +1146,7 @@ void Room705::daemon() {
 	case 155:
 		sendWSMessage_10000(1, _monkMach, _705Monk1Series, 16, 19, 955, _705Monk1Series, 19, 19, 0);
 		digi_play("706_s01", 2, 127, -1, -1);
-		_G(flags[V222]) = 1;
+		_G(flags)[V222] = 1;
 		player_set_commands_allowed(true);
 
 		break;
@@ -1249,8 +1249,8 @@ void Room705::playCheckBrochureAnim(int32 trigger, const char *digiName) {
 		break;
 
 	case 44:
-		if (player_said("PRAYER WHEEL BROCHURE", "PRAYER WHEEL #12") && _G(flags[V221]) == 4) {
-			_G(flags[V229]) = 1;
+		if (player_said("PRAYER WHEEL BROCHURE", "PRAYER WHEEL #12") && _G(flags)[V221] == 4) {
+			_G(flags)[V229] = 1;
 		}
 
 		kernel_timing_trigger(10, 45, nullptr);
@@ -1280,7 +1280,7 @@ void Room705::useWheelOnLeftNiche(int32 trigger, int val1) {
 	switch (trigger) {
 	case -1:
 		player_set_commands_allowed(false);
-		if (_G(flags[V220])) {
+		if (_G(flags)[V220]) {
 			digi_play("com080", 1, 255, 114, -1);
 		} else {
 			setGlobals1(_ripTrekMedReachPos1Series, 1, 5, 5, 5, 0, 5, 10, 10, 10, 0, 10, 1, 1, 1, 0, 0, 0, 0, 0, 0);
@@ -1302,13 +1302,13 @@ void Room705::useWheelOnLeftNiche(int32 trigger, int val1) {
 		break;
 
 	case 104:
-		switch (_G(flags[V220])) {
+		switch (_G(flags)[V220]) {
 		case 0:
 			return;
 
 		case 1:
 			inv_move_object("PEACE WHEEL", 705);
-			_G(flags[V220]) = 1;
+			_G(flags)[V220] = 1;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_rightWheelMach = series_place_sprite("705 LEFT PEACE WHEEL", 0, 0, 0, 100, 1280);
 
@@ -1316,7 +1316,7 @@ void Room705::useWheelOnLeftNiche(int32 trigger, int val1) {
 
 		case 2:
 			inv_move_object("INSIGHT WHEEL", 705);
-			_G(flags[V220]) = 2;
+			_G(flags)[V220] = 2;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_rightWheelMach = series_place_sprite("705 LEFT INSIGHT WHEEL", 0, 0, 0, 100, 1280);
 
@@ -1324,7 +1324,7 @@ void Room705::useWheelOnLeftNiche(int32 trigger, int val1) {
 
 		case 3:
 			inv_move_object("SERENITY WHEEL", 705);
-			_G(flags[V220]) = 3;
+			_G(flags)[V220] = 3;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_rightWheelMach = series_place_sprite("705 LEFT SERENITY WHEEL", 0, 0, 0, 100, 1280);
 
@@ -1332,7 +1332,7 @@ void Room705::useWheelOnLeftNiche(int32 trigger, int val1) {
 
 		case 4:
 			inv_move_object("TRUTH WHEEL", 705);
-			_G(flags[V220]) = 4;
+			_G(flags)[V220] = 4;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_rightWheelMach = series_place_sprite("705 LEFT TRUTH WHEEL", 0, 0, 0, 100, 1280);
 
@@ -1340,7 +1340,7 @@ void Room705::useWheelOnLeftNiche(int32 trigger, int val1) {
 
 		case 5:
 			inv_move_object("WISDOM WHEEL", 705);
-			_G(flags[V220]) = 5;
+			_G(flags)[V220] = 5;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_rightWheelMach = series_place_sprite("705 LEFT WISDOM WHEEL", 0, 0, 0, 100, 1280);
 
@@ -1396,7 +1396,7 @@ void Room705::useWheelOnLeftNiche(int32 trigger, int val1) {
 		break;
 
 	case 113:
-		if (_G(flags[V220]) == 1) {
+		if (_G(flags)[V220] == 1) {
 			terminateMachine(_monkMach);
 			series_unload(_705Monk1Series);
 		}
@@ -1432,7 +1432,7 @@ void Room705::useWheelOnRightNiche(int32 trigger, int val1) {
 	switch (trigger) {
 	case -1:
 		player_set_commands_allowed(false);
-		if (_G(flags[V221])) {
+		if (_G(flags)[V221]) {
 			digi_play("com080", 1, 255, 114, -1);
 		} else {
 			setGlobals1(_ripTrekMedReachPos1Series, 1, 5, 5, 5, 0, 5, 10, 10, 10, 0, 10, 1, 1, 1, 0, 0, 0, 0, 0, 0);
@@ -1454,13 +1454,13 @@ void Room705::useWheelOnRightNiche(int32 trigger, int val1) {
 		break;
 
 	case 104:
-		switch (_G(flags[V221])) {
+		switch (_G(flags)[V221]) {
 		case 0:
 			return;
 
 		case 1:
 			inv_move_object("PEACE WHEEL", 705);
-			_G(flags[V221]) = 1;
+			_G(flags)[V221] = 1;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_rightWheelMach = series_place_sprite("705 RT PEACE WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1468,7 +1468,7 @@ void Room705::useWheelOnRightNiche(int32 trigger, int val1) {
 
 		case 2:
 			inv_move_object("INSIGHT WHEEL", 705);
-			_G(flags[V221]) = 2;
+			_G(flags)[V221] = 2;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_rightWheelMach = series_place_sprite("705 RT INSIGHT WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1476,7 +1476,7 @@ void Room705::useWheelOnRightNiche(int32 trigger, int val1) {
 
 		case 3:
 			inv_move_object("SERENITY WHEEL", 705);
-			_G(flags[V221]) = 3;
+			_G(flags)[V221] = 3;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_rightWheelMach = series_place_sprite("705 RT SERENITY WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1484,7 +1484,7 @@ void Room705::useWheelOnRightNiche(int32 trigger, int val1) {
 
 		case 4:
 			inv_move_object("TRUTH WHEEL", 705);
-			_G(flags[V221]) = 4;
+			_G(flags)[V221] = 4;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_rightWheelMach = series_place_sprite("705 RT TRUTH WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1492,7 +1492,7 @@ void Room705::useWheelOnRightNiche(int32 trigger, int val1) {
 
 		case 5:
 			inv_move_object("WISDOM WHEEL", 705);
-			_G(flags[V221]) = 5;
+			_G(flags)[V221] = 5;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_rightWheelMach = series_place_sprite("705 RT WISDOM WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1565,7 +1565,7 @@ void Room705::useWheelOnRightNiche(int32 trigger, int val1) {
 		break;
 
 	case 113:
-		if (_G(flags[V221]) == 2) {
+		if (_G(flags)[V221] == 2) {
 			terminateMachine(_monkMach);
 			series_unload(_705Monk4Series);
 		}
diff --git a/engines/m4/riddle/rooms/section7/room706.cpp b/engines/m4/riddle/rooms/section7/room706.cpp
index 1db032f3e15..e0dfe46410b 100644
--- a/engines/m4/riddle/rooms/section7/room706.cpp
+++ b/engines/m4/riddle/rooms/section7/room706.cpp
@@ -39,7 +39,7 @@ void Room706::init() {
 	digi_preload("950_S40A", -1);
 	_ripTrekMedReachHandPos1Series = series_load("RIP TREK MED REACH HAND POS1", -1, nullptr);
 
-	if (_G(flags[V224])) {
+	if (_G(flags)[V224]) {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "MONK #13", false);
 		hotspot_set_active(_G(currentSceneDef).hotspots, "MONK #14", false);
 		// Suspicious but present in the original. Should it be #16?
@@ -54,13 +54,13 @@ void Room706::init() {
 	hotspot_set_active(_G(currentSceneDef).hotspots, "  ", false);
 	hotspot_set_active(_G(currentSceneDef).hotspots, "Note", false);
 
-	if (_G(flags[V219])) {
+	if (_G(flags)[V219]) {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "EMPTY NICHE", false);
 	} else {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "PRAYER WHEEL #15", false);
 	}
 
-	switch (_G(flags[V219])) {
+	switch (_G(flags)[V219]) {
 	case 1:
 		_prayerWheelMach = series_place_sprite("706 PEACE PRAYER WHEEL", 0, 640, 0, 100, 1280);
 		break;
@@ -85,7 +85,7 @@ void Room706::init() {
 		break;
 	}
 
-	if (_G(flags[V222])) {
+	if (_G(flags)[V222]) {
 		series_show("706 ENLIGHTEN DOOR OPEN", 3840, 16, -1, -1, 0, 100, 0, 0);
 
 		hotspot_set_active(_G(currentSceneDef).hotspots, "  ", true);
@@ -93,7 +93,7 @@ void Room706::init() {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "empty cell", false);
 	}
 
-	if (_G(flags[V224])) {
+	if (_G(flags)[V224]) {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "Note", true);
 	}
 
@@ -163,7 +163,7 @@ void Room706::parser() {
 	} else if (player_said("PRAYER WHEEL BROCHURE", "PRAYER WHEEL #16") && inv_player_has("PRAYER WHEEL BROCHURE")) {
 		playCheckBrochureAnim(_G(kernel).trigger, "706r12");
 	} else if (player_said("PRAYER WHEEL BROCHURE", "PRAYER WHEEL #15") && inv_player_has("PRAYER WHEEL BROCHURE")) {
-		switch (_G(flags[V219])) {
+		switch (_G(flags)[V219]) {
 		case 1:
 			playCheckBrochureAnim(_G(kernel).trigger, "704r09");
 			break;
@@ -207,7 +207,7 @@ void Room706::parser() {
 		player_set_commands_allowed(false);
 		digi_play("706r10", 1, 255, -1, -1);
 		player_set_commands_allowed(true);
-	} else if (talkFl && player_said_any("MONK #13", "MONK #14", "MONK #15", "MONK #16") && _G(flags[V219])) {
+	} else if (talkFl && player_said_any("MONK #13", "MONK #14", "MONK #15", "MONK #16") && _G(flags)[V219]) {
 		digi_play("com142", 1, 255, -1, -1);
 	} else if (talkFl && player_said("MONK #13")) {
 		switch (_G(kernel).trigger) {
@@ -535,10 +535,10 @@ void Room706::parser() {
 		digi_play("com080", 1, 255, -1, -1);
 	else if (lookFl && player_said("EMPTY NICHE"))
 		digi_play("com127", 1, 255, -1, 997);
-	else if (lookFl && (player_said_any("PRAYER WHEEL #13", "PRAYER WHEEL #14", "PRAYER WHEEL #16") || (player_said("PRAYER WHEEL #15") && _G(flags[V219]))))
+	else if (lookFl && (player_said_any("PRAYER WHEEL #13", "PRAYER WHEEL #14", "PRAYER WHEEL #16") || (player_said("PRAYER WHEEL #15") && _G(flags)[V219])))
 		digi_play("com076", 1, 255, -1, -1);
-	else if (takeFl && player_said_any("PRAYER WHEEL #13", "PRAYER WHEEL #14", "PRAYER WHEEL #15", "PRAYER WHEEL #16") && _G(flags[V286]))
-		digi_play(_G(flags[V224]) ? "706r26" : "com143", 1, 255, -1, -1);
+	else if (takeFl && player_said_any("PRAYER WHEEL #13", "PRAYER WHEEL #14", "PRAYER WHEEL #15", "PRAYER WHEEL #16") && _G(flags)[V286])
+		digi_play(_G(flags)[V224] ? "706r26" : "com143", 1, 255, -1, -1);
 	else if (takeFl && player_said_any("PRAYER WHEEL #13", "PRAYER WHEEL #14", "PRAYER WHEEL #16")) {
 		_G(kernel).trigger_mode = KT_DAEMON;
 		kernel_trigger_dispatchx(kernel_trigger_create(80));
@@ -548,7 +548,7 @@ void Room706::parser() {
 		kernel_trigger_dispatchx(kernel_trigger_create(70));
 		_G(kernel).trigger_mode = KT_PARSE;
 	} else if (lookFl && player_said(" ")) {
-		digi_play(_G(flags[V224]) ? "706r24" : "com075", 1, 255, -1, -1);
+		digi_play(_G(flags)[V224] ? "706r24" : "com075", 1, 255, -1, -1);
 	} else if (player_said("CUPOLA")) {
 		switch (_G(kernel).trigger) {
 		case -1:
@@ -675,10 +675,10 @@ void Room706::daemon() {
 		break;
 
 	case 74:
-		switch (_G(flags[V219])) {
+		switch (_G(flags)[V219]) {
 		case 1:
 			inv_give_to_player("PEACE WHEEL");
-			_G(flags[V219]) = 0;
+			_G(flags)[V219] = 0;
 			player_update_info(_G(my_walker), &_G(player_info));
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING PEACE WHEEL", _G(master_palette), 5, 1, _G(player_info).camera_x + 800, 225, 75, nullptr, -1);
@@ -687,7 +687,7 @@ void Room706::daemon() {
 
 		case 2:
 			inv_give_to_player("INSIGHT WHEEL");
-			_G(flags[V219]) = 0;
+			_G(flags)[V219] = 0;
 			player_update_info(_G(my_walker), &_G(player_info));
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING INSIGHT WHEEL", _G(master_palette), 5, 1, _G(player_info).camera_x + 800, 225, 75, nullptr, -1);
@@ -696,7 +696,7 @@ void Room706::daemon() {
 
 		case 3:
 			inv_give_to_player("SERENITY WHEEL");
-			_G(flags[V219]) = 0;
+			_G(flags)[V219] = 0;
 			player_update_info(_G(my_walker), &_G(player_info));
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING SERENITY WHEEL", _G(master_palette), 5, 1, _G(player_info).camera_x + 800, 225, 75, nullptr, -1);
@@ -705,7 +705,7 @@ void Room706::daemon() {
 
 		case 4:
 			inv_give_to_player("TRUTH WHEEL");
-			_G(flags[V219]) = 0;
+			_G(flags)[V219] = 0;
 			player_update_info(_G(my_walker), &_G(player_info));
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING TRUTH WHEEL", _G(master_palette), 5, 1, _G(player_info).camera_x + 800, 225, 75, nullptr, -1);
@@ -714,7 +714,7 @@ void Room706::daemon() {
 
 		case 5:
 			inv_give_to_player("WISDOM WHEEL");
-			_G(flags[V219]) = 0;
+			_G(flags)[V219] = 0;
 			player_update_info(_G(my_walker), &_G(player_info));
 			digi_play("950_S40", 2, 255, -1, 950);
 			kernel_examine_inventory_object("PING WISDOM WHEEL", _G(master_palette), 5, 1, _G(player_info).camera_x + 800, 225, 75, nullptr, -1);
@@ -816,9 +816,9 @@ void Room706::daemon() {
 		case 125:
 			conv_load("conv706a", 10, 10, 91);
 			conv_export_value_curr(0, 0);
-			conv_export_value_curr(_G(flags[V211]), 1);
-			conv_export_value_curr(_G(flags[V213]), 2);
-			conv_export_value_curr((_G(flags[V219]) == 4) ? 1 : 0, 0);
+			conv_export_value_curr(_G(flags)[V211], 1);
+			conv_export_value_curr(_G(flags)[V213], 2);
+			conv_export_value_curr((_G(flags)[V219] == 4) ? 1 : 0, 0);
 
 			conv_play(conv_get_handle());
 
@@ -1009,7 +1009,7 @@ void Room706::useWheelOnNiche(int32 trigger, int32 val1) {
 	switch (_G(kernel).trigger) {
 	case -1:
 		player_set_commands_allowed(false);
-		if (_G(flags[V219]) == 0) {
+		if (_G(flags)[V219] == 0) {
 			setGlobals1(_ripTrekMedReachHandPos1Series, 1, 5, 5, 5, 0, 5, 10, 10, 10, 0, 10, 1, 1, 1, 0, 0, 0, 0, 0, 0);
 			sendWSMessage_110000(_G(my_walker), 101);
 		} else {
@@ -1031,13 +1031,13 @@ void Room706::useWheelOnNiche(int32 trigger, int32 val1) {
 		break;
 
 	case 104:
-		if (_G(flags[V219]) != 0)
+		if (_G(flags)[V219] != 0)
 			return;
 
 		switch (val1) {
 		case 1:
 			inv_move_object("PEACE WHEEL", 706);
-			_G(flags[V219]) = 1;
+			_G(flags)[V219] = 1;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("706 PEACE PRAYER WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1045,7 +1045,7 @@ void Room706::useWheelOnNiche(int32 trigger, int32 val1) {
 
 		case 2:
 			inv_move_object("INSIGHT WHEEL", 706);
-			_G(flags[V219]) = 2;
+			_G(flags)[V219] = 2;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("706 INSIGHT PRAYER WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1053,7 +1053,7 @@ void Room706::useWheelOnNiche(int32 trigger, int32 val1) {
 
 		case 3:
 			inv_move_object("SERENITY WHEEL", 706);
-			_G(flags[V219]) = 3;
+			_G(flags)[V219] = 3;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("706 SERENITY PRAYER WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1061,7 +1061,7 @@ void Room706::useWheelOnNiche(int32 trigger, int32 val1) {
 
 		case 4:
 			inv_move_object("TRUTH WHEEL", 706);
-			_G(flags[V219]) = 4;
+			_G(flags)[V219] = 4;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("706 TRUTH PRAYER WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1069,7 +1069,7 @@ void Room706::useWheelOnNiche(int32 trigger, int32 val1) {
 
 		case 5:
 			inv_move_object("WISDOM WHEEL", 706);
-			_G(flags[V219]) = 5;
+			_G(flags)[V219] = 5;
 			digi_play("950_S40A", 2, 255, -1, 950);
 			_prayerWheelMach = series_place_sprite("706 WISDOM PRAYER WHEEL", 0, 640, 0, 100, 1280);
 
@@ -1150,7 +1150,7 @@ void Room706::useWheelOnNiche(int32 trigger, int32 val1) {
 		break;
 
 	case 113:
-		if (_G(flags[V219]) == 4) {
+		if (_G(flags)[V219] == 4) {
 			terminateMachine(_monkMach);
 			series_unload(_706Monk3Series);
 		}
diff --git a/engines/m4/riddle/rooms/section7/room710.cpp b/engines/m4/riddle/rooms/section7/room710.cpp
index 88b70f587ac..482b9859de4 100644
--- a/engines/m4/riddle/rooms/section7/room710.cpp
+++ b/engines/m4/riddle/rooms/section7/room710.cpp
@@ -60,7 +60,7 @@ void Room710::init() {
 	switch (_G(game).previous_room) {
 	case KERNEL_RESTORING_GAME:
 		digi_preload("950_s41", -1);
-		if (_G(flags[V223])) {
+		if (_G(flags)[V223]) {
 			_ladderActiveFl = true;
 			_710Rpld4Mach = series_place_sprite("710rpld4", 0, 0, -53, 100, 1541);
 			_710Rpld5Mach = series_place_sprite("710rpld5", 0, 0, -53, 100, 3840);
@@ -76,7 +76,7 @@ void Room710::init() {
 		ws_demand_location(_G(my_walker), 320, 282);
 		ws_demand_facing(_G(my_walker), 5);
 
-		if (_G(flags[V223])) {
+		if (_G(flags)[V223]) {
 			_ladderActiveFl = true;
 			_710Rpld4Mach = series_place_sprite("710rpld4", 0, 0, -53, 100, 1541);
 			_710Rpld5Mach = series_place_sprite("710rpld5", 0, 0, -53, 100, 3840);
@@ -110,7 +110,7 @@ void Room710::init() {
 		ws_demand_location(_G(my_walker), 282, 282);
 		ws_demand_facing(_G(my_walker), 4);
 
-		if (_G(flags[V223])) {
+		if (_G(flags)[V223]) {
 			_ladderActiveFl = true;
 			_710Rpld4Mach = series_place_sprite("710rpld4", 0, 0, -53, 100, 1541);
 			_710Rpld5Mach = series_place_sprite("710rpld5", 0, 0, -53, 100, 4095);
@@ -150,7 +150,7 @@ void Room710::parser() {
 
 		if (_ladderActiveFl) {
 			digi_play("710R21", 1, 255, -1, -1);
-		} else if (_G(flags[kLeftCastleUnderground] == 0)) {
+		} else if (_G(flags)[kLeftCastleUnderground] == 0) {
 			digi_play("710R02", 1, 255, -1, -1);
 		} else {
 			switch (_G(kernel).trigger) {
@@ -206,7 +206,7 @@ void Room710::parser() {
 		digi_play(_ladderActiveFl ? "710R20" : "710R01", 1, 255, -1, -1);
 		player_set_commands_allowed(true);
 	} else if (gearFl && player_said("Rope")) {
-		if (_G(flags[V223])) {
+		if (_G(flags)[V223]) {
 			switch (_G(kernel).trigger) {
 			case -1:
 				player_set_commands_allowed(false);
@@ -241,7 +241,7 @@ void Room710::parser() {
 			case 3:
 				terminateMachine(_ripContractionMach02);
 				_710Rpld4Mach = series_place_sprite("710rpld3", 0, 0, -53, 100, 3840);
-				_G(flags[V223]) = 0;
+				_G(flags)[V223] = 0;
 				player_set_commands_allowed(true);
 
 				break;
@@ -297,7 +297,7 @@ void Room710::parser() {
 			case 3:
 				terminateMachine(_ripContractionMach02);
 				_710Rpld4Mach = series_place_sprite("710rpld4", 0, 0, -53, 100, 1541);
-				_G(flags[V223]) = 1;
+				_G(flags)[V223] = 1;
 				player_set_commands_allowed(true);
 				digi_play("710r07", 1, 255, -1, -1);
 
diff --git a/engines/m4/riddle/rooms/section7/room711.cpp b/engines/m4/riddle/rooms/section7/room711.cpp
index e40aa5c1d25..4a2ec5b4a27 100644
--- a/engines/m4/riddle/rooms/section7/room711.cpp
+++ b/engines/m4/riddle/rooms/section7/room711.cpp
@@ -35,7 +35,7 @@ void Room711::preload() {
 
 void Room711::init() {
 	digi_preload("711R03", -1);
-	if (_G(flags[V224])) {
+	if (_G(flags)[V224]) {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "MASTER LU'S BOOK", false);
 		hotspot_set_active(_G(currentSceneDef).hotspots, "SIKKIMESE LU'S BOOK", false);
 	}
@@ -69,7 +69,7 @@ void Room711::parser() {
 	} else if ((lookFl || player_said("JOURNAL")) && player_said("Master Lu's Book")) {
 		switch (_G(kernel).trigger) {
 		case -1:
-			if (_G(flags[V286]))
+			if (_G(flags)[V286])
 				digi_play("203r54", 1, 255, -1, -1);
 			else {
 				player_set_commands_allowed(false);
@@ -103,7 +103,7 @@ void Room711::parser() {
 			break;
 
 		case 8:
-			_G(flags[V286]) = 1;
+			_G(flags)[V286] = 1;
 			player_set_commands_allowed(true);
 
 			break;
@@ -134,7 +134,7 @@ void Room711::parser() {
 
 		case 2:
 			player_set_commands_allowed(true);
-			_G(game).new_room = _G(flags[V286]) ? 706 : 710;
+			_G(game).new_room = _G(flags)[V286] ? 706 : 710;
 
 			break;
 
diff --git a/engines/m4/riddle/rooms/section8/room807.cpp b/engines/m4/riddle/rooms/section8/room807.cpp
index 9963fcd7609..bcb919a05b6 100644
--- a/engines/m4/riddle/rooms/section8/room807.cpp
+++ b/engines/m4/riddle/rooms/section8/room807.cpp
@@ -55,7 +55,7 @@ void Room807::init() {
 		hotspot_set_active(_G(currentSceneDef).hotspots, "wooden post", false);
 	}
 
-	if (_G(flags[V274])) {
+	if (_G(flags)[V274]) {
 		_807DoorMach = series_show("807door", 4095, 0, -1, -1, 0, 100, 0, 0);
 		hotspot_set_active(_G(currentSceneDef).hotspots, "stone block", true);
 		hotspot_set_active(_G(currentSceneDef).hotspots, "corridor", false);
@@ -104,7 +104,7 @@ void Room807::init() {
 			hotspot_set_active(_G(currentSceneDef).hotspots, "crank", false);
 		}
 
-		if (_G(flags[V276]) != 0) {
+		if (_G(flags)[V276] != 0) {
 			hotspot_set_active(_G(currentSceneDef).hotspots, "mei chen", false);
 		} else {
 			ws_walk_load_shadow_series(S8_SHADOW_DIRS1, S8_SHADOW_NAMES1);
@@ -128,7 +128,7 @@ void Room807::init() {
 		ws_demand_location(_G(my_walker), 273, 270);
 		ws_demand_facing(_G(my_walker), 5);
 
-		if (_G(flags[V276]) != 0) {
+		if (_G(flags)[V276] != 0) {
 			ws_walk(_G(my_walker), 250, 345, nullptr, 5, 2, true);
 		} else {
 			ws_walk_load_walker_series(S8_SHADOW_DIRS1, S8_SHADOW_NAMES1);
@@ -167,7 +167,7 @@ void Room807::init() {
 			ws_demand_location(_G(my_walker), 366, 500);
 			ws_demand_facing(_G(my_walker), 1);
 
-			if (_G(flags[V276]) != 0) {
+			if (_G(flags)[V276] != 0) {
 				ws_walk(_G(my_walker), 366, 345, nullptr, 5, 2, true);
 			} else {
 				_mcTrekMach = triggerMachineByHash_3000(8, 4, *S8_SHADOW_DIRS2, *S8_SHADOW_DIRS1, 450, 600, 1, Walker::player_walker_callback, "mc_trek");
@@ -183,7 +183,7 @@ void Room807::init() {
 }
 
 void Room807::pre_parser() {
-	if (_G(flags[V274]) || inv_object_in_scene("wooden post", 807) || inv_object_in_scene("wooden beam", 807)) {
+	if (_G(flags)[V274] || inv_object_in_scene("wooden post", 807) || inv_object_in_scene("wooden beam", 807)) {
 		if (player_said("gear", "stone block")) {
 			_G(player).need_to_walk = false;
 			_G(player).ready_to_walk = true;
@@ -245,7 +245,7 @@ void Room807::parser() {
 
 	switch (opCode) {
 	case 0:
-		if (player_said("stone block") && _G(flags[V276]) == 0) {
+		if (player_said("stone block") && _G(flags)[V276] == 0) {
 			switch (_G(kernel).trigger) {
 			case -1:
 				ws_walk(_G(my_walker), 305, 305, nullptr, 10, 1, true);
@@ -283,7 +283,7 @@ void Room807::parser() {
 				break;
 			}
 		} else if (player_said("crank") && inv_object_in_scene("crank", 807)) {
-			if (!_G(flags[V274])) {
+			if (!_G(flags)[V274]) {
 				digi_play("com078", 1, 255, -1, 997);
 			} else if (inv_object_in_scene("wooden post", 807)) {
 				digi_play("807r23a", 1, 255, -1, -1);
@@ -321,7 +321,7 @@ void Room807::parser() {
 
 				case 20:
 					player_set_commands_allowed(true);
-					_G(flags[V274]) = 0;
+					_G(flags)[V274] = 0;
 					_field38 = 1;
 					hotspot_set_active(_G(currentSceneDef).hotspots, "stone block", false);
 					hotspot_set_active(_G(currentSceneDef).hotspots, "corridor", true);
@@ -363,7 +363,7 @@ void Room807::parser() {
 		} else if (player_said("wooden beam") && inv_object_in_scene("wooden beam", 807)) {
 			digi_play("807r11", 1, 255, -1, 997);
 		} else if (player_said("wooden post") && inv_object_in_scene("wooden post", 807)) {
-			if (inv_object_in_scene("crank", 807) && _G(flags[V274]) == 0) {
+			if (inv_object_in_scene("crank", 807) && _G(flags)[V274] == 0) {
 				digi_play("807r10", 1, 255, -1, -1);
 			} else {
 				digi_play("com021", 1, 255, -1, 997);
@@ -395,12 +395,12 @@ void Room807::parser() {
 				break;
 
 			case 5:
-				if (_G(flags[V274]) == 0 && !inv_object_in_scene("wooden beam", 807)) {
+				if (_G(flags)[V274] == 0 && !inv_object_in_scene("wooden beam", 807)) {
 					inv_give_to_player("wooden post");
 					kernel_examine_inventory_object("PING WOODEN POST", _G(master_palette), 5, 1, 400, 245, 13, nullptr, -1);
 					terminateMachine(_807BeamMach);
 					series_play("807rp06", 256, 2, 10, 5, 0, 100, 0, 0, 0, 20);
-					_G(flags[V274]) = 1;
+					_G(flags)[V274] = 1;
 				} else {
 					inv_give_to_player("wooden post");
 					kernel_examine_inventory_object("PING WOODEN POST", _G(master_palette), 5, 1, 400, 245, -1, nullptr, -1);
@@ -452,7 +452,7 @@ void Room807::parser() {
 			switch (_G(kernel).trigger) {
 			case -1:
 				if (inv_object_in_scene("crank", 807)) {
-					if (inv_object_in_scene("wooden post", 807) && _G(flags[V274]) == 0) {
+					if (inv_object_in_scene("wooden post", 807) && _G(flags)[V274] == 0) {
 						digi_play("807r23", 1, 255, -1, -1);
 					} else {
 						player_set_commands_allowed(false);
@@ -540,7 +540,7 @@ void Room807::parser() {
 		break;
 
 	case 3:
-		if (_G(flags[V274]) == 0 && !inv_object_in_scene("wooden post", 807) && !inv_object_in_scene("wooden beam", 807)) {
+		if (_G(flags)[V274] == 0 && !inv_object_in_scene("wooden post", 807) && !inv_object_in_scene("wooden beam", 807)) {
 			_field34 = 1;
 			conv_load("conv807a", 10, 10, 747);
 			conv_play(conv_get_handle());
@@ -617,7 +617,7 @@ void Room807::parser() {
 			case 10:
 				player_set_commands_allowed(false);
 				ws_walk(_G(my_walker), 305, 190, nullptr, -1, 2, true);
-				if (_G(flags[V276]) == 0) {
+				if (_G(flags)[V276] == 0) {
 					ws_walk(_mcTrekMach, 305, 190, nullptr, -1, -1, true);
 				}
 
@@ -643,8 +643,8 @@ void Room807::parser() {
 				const int32 destX = CLIP(_G(player_info).x, (int32)247, (int32)400);
 				const int32 destY = MAX(_G(player_info).y, (int32)342);
 
-				if (_G(flags[V276]) == 0 && _G(flags[V275]) == 0) {
-					_G(flags[V275]) = 1;
+				if (_G(flags)[V276] == 0 && _G(flags)[V275] == 0) {
+					_G(flags)[V275] = 1;
 					ws_walk(_G(my_walker), destX, destY, nullptr, 10, -1, true);
 				} else {
 					ws_walk(_G(my_walker), destX, destY, nullptr, 35, -1, false);
@@ -676,7 +676,7 @@ void Room807::parser() {
 				break;
 
 			case 35:
-				if (_G(flags[V276]) == 0) {
+				if (_G(flags)[V276] == 0) {
 					ws_walk(_mcTrekMach, 320, 560, nullptr, -1, -1, true);
 				}
 
@@ -747,7 +747,7 @@ void Room807::parser() {
 				inv_move_object("wooden post", 807);
 				_field38 = 0;
 				hotspot_set_active(_G(currentSceneDef).hotspots, "wooden post", true);
-				if (_G(flags[V274]) == 0 && !inv_object_in_scene("wooden beam", 807)) {
+				if (_G(flags)[V274] == 0 && !inv_object_in_scene("wooden beam", 807)) {
 					terminateMachine(_807Crnk2Mach);
 					_807Crnk2Mach = series_show("807crnk2", 4095, 0, -1, -1, 9, 100, 0, 0);
 					series_load("807rp06", -1, nullptr);
@@ -928,7 +928,7 @@ void Room807::daemon() {
 	case 0:
 		ws_unhide_walker(_G(my_walker));
 		_807DoorMach = series_show("807door", 4095, 0, -1, -1, 0, 100, 0, 0);
-		_G(flags[V274]) = 1;
+		_G(flags)[V274] = 1;
 		hotspot_set_active(_G(currentSceneDef).hotspots, "stone block", true);
 		hotspot_set_active(_G(currentSceneDef).hotspots, "corridor", false);
 		hotspot_set_active(_G(currentSceneDef).hotspots, "chariot ", false);
@@ -958,7 +958,7 @@ void Room807::daemon() {
 
 	case 5:
 		player_set_commands_allowed(true);
-		if (_G(flags[V276]) == 0) {
+		if (_G(flags)[V276] == 0) {
 			hotspot_set_active(_G(currentSceneDef).hotspots, "mei chen", true);
 			kernel_timing_trigger(imath_ranged_rand(1200, 1800), 13, nullptr);
 		}
@@ -970,12 +970,12 @@ void Room807::daemon() {
 		break;
 
 	case 7:
-		if ((_G(flags[V274]) == 0) && !inv_object_in_scene("wooden beam", 807) && !inv_object_in_scene("wooden post", 807)) {
+		if ((_G(flags)[V274] == 0) && !inv_object_in_scene("wooden beam", 807) && !inv_object_in_scene("wooden post", 807)) {
 			if (_field34)
 				kernel_timing_trigger(60, 7, "thunk!");
 			else {
 				player_set_commands_allowed(false);
-				_G(flags[V274]) = 1;
+				_G(flags)[V274] = 1;
 				hotspot_set_active(_G(currentSceneDef).hotspots, "stone block", true);
 				hotspot_set_active(_G(currentSceneDef).hotspots, "corridor", false);
 				hotspot_set_active(_G(currentSceneDef).hotspots, "chariot ", false);
@@ -1013,14 +1013,14 @@ void Room807::daemon() {
 		break;
 
 	case 11:
-		_G(flags[V274]) = 1;
+		_G(flags)[V274] = 1;
 		disable_player_commands_and_fade_init(12);
 
 		break;
 
 	case 12:
 		_field38 = 1;
-		_G(flags[V274]) = 0;
+		_G(flags)[V274] = 0;
 		other_save_game_for_resurrection();
 		_G(game).new_section = 4;
 		_G(game).new_room = 413;
@@ -1028,7 +1028,7 @@ void Room807::daemon() {
 		break;
 
 	case 13:
-		if (player_commands_allowed() && checkStrings() && (_G(flags[V274]) != 0 || inv_object_in_scene("wooden post", 807) || inv_object_in_scene("wooden beam", 807))) {
+		if (player_commands_allowed() && checkStrings() && (_G(flags)[V274] != 0 || inv_object_in_scene("wooden post", 807) || inv_object_in_scene("wooden beam", 807))) {
 			player_set_commands_allowed(false);
 			intr_cancel_sentence();
 			switch (imath_ranged_rand(1, 4)) {
diff --git a/engines/m4/riddle/rooms/section8/room808.cpp b/engines/m4/riddle/rooms/section8/room808.cpp
index 55a2bea44fa..9863c8feeff 100644
--- a/engines/m4/riddle/rooms/section8/room808.cpp
+++ b/engines/m4/riddle/rooms/section8/room808.cpp
@@ -64,7 +64,7 @@ void Room808::init() {
 	series_load("808pos1", -1, nullptr);
 	series_load("808pos2", -1, nullptr);
 
-	if (_G(flags[V096]) == 0) {
+	if (_G(flags)[V096] == 0) {
 		// Unload the freshly loaded series? This doesn't make sense?!
 		series_unload(series_load("808 RIP TEST BRIDGESHOVEL FAR", -1, nullptr));
 		series_unload(series_load("808 RIP TEST BRIDGE", -1, nullptr));
@@ -74,8 +74,8 @@ void Room808::init() {
 	_808ChainMach = series_plain_play("808chain", -1, 0, 100, 0, 0, -1, true);
 	series_play("LIT URN ", 767, 0, -1, 5, -1, 100, 0, 0, 0, -1);
 	if (inv_object_in_scene("FARMER'S SHOVEL", 808)) {
-		if (_G(flags[V095])) {
-			switch (_G(flags[V094])) {
+		if (_G(flags)[V095]) {
+			switch (_G(flags)[V094]) {
 			case 1:
 				_808PosMach = series_show("808pos2", 1281, 0, -1, -1, 6, 100, 0, 0);
 				break;
@@ -96,11 +96,11 @@ void Room808::init() {
 				break;
 			}
 		} else {
-			_808PosMach = series_show("808pos2", 1281, 0, -1, -1, _G(flags[V094]), 100, 0, 0);
+			_808PosMach = series_show("808pos2", 1281, 0, -1, -1, _G(flags)[V094], 100, 0, 0);
 		}
 	} else {
-		if (_G(flags[V095])) {
-			switch (_G(flags[V094])) {
+		if (_G(flags)[V095]) {
+			switch (_G(flags)[V094]) {
 			case 1:
 				_808PosMach = series_show("808pos1", 1281, 0, -1, -1, 6, 100, 0, 0);
 				break;
@@ -121,18 +121,18 @@ void Room808::init() {
 				break;
 			}
 		} else {
-			_808PosMach = series_show("808pos1", 1281, 0, -1, -1, _G(flags[V094]), 100, 0, 0);
+			_808PosMach = series_show("808pos1", 1281, 0, -1, -1, _G(flags)[V094], 100, 0, 0);
 		}
 	}
 
-	if (inv_object_in_scene("crank", 808) && _G(flags[V098]) == 0) {
+	if (inv_object_in_scene("crank", 808) && _G(flags)[V098] == 0) {
 		_808HandleSpriteMach = series_show("808 handle sprite", 4095, 0, -1, -1, 0, 100, 0, 0);
 	}
 
 	switch (_G(game).previous_room) {
 	case KERNEL_RESTORING_GAME:
 		digi_preload("950_s29", -1);
-		if (_G(flags[V097])) {
+		if (_G(flags)[V097]) {
 			_mcTrekMach = triggerMachineByHash_3000(8, 4, *S8_SHADOW_DIRS2, *S8_SHADOW_DIRS1, 345, 115, 5, Walker::player_walker_callback, "mc_trek");
 		} else {
 			_mcTrekMach = triggerMachineByHash_3000(8, 4, *S8_SHADOW_DIRS2, *S8_SHADOW_DIRS1, 112, 238, 5, Walker::player_walker_callback, "mc_trek");
@@ -158,11 +158,11 @@ void Room808::init() {
 		ws_demand_location(_G(my_walker), 18, 216);
 		ws_hide_walker(_G(my_walker));
 
-		if (_G(flags[V276]) == 0) {
+		if (_G(flags)[V276] == 0) {
 			_808McupSeries = series_load("808mcup", -1, nullptr);
 			series_play("808rpup", 0, 0, 2, 5, 0, 100, 0, 0, 0, -1);
 		} else {
-			_G(flags[V276]) = 0;
+			_G(flags)[V276] = 0;
 			_mcTrekMach = triggerMachineByHash_3000(8, 4, *S8_SHADOW_DIRS2, *S8_SHADOW_DIRS1, 345, 116, 5, Walker::player_walker_callback, "mc_trek");
 			series_play("808rpup", 0, 0, 4, 5, 0, 100, 0, 0, 0, -1);
 		}
@@ -210,7 +210,7 @@ void Room808::pre_parser() {
 		break;
 
 	case 1:
-		if (player_said("slot") && _G(flags[V097]) == 0) {
+		if (player_said("slot") && _G(flags)[V097] == 0) {
 			_G(player).walk_x = 202;
 			_G(player).walk_y = 179;
 			_G(player).walk_facing = 2;
@@ -238,7 +238,7 @@ void Room808::pre_parser() {
 	}
 
 
-	if (doneFl || _G(flags[V100]))
+	if (doneFl || _G(flags)[V100])
 		return;
 
 	if (!getWalkPath(_G(my_walker), _G(player).walk_x, _G(player).walk_y))
@@ -254,20 +254,20 @@ void Room808::pre_parser() {
 	if (!check1Fl && !check2Fl)
 		return;
 
-	if (_G(flags[V094]) != 0 && _G(flags[V094]) != 4) {
+	if (_G(flags)[V094] != 0 && _G(flags)[V094] != 4) {
 		_G(player).need_to_walk = false;
 		_G(player).ready_to_walk = true;
 		_G(player).waiting_for_walk = false;
-	} else if (inv_object_in_scene("FARMER'S SHOVEL", 808) && (_G(flags[V094]) == 0 || _G(flags[V100]) == 0)) {
+	} else if (inv_object_in_scene("FARMER'S SHOVEL", 808) && (_G(flags)[V094] == 0 || _G(flags)[V100] == 0)) {
 		intr_cancel_sentence();
 		_G(kernel).trigger_mode = KT_DAEMON;
-		if (_G(flags[V096]) == 0) {
+		if (_G(flags)[V096] == 0) {
 			ws_walk(_G(my_walker), 185, 165, nullptr, 6, 2, true);
 		} else {
 			ws_walk(_G(my_walker), 192, 163, nullptr, 10, 2, true);
 		}
 		_G(kernel).trigger_mode = KT_PREPARSE;
-	} else if (inv_object_in_scene("FARMER'S SHOVEL", 808) && _G(flags[V094]) == 4 && check1Fl) {
+	} else if (inv_object_in_scene("FARMER'S SHOVEL", 808) && _G(flags)[V094] == 4 && check1Fl) {
 		intr_cancel_sentence();
 		_G(kernel).trigger_mode = KT_DAEMON;
 		ws_walk(_G(my_walker), 274, 142, nullptr, 8, 2, true);
@@ -356,7 +356,7 @@ void Room808::parser() {
 				break;
 
 			}
-		} else if (player_said("wheel") && _G(flags[V100])) {
+		} else if (player_said("wheel") && _G(flags)[V100]) {
 			switch (_G(kernel).trigger) {
 			case -1: {
 				bool walkCheck = true;
@@ -411,7 +411,7 @@ void Room808::parser() {
 		} else if (player_said_any("wheel", "wheel ", "wheel  ", "wheel   ")) {
 			switch (_G(kernel).trigger) {
 			case -1:
-				if (_G(flags[V095])) {
+				if (_G(flags)[V095]) {
 					_dword1A1964_facing = 1;
 					ws_walk(_G(my_walker), 157, 166, nullptr, 5, 1, true);
 				} else {
@@ -423,7 +423,7 @@ void Room808::parser() {
 
 			case 5:
 				player_set_commands_allowed(false);
-				setBridgeHotspots(_G(flags[V094]), false);
+				setBridgeHotspots(_G(flags)[V094], false);
 				ws_hide_walker(_G(my_walker));
 				terminateMachine(_808PosMach);
 				setPosMachInfo();
@@ -440,7 +440,7 @@ void Room808::parser() {
 
 			case 10:
 				player_set_commands_allowed(true);
-				setBridgeHotspots(_G(flags[V094]), true);
+				setBridgeHotspots(_G(flags)[V094], true);
 				ws_unhide_walker(_G(my_walker));
 				ws_demand_facing(_G(my_walker), _dword1A1964_facing);
 
@@ -454,7 +454,7 @@ void Room808::parser() {
 				break;
 
 			}
-		} else if (player_said("crank") && inv_object_in_scene("crank", 808) && _G(flags[V100])) {
+		} else if (player_said("crank") && inv_object_in_scene("crank", 808) && _G(flags)[V100]) {
 			switch (_G(kernel).trigger) {
 			case -1:
 				player_set_commands_allowed(false);
@@ -580,11 +580,11 @@ void Room808::parser() {
 		} else if (player_said("hole in bridge")) {
 			switch (_G(kernel).trigger) {
 			case -1:
-				if (_G(flags[V278]) && _G(flags[V277]))
+				if (_G(flags)[V278] && _G(flags)[V277])
 					digi_play("808r16", 1, 255, -1, -1);
 				else {
-					_G(flags[V278]) = 1;
-					digi_play("808r15", 1, 255, _G(flags[V278]) ? 10 : -1, -1);
+					_G(flags)[V278] = 1;
+					digi_play("808r15", 1, 255, _G(flags)[V278] ? 10 : -1, -1);
 				}
 				break;
 
@@ -598,11 +598,11 @@ void Room808::parser() {
 		} else if (player_said("hole in chasm wall")) {
 			switch (_G(kernel).trigger) {
 			case -1:
-				if (_G(flags[V278]) && _G(flags[V277]))
+				if (_G(flags)[V278] && _G(flags)[V277])
 					digi_play("808r16", 1, 255, -1, -1);
 				else {
-					_G(flags[V277]) = 1;
-					digi_play("808r17", 1, 255, _G(flags[V278])  ? 10 : -1, -1);
+					_G(flags)[V277] = 1;
+					digi_play("808r17", 1, 255, _G(flags)[V278]  ? 10 : -1, -1);
 				}
 				break;
 
@@ -656,7 +656,7 @@ void Room808::parser() {
 		} else if ((player_said("FARMER'S SHOVEL") && inv_object_in_scene("FARMER'S SHOVEL", 808)) || player_said_any("FARMER'S SHOVEL ", "FARMER'S SHOVEL  ", "FARMER'S SHOVEL    ")) {
 			digi_play("808r31", 1, 255, -1, -1);
 		} else if (player_said("crank")) {
-			if (_G(flags[V100])) {
+			if (_G(flags)[V100]) {
 				switch (_G(kernel).trigger) {
 				case -1:
 					if (!inv_object_in_scene("crank", 808)) {
@@ -702,11 +702,11 @@ void Room808::parser() {
 		return;
 
 	case 3:
-		if (_G(flags[V097]) == 0 && _G(flags[V094]) == 4 && inv_object_in_scene("FARMER'S SHOVEL", 808)) {
+		if (_G(flags)[V097] == 0 && _G(flags)[V094] == 4 && inv_object_in_scene("FARMER'S SHOVEL", 808)) {
 			conv_load("conv808a", 10, 10, 747);
-			conv_export_value_curr(_G(flags[V098]), 0);
+			conv_export_value_curr(_G(flags)[V098], 0);
 			conv_play(conv_get_handle());
-		} else if (_G(flags[V097]) == 0) {
+		} else if (_G(flags)[V097] == 0) {
 			switch (_G(kernel).trigger) {
 			case -1:
 				player_set_commands_allowed(false);
@@ -761,7 +761,7 @@ void Room808::parser() {
 			default:
 				break;
 			}
-		} else if (_G(flags[V097]) == 1 && inv_object_in_scene("crank", 808) && _G(flags[V100]) == 0) {
+		} else if (_G(flags)[V097] == 1 && inv_object_in_scene("crank", 808) && _G(flags)[V100] == 0) {
 			switch (_G(kernel).trigger) {
 			case -1:
 				ws_turn_to_face(_G(my_walker), 1, 5);
@@ -769,8 +769,8 @@ void Room808::parser() {
 
 			case 5:
 				player_set_commands_allowed(false);
-				if (_G(flags[V099]) == 0) {
-					_G(flags[V099]) = 1;
+				if (_G(flags)[V099] == 0) {
+					_G(flags)[V099] = 1;
 					digi_play("808r26", 1, 255, 10, -1);
 				} else {
 					digi_play("808r27", 1, 255, 10, -1);
@@ -787,13 +787,13 @@ void Room808::parser() {
 
 			case 20:
 				ws_hide_walker(_mcTrekMach);
-				if (_G(flags[V098]) == 0)
+				if (_G(flags)[V098] == 0)
 					terminateMachine(_808HandleSpriteMach);
 
-				if (_G(flags[V094]) == 1 || _G(flags[V094]) == 2 || _G(flags[V094]) == 3) {
+				if (_G(flags)[V094] == 1 || _G(flags)[V094] == 2 || _G(flags)[V094] == 3) {
 					series_load("808 bolt going in and out", -1, nullptr);
 					series_play("808 mei chen cranks handle", 1536, 0, 30, 5, 0, 100, 0, 0, 0, 14);
-				} else if (_G(flags[V094]) == 4 || (_G(flags[V094]) == 0 && inv_object_in_scene("FARMER'S SHOVEL", 808))) {
+				} else if (_G(flags)[V094] == 4 || (_G(flags)[V094] == 0 && inv_object_in_scene("FARMER'S SHOVEL", 808))) {
 					series_play("808 mei chen cranks handle", 1536, 0, 21, 5, 0, 100, 0, 0, 0, 12);
 				} else {
 					series_play("808 mei chen cranks handle", 1536, 0, 40, 5, 0, 100, 0, 0, 0, 7);
@@ -823,13 +823,13 @@ void Room808::parser() {
 				break;
 
 			case 30:
-				if (_G(flags[V098]) == 0) {
+				if (_G(flags)[V098] == 0) {
 					terminateMachine(_808HandleSpriteMach);
 				}
 
 				_808RipFallShovelNearSideMach = series_play("808 mei chen cranks handle", 1536, 16, 35, 5, 0, 100, 0, 0, 15, 47);
 				_safariShadowMach = series_play("808 bolt going in and out", 0, 16, -1, 15, 0, 100, 0, 0, 0, -1);
-				_G(flags[V279]) = 1;
+				_G(flags)[V279] = 1;
 				digi_play("808_s07", 2, 255, -1, -1);
 				digi_play("808_s10", 1, 255, -1, -1);
 
@@ -868,7 +868,7 @@ void Room808::parser() {
 				break;
 
 			case 40:
-				if (_G(flags[V098]) == 0) {
+				if (_G(flags)[V098] == 0) {
 					terminateMachine(_808HandleSpriteMach);
 				}
 
@@ -899,9 +899,9 @@ void Room808::parser() {
 
 			case 50:
 				player_set_commands_allowed(true);
-				_G(flags[V100]) = 1;
-				_G(flags[V276]) = 0;
-				_G(flags[V098]) = 0;
+				_G(flags)[V100] = 1;
+				_G(flags)[V276] = 0;
+				_G(flags)[V098] = 0;
 				hotspot_set_active(_G(currentSceneDef).hotspots, "crank", true);
 				hotspot_set_active(_G(currentSceneDef).hotspots, "slot", false);
 				digi_unload("808_s10");
@@ -911,11 +911,11 @@ void Room808::parser() {
 			case 55:
 				player_set_commands_allowed(true);
 
-				if (_G(flags[V094]) == 4 || (_G(flags[V094]) == 0 && inv_object_in_scene("FARMER'S SHOVEL", 808))) {
-					digi_play(_G(flags[V279]) ? "808r29" : "808r28", 1, 255, -1, -1);
+				if (_G(flags)[V094] == 4 || (_G(flags)[V094] == 0 && inv_object_in_scene("FARMER'S SHOVEL", 808))) {
+					digi_play(_G(flags)[V279] ? "808r29" : "808r28", 1, 255, -1, -1);
 				}
 
-				_G(flags[V098]) = 0;
+				_G(flags)[V098] = 0;
 				hotspot_set_active(_G(currentSceneDef).hotspots, "crank", true);
 				hotspot_set_active(_G(currentSceneDef).hotspots, "slot", false);
 				digi_unload("808_s10");
@@ -928,7 +928,7 @@ void Room808::parser() {
 		} else {
 			switch (_G(kernel).trigger) {
 			case -1:
-				if (_G(flags[V100]) == 0) {
+				if (_G(flags)[V100] == 0) {
 					ws_turn_to_face(_G(my_walker), 1, 10);
 				} else {
 					ws_walk(_G(my_walker), 335, 121, nullptr, 10, 1, true);
@@ -993,7 +993,7 @@ void Room808::parser() {
 		if (player_said("west")) {
 			switch (_G(kernel).trigger) {
 			case -1:
-				if (_G(flags[V097]) == 1 && _G(flags[V100]) == 0) {
+				if (_G(flags)[V097] == 1 && _G(flags)[V100] == 0) {
 					ws_walk(_G(my_walker), 67, 211, nullptr, 2, 7, false);
 				} else {
 					ws_walk(_G(my_walker), 67, 211, nullptr, 10, 7, false);
@@ -1013,14 +1013,14 @@ void Room808::parser() {
 
 			case 5:
 				ws_walk(_G(my_walker), 17, 214, nullptr, 20, 8, true);
-				_G(flags[V276]) = 1;
+				_G(flags)[V276] = 1;
 
 				break;
 
 			case 10:
 				player_set_commands_allowed(false);
 				ws_walk(_G(my_walker), 17, 214, nullptr, 20, 8, true);
-				if (_G(flags[V097]) == 0) {
+				if (_G(flags)[V097] == 0) {
 					setGlobals3(_meiChienHandsBehindBackSeries, 17, 1);
 					sendWSMessage_3840000(_mcTrekMach, -1);
 				} else {
@@ -1049,7 +1049,7 @@ void Room808::parser() {
 			}
 
 
-		} else if (player_said("east") && _G(flags[V100]) == 0) {
+		} else if (player_said("east") && _G(flags)[V100] == 0) {
 			switch (_G(kernel).trigger) {
 			case -1:
 				ws_walk(_G(my_walker), 480, 35, nullptr, 10, 2, true);
@@ -1080,9 +1080,9 @@ void Room808::parser() {
 		if (player_said("mei chen")) {
 			switch (_G(kernel).trigger) {
 			case -1:
-				if (_G(flags[V100]) != 0) {
+				if (_G(flags)[V100] != 0) {
 					digi_play("com122", 1, 255, 997);
-				} else if (_G(flags[V097]) == 1 && inv_object_in_scene("FARMER'S SHOVEL", 808) && _G(flags[V094]) == 4) {
+				} else if (_G(flags)[V097] == 1 && inv_object_in_scene("FARMER'S SHOVEL", 808) && _G(flags)[V094] == 4) {
 					ws_walk(_G(my_walker), 185, 156, nullptr, 11, 5, true);
 				} else {
 					digi_play("808r30", 1, 255, -1, -1);
@@ -1114,8 +1114,8 @@ void Room808::parser() {
 				break;
 
 			case 20:
-				_G(flags[V098]) = 1;
-				if (_G(flags[V097]) == 0) {
+				_G(flags)[V098] = 1;
+				if (_G(flags)[V097] == 0) {
 					setGlobals3(_mctd61Series, 5, 1);
 					sendWSMessage_3840000(_mcTrekMach, 25);
 				} else {
@@ -1140,7 +1140,7 @@ void Room808::parser() {
 				break;
 
 			case 30:
-				if (_G(flags[V097]) != 1) {
+				if (_G(flags)[V097] != 1) {
 					player_set_commands_allowed(true);
 					ws_demand_facing(_G(my_walker), 7);
 				} else {
@@ -1159,7 +1159,7 @@ void Room808::parser() {
 			default:
 				break;
 			}
-		} else if (player_said("slot") && _G(flags[V100]) != 0) {
+		} else if (player_said("slot") && _G(flags)[V100] != 0) {
 			switch (_G(kernel).trigger) {
 			case -1:
 				player_set_commands_allowed(false);
@@ -1224,7 +1224,7 @@ void Room808::parser() {
 				ws_unhide_walker(_G(my_walker));
 				ws_demand_facing(_G(my_walker), 2);
 				terminateMachine(_808RipFallShovelNearSideMach);
-				_G(flags[V095]) = 0;
+				_G(flags)[V095] = 0;
 
 				break;
 
@@ -1296,7 +1296,7 @@ void Room808::parser() {
 			break;
 
 		case 30:
-			_G(flags[V097]) = 1;
+			_G(flags)[V097] = 1;
 			addMcHotspot(1);
 			conv_resume(conv_get_handle());
 
@@ -1328,10 +1328,10 @@ void Room808::daemon() {
 		setBridgeHotspots(2, false);
 		setBridgeHotspots(3, false);
 		setBridgeHotspots(4, false);
-		setBridgeHotspots(_G(flags[V094]), true);
-		addMcHotspot(_G(flags[V097]));
+		setBridgeHotspots(_G(flags)[V094], true);
+		addMcHotspot(_G(flags)[V097]);
 
-		if (_G(flags[V097]) == 0) {
+		if (_G(flags)[V097] == 0) {
 			_meiChienHandsBehindBackSeries = series_load("MEI CHIEN HANDS BEHIND BACK", -1, nullptr);
 			setGlobals3(_meiChienHandsBehindBackSeries, 1, 17);
 			sendWSMessage_3840000(_mcTrekMach, -1);
@@ -1376,11 +1376,11 @@ void Room808::daemon() {
 		player_set_commands_allowed(false);
 		ws_hide_walker(_G(my_walker));
 		terminateMachine(_808PosMach);
-		_G(flags[V096]) = 1;
+		_G(flags)[V096] = 1;
 
 		if (inv_object_in_scene("farmer's shovel", 808)) {
 			series_play("808 RIP TEST BRIDGESHOVEL FAR", 1, 0, 7, 5, 0, 100, 0, 0, 0, -1);
-		} else if (_G(flags[V094]) == 4) {
+		} else if (_G(flags)[V094] == 4) {
 			series_play("808test3", 1, 0, 7, 5, 0, 100, 0, 0, 0, -1);
 		} else {
 			series_play("808 RIP TEST BRIDGE", 1, 0, 7, 5, 0, 100, 0, 0, 0, -1);
@@ -1395,7 +1395,7 @@ void Room808::daemon() {
 
 		if (inv_object_in_scene("farmer's shovel", 808)) {
 			_808PosMach = series_show("808pos2", 1281, 0, -1, -1, 0, 100, 0, 0);
-		} else if (_G(flags[V094]) == 4) {
+		} else if (_G(flags)[V094] == 4) {
 			_808PosMach = series_show("808pos1", 1281, 0, -1, -1, 4, 100, 0, 0);
 		} else {
 			_808PosMach = series_show("808pos1", 1281, 0, -1, -1, 0, 100, 0, 0);
@@ -1470,7 +1470,7 @@ void Room808::daemon() {
 		series_stream_break_on_frame(_808RipFallShovelNearSideMach, 21, 11);
 		digi_play("808_s02", 2, 255, -1, -1);
 
-		if (_G(flags[V097] == 0)) {
+		if (_G(flags)[V097] == 0) {
 			setGlobals3(_meiChienHandsBehindBackSeries, 17, 1);
 			sendWSMessage_3840000(_mcTrekMach, 16);
 		} else {
@@ -1486,7 +1486,7 @@ void Room808::daemon() {
 		series_stream_break_on_frame(_808RipFallShovelNearSideMach, 24, 11);
 		digi_play("808_s02", 2, 255, -1, -1);
 
-		if (_G(flags[V097] == 0)) {
+		if (_G(flags)[V097] == 0) {
 			setGlobals3(_meiChienHandsBehindBackSeries, 17, 1);
 			sendWSMessage_3840000(_mcTrekMach, 16);
 		} else {
@@ -1503,7 +1503,7 @@ void Room808::daemon() {
 		series_stream_break_on_frame(_808RipFallShovelNearSideMach, 24, 9);
 		digi_play("808_s02", 2, 255, -1, -1);
 
-		if (_G(flags[V097] == 0)) {
+		if (_G(flags)[V097] == 0) {
 			setGlobals3(_meiChienHandsBehindBackSeries, 17, 1);
 			sendWSMessage_3840000(_mcTrekMach, 16);
 		} else {
@@ -1525,7 +1525,7 @@ void Room808::daemon() {
 		break;
 
 	case 18:
-		if (_G(flags[V097] != 0))
+		if (_G(flags)[V097] != 0)
 			break;
 
 		if (!player_commands_allowed() || !checkStrings()) {
@@ -1753,7 +1753,7 @@ void Room808::setBridgeHotspots(int val1, bool activeFl) {
 		else
 			hotspot_set_active(_G(currentSceneDef).hotspots, "FARMER'S SHOVEL", true);
 
-		if (inv_object_in_scene("crank", 808) || _G(flags[V098]) != 0) {
+		if (inv_object_in_scene("crank", 808) || _G(flags)[V098] != 0) {
 			hotspot_set_active(_G(currentSceneDef).hotspots, "crank", false);
 			hotspot_set_active(_G(currentSceneDef).hotspots, "slot", true);
 		} else {
@@ -1792,7 +1792,7 @@ void Room808::setBridgeHotspots(int val1, bool activeFl) {
 		else
 			hotspot_set_active(_G(currentSceneDef).hotspots, "FARMER'S SHOVEL  ", true);
 
-		if (inv_object_in_scene("crank", 808) || _G(flags[V098]) != 0) {
+		if (inv_object_in_scene("crank", 808) || _G(flags)[V098] != 0) {
 			hotspot_set_active(_G(currentSceneDef).hotspots, "crank", false);
 			hotspot_set_active(_G(currentSceneDef).hotspots, "slot", true);
 		} else {
@@ -1813,7 +1813,7 @@ void Room808::setBridgeHotspots(int val1, bool activeFl) {
 		else
 			hotspot_set_active(_G(currentSceneDef).hotspots, "FARMER'S SHOVEL   ", true);
 
-		if (inv_object_in_scene("crank", 808) || _G(flags[V098]) != 0) {
+		if (inv_object_in_scene("crank", 808) || _G(flags)[V098] != 0) {
 			hotspot_set_active(_G(currentSceneDef).hotspots, "crank", false);
 			hotspot_set_active(_G(currentSceneDef).hotspots, "slot", true);
 		} else {
@@ -1835,7 +1835,7 @@ void Room808::setBridgeHotspots(int val1, bool activeFl) {
 		else
 			hotspot_set_active(_G(currentSceneDef).hotspots, "FARMER'S SHOVEL    ", true);
 
-		if (inv_object_in_scene("crank", 808) || _G(flags[V098]) != 0) {
+		if (inv_object_in_scene("crank", 808) || _G(flags)[V098] != 0) {
 			hotspot_set_active(_G(currentSceneDef).hotspots, "crank", false);
 			hotspot_set_active(_G(currentSceneDef).hotspots, "slot", true);
 		} else {
@@ -1892,15 +1892,15 @@ void Room808::addMcHotspot(int32 val1) {
 }
 
 void Room808::setPosMachInfo() {
-	if (_G(flags[V095])) {
+	if (_G(flags)[V095]) {
 		if (inv_object_in_scene("FARMER'S SHOVEL", 808)) {
-			switch (_G(flags[V094])) {
+			switch (_G(flags)[V094]) {
 			case 1:
 				_posMachName = "808spn16";
-				_G(flags[V095]) = 0;
+				_G(flags)[V095] = 0;
 				_posMachIndex = 0;
 				_posMachFrameNum = 13;
-				_G(flags[V094]) = 0;
+				_G(flags)[V094] = 0;
 
 				break;
 
@@ -1908,7 +1908,7 @@ void Room808::setPosMachInfo() {
 				_posMachName = "808spn15";
 				_posMachIndex = 6;
 				_posMachFrameNum = 13;
-				_G(flags[V094]) = 1;
+				_G(flags)[V094] = 1;
 
 				break;
 
@@ -1916,7 +1916,7 @@ void Room808::setPosMachInfo() {
 				_posMachName = "808spn14";
 				_posMachIndex = 4;
 				_posMachFrameNum = 17;
-				_G(flags[V094]) = 2;
+				_G(flags)[V094] = 2;
 
 				break;
 
@@ -1924,7 +1924,7 @@ void Room808::setPosMachInfo() {
 				_posMachName = "808spn13";
 				_posMachIndex = 3;
 				_posMachFrameNum = 13;
-				_G(flags[V094]) = 3;
+				_G(flags)[V094] = 3;
 
 				break;
 
@@ -1932,14 +1932,14 @@ void Room808::setPosMachInfo() {
 				break;
 			}
 		} else {
-			switch (_G(flags[V094])) {
+			switch (_G(flags)[V094]) {
 			case 1:
 				_posMachName = "808spn08";
 
-				_G(flags[V095]) = 0;
+				_G(flags)[V095] = 0;
 				_posMachIndex = 0;
 				_posMachFrameNum = 13;
-				_G(flags[V094]) = 0;
+				_G(flags)[V094] = 0;
 
 				break;
 
@@ -1947,7 +1947,7 @@ void Room808::setPosMachInfo() {
 				_posMachName = "808spn07";
 				_posMachIndex = 6;
 				_posMachFrameNum = 13;
-				_G(flags[V094]) = 1;
+				_G(flags)[V094] = 1;
 
 				break;
 
@@ -1955,7 +1955,7 @@ void Room808::setPosMachInfo() {
 				_posMachName = "808spn06";
 				_posMachIndex = 5;
 				_posMachFrameNum = 17;
-				_G(flags[V094]) = 2;
+				_G(flags)[V094] = 2;
 
 				break;
 
@@ -1963,7 +1963,7 @@ void Room808::setPosMachInfo() {
 				_posMachName = "808spn05";
 				_posMachIndex = 3;
 				_posMachFrameNum = 13;
-				_G(flags[V094]) = 3;
+				_G(flags)[V094] = 3;
 
 				break;
 
@@ -1973,12 +1973,12 @@ void Room808::setPosMachInfo() {
 		}
 	} else {
 		if (inv_object_in_scene("FARMER'S SHOVEL", 808)) {
-			switch (_G(flags[V094])) {
+			switch (_G(flags)[V094]) {
 			case 1:
 				_posMachName = "808spn09";
 				_posMachIndex = 1;
 				_posMachFrameNum = 13;
-				_G(flags[V094]) = 1;
+				_G(flags)[V094] = 1;
 
 				break;
 
@@ -1986,7 +1986,7 @@ void Room808::setPosMachInfo() {
 				_posMachName = "808spn10";
 				_posMachIndex = 2;
 				_posMachFrameNum = 13;
-				_G(flags[V094]) = 2;
+				_G(flags)[V094] = 2;
 
 				break;
 
@@ -1994,7 +1994,7 @@ void Room808::setPosMachInfo() {
 				_posMachName = "808spn11";
 				_posMachIndex = 3;
 				_posMachFrameNum = 13;
-				_G(flags[V094]) = 3;
+				_G(flags)[V094] = 3;
 
 				break;
 
@@ -2002,8 +2002,8 @@ void Room808::setPosMachInfo() {
 				_posMachName = "808spn12";
 				_posMachIndex = 5;
 				_posMachFrameNum = 10;
-				_G(flags[V094]) = 4;
-				_G(flags[V095]) = 1;
+				_G(flags)[V094] = 4;
+				_G(flags)[V095] = 1;
 
 				break;
 
@@ -2011,12 +2011,12 @@ void Room808::setPosMachInfo() {
 				break;
 			}
 		} else {
-			switch (_G(flags[V094])) {
+			switch (_G(flags)[V094]) {
 			case 1:
 				_posMachName = "808spn01";
 				_posMachIndex = 1;
 				_posMachFrameNum = 13;
-				_G(flags[V094]) = 1;
+				_G(flags)[V094] = 1;
 
 				break;
 
@@ -2024,7 +2024,7 @@ void Room808::setPosMachInfo() {
 				_posMachName = "808spn02";
 				_posMachIndex = 2;
 				_posMachFrameNum = 13;
-				_G(flags[V094]) = 2;
+				_G(flags)[V094] = 2;
 
 				break;
 
@@ -2032,7 +2032,7 @@ void Room808::setPosMachInfo() {
 				_posMachName = "808spn03";
 				_posMachIndex = 3;
 				_posMachFrameNum = 13;
-				_G(flags[V094]) = 3;
+				_G(flags)[V094] = 3;
 
 				break;
 
@@ -2040,8 +2040,8 @@ void Room808::setPosMachInfo() {
 				_posMachName = "808spn04";
 				_posMachIndex = 4;
 				_posMachFrameNum = 10;
-				_G(flags[V094]) = 4;
-				_G(flags[V095]) = 1;
+				_G(flags)[V094] = 4;
+				_G(flags)[V095] = 1;
 
 				break;
 
diff --git a/engines/m4/riddle/rooms/section8/room809.cpp b/engines/m4/riddle/rooms/section8/room809.cpp
index 78d4234f294..726af91250c 100644
--- a/engines/m4/riddle/rooms/section8/room809.cpp
+++ b/engines/m4/riddle/rooms/section8/room809.cpp
@@ -34,7 +34,7 @@ void Room809::preload() {
 }
 
 void Room809::init() {
-	if (_G(game).previous_room == KERNEL_RESTORING_GAME || _G(flags[V263]))
+	if (_G(game).previous_room == KERNEL_RESTORING_GAME || _G(flags)[V263])
 		digi_preload("950_s29", -1);
 
 	_field20 = 0;
@@ -103,8 +103,8 @@ void Room809::init() {
 		_field24 = 0;
 		_field28 = 160;
 
-		if (_G(flags[V263]) == 0) {
-			_G(flags[V263]) = 1;
+		if (_G(flags)[V263] == 0) {
+			_G(flags)[V263] = 1;
 
 			moveScreen(1280, 0);
 			_G(camera_reacts_to_player) = false;




More information about the Scummvm-git-logs mailing list