aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--simon/simon.cpp6
-rw-r--r--simon/simon.h6
2 files changed, 6 insertions, 6 deletions
diff --git a/simon/simon.cpp b/simon/simon.cpp
index 7b72d5dcba..56539bccb2 100644
--- a/simon/simon.cpp
+++ b/simon/simon.cpp
@@ -2420,7 +2420,7 @@ void SimonEngine::set_video_mode_internal(uint mode, uint vga_res_id) {
if (!(_game & GF_SIMON2)) {
if (_unk_pal_flag) {
_unk_pal_flag = false;
- while (*(volatile int *)&_palette_color_count != 0) {
+ while (_palette_color_count != 0) {
delay(10);
}
}
@@ -2432,7 +2432,7 @@ void SimonEngine::set_video_mode(uint mode, uint vga_res_id) {
lock();
if (_lock_word == 0) {
_sync_flag_1 = true;
- while ((*(volatile bool *)&_sync_flag_1) == true) {
+ while (_sync_flag_1) {
delay(10);
}
}
@@ -2440,7 +2440,7 @@ void SimonEngine::set_video_mode(uint mode, uint vga_res_id) {
_lock_word |= 0x20;
- while ((*(volatile uint16*)&_lock_word) & 2) {
+ while (_lock_word & 2) {
delay(10);
}
diff --git a/simon/simon.h b/simon/simon.h
index 49d92d7ab5..cc21a75b84 100644
--- a/simon/simon.h
+++ b/simon/simon.h
@@ -179,7 +179,7 @@ protected:
bool _vga_res_328_loaded;
bool _hitarea_unk_3;
bool _mortal_flag;
- bool _sync_flag_1;
+ volatile bool _sync_flag_1;
byte _video_var_8;
bool _use_palette_delay;
bool _sync_flag_2;
@@ -248,12 +248,12 @@ protected:
Item *_dummy_item_2;
Item *_dummy_item_3;
- uint16 _lock_word;
+ volatile uint16 _lock_word;
uint16 _scroll_up_hit_area;
uint16 _scroll_down_hit_area;
uint16 _video_var_7;
- uint16 _palette_color_count;
+ volatile uint16 _palette_color_count;
byte _video_var_4;
bool _video_var_5;