diff options
Diffstat (limited to 'simon')
-rw-r--r-- | simon/debug.h | 32 | ||||
-rw-r--r-- | simon/simon.h | 16 | ||||
-rw-r--r-- | simon/vga.cpp | 40 |
3 files changed, 43 insertions, 45 deletions
diff --git a/simon/debug.h b/simon/debug.h index b94dde3e02..03c39ac648 100644 --- a/simon/debug.h +++ b/simon/debug.h @@ -995,8 +995,8 @@ const char *const simon1_video_opcode_name_table[] = { "|CLEAR_PATHFIND_ARRAY", /* 12 */ "d|DELAY", - "d|OFFSET_X", - "d|OFFSET_Y", + "d|SET_SPRITE_OFFSET_X", + "d|SET_SPRITE_OFFSET_Y", "d|IDENT_WAKEUP", /* 16 */ "d|IDENT_SLEEP", @@ -1006,8 +1006,8 @@ const char *const simon1_video_opcode_name_table[] = { /* 20 */ "dd|SET_CODE_WORD", "i|JUMP_IF_CODE_WORD", - "dd|SET_PALETTE", - "d|SET_PRIORITY", + "dd|SET_SPRITE_PALETTE", + "d|SET_SPRITE_PRIORITY", /* 24 */ "diid|SET_SPRITE_XY", "x|HALT_SPRITE", @@ -1025,7 +1025,7 @@ const char *const simon1_video_opcode_name_table[] = { "dd|VC35", /* 36 */ "dd|SAVELOAD_THING", - "v|OFFSET_Y_F", + "v|SET_SPRITE_OFFSET_Y", "v|SKIP_IF_VAR_ZERO", "vd|SET_VAR", /* 40 */ @@ -1035,8 +1035,8 @@ const char *const simon1_video_opcode_name_table[] = { "d|SKIP_IF_BIT_CLEAR", /* 44 */ "d|SKIP_IF_BIT_SET", - "v|SET_X_F", - "v|SET_Y_F", + "v|SET_SPRITE_X", + "v|SET_SPRITE_Y", "vv|ADD_VAR_F", /* 48 */ "|VC_48", @@ -1052,7 +1052,7 @@ const char *const simon1_video_opcode_name_table[] = { "|DUMMY_56", "|DUMMY_57", "|UNK_58", - "|SKIP_IF_VOICE", + "|SKIP_IF_NO_SPEECH", /* 60 */ "d|KILL_SPRITE", "ddd|INIT_SPRITE", @@ -1078,8 +1078,8 @@ const char *const simon2_video_opcode_name_table[] = { "|CLEAR_PATHFIND_ARRAY", /* 12 */ "b|DELAY", - "d|OFFSET_X", - "d|OFFSET_Y", + "d|SET_SPRITE_OFFSET_X", + "d|SET_SPRITE_OFFSET_Y", "d|IDENT_WAKEUP", /* 16 */ "d|IDENT_SLEEP", @@ -1089,8 +1089,8 @@ const char *const simon2_video_opcode_name_table[] = { /* 20 */ "dd|SET_CODE_WORD", "i|JUMP_IF_CODE_WORD", - "dd|SET_PALETTE", - "d|SET_PRIORITY", + "dd|SET_SPRITE_PALETTE", + "d|SET_SPRITE_PRIORITY", /* 24 */ "diid|SET_SPRITE_XY", "x|HALT_SPRITE", @@ -1108,7 +1108,7 @@ const char *const simon2_video_opcode_name_table[] = { "dd|VC35", /* 36 */ "dd|SAVELOAD_THING", - "v|OFFSET_Y_F", + "v|SET_SPRITE_OFFSET_Y", "v|SKIP_IF_VAR_ZERO", "vd|SET_VAR", /* 40 */ @@ -1118,8 +1118,8 @@ const char *const simon2_video_opcode_name_table[] = { "d|SKIP_IF_BIT_CLEAR", /* 44 */ "d|SKIP_IF_BIT_SET", - "v|SET_X_F", - "v|SET_Y_F", + "v|SET_SPRITE_X", + "v|SET_SPRITE_Y", "vv|ADD_VAR_F", /* 48 */ "|VC_48", @@ -1142,7 +1142,7 @@ const char *const simon2_video_opcode_name_table[] = { "|PALETTE_THING", "|PALETTE_THING_2", /* 64 */ - "|SKIP_IF_VOICE", + "|SKIP_IF_NO_SPEECH", "|PALETTE_THING_3", "|SKIP_IF_NZ", "|SKIP_IF_GE", diff --git a/simon/simon.h b/simon/simon.h index 5a336a7bc9..7bd4c41712 100644 --- a/simon/simon.h +++ b/simon/simon.h @@ -612,8 +612,8 @@ public: void vc_10_draw(); void vc_11_clear_pathfind_array(); void vc_12_delay(); - void vc_13_offset_x(); - void vc_14_offset_y(); + void vc_13_set_sprite_offset_x(); + void vc_14_set_sprite_offset_y(); void vc_15_wakeup_id(); void vc_16_sleep_on_id(); void vc_17_set_pathfind_item(); @@ -621,8 +621,8 @@ public: void vc_19_chain_to_script(); void vc_20_set_code_word(); void vc_21_jump_if_code_word(); - void vc_22_set_palette(); - void vc_23_set_priority(); + void vc_22_set_sprite_palette(); + void vc_23_set_sprite_priority(); void vc_24_set_sprite_xy(); void vc_25_halt_sprite(); void vc_26_set_window(); @@ -638,7 +638,7 @@ public: void vc_34_force_lock(); void vc_35(); void vc_36_saveload_thing(); - void vc_37_offset_y_f(); + void vc_37_set_sprite_offset_y(); void vc_38_skip_if_var_zero(); void vc_39_set_var(); void vc_40_var_add(); @@ -646,8 +646,8 @@ public: void vc_42_delay_if_not_eq(); void vc_43_skip_if_bit_clear(); void vc_44_skip_if_bit_set(); - void vc_45_set_x(); - void vc_46_set_y(); + void vc_45_set_sprite_x(); + void vc_46_set_sprite_y(); void vc_47_add_var_f(); void vc_48(); void vc_49_set_bit(); @@ -666,7 +666,7 @@ public: void vc_63_palette_thing_2(); // Simon2 specific Video Script Opcodes - void vc_64_skip_if_voice(); + void vc_64_skip_if_no_speech(); void vc_65_palette_thing_3(); void vc_66_skip_if_nz(); void vc_67_skip_if_ge(); diff --git a/simon/vga.cpp b/simon/vga.cpp index 8d7a81a52c..79e491b4d1 100644 --- a/simon/vga.cpp +++ b/simon/vga.cpp @@ -43,8 +43,8 @@ static const VgaOpcodeProc vga_opcode_table[] = { &SimonState::vc_10_draw, &SimonState::vc_11_clear_pathfind_array, &SimonState::vc_12_delay, - &SimonState::vc_13_offset_x, - &SimonState::vc_14_offset_y, + &SimonState::vc_13_set_sprite_offset_x, + &SimonState::vc_14_set_sprite_offset_y, &SimonState::vc_15_wakeup_id, &SimonState::vc_16_sleep_on_id, &SimonState::vc_17_set_pathfind_item, @@ -52,8 +52,8 @@ static const VgaOpcodeProc vga_opcode_table[] = { &SimonState::vc_19_chain_to_script, &SimonState::vc_20_set_code_word, &SimonState::vc_21_jump_if_code_word, - &SimonState::vc_22_set_palette, - &SimonState::vc_23_set_priority, + &SimonState::vc_22_set_sprite_palette, + &SimonState::vc_23_set_sprite_priority, &SimonState::vc_24_set_sprite_xy, &SimonState::vc_25_halt_sprite, &SimonState::vc_26_set_window, @@ -67,7 +67,7 @@ static const VgaOpcodeProc vga_opcode_table[] = { &SimonState::vc_34_force_lock, &SimonState::vc_35, &SimonState::vc_36_saveload_thing, - &SimonState::vc_37_offset_y_f, + &SimonState::vc_37_set_sprite_offset_y, &SimonState::vc_38_skip_if_var_zero, &SimonState::vc_39_set_var, &SimonState::vc_40_var_add, @@ -75,8 +75,8 @@ static const VgaOpcodeProc vga_opcode_table[] = { &SimonState::vc_42_delay_if_not_eq, &SimonState::vc_43_skip_if_bit_clear, &SimonState::vc_44_skip_if_bit_set, - &SimonState::vc_45_set_x, - &SimonState::vc_46_set_y, + &SimonState::vc_45_set_sprite_x, + &SimonState::vc_46_set_sprite_y, &SimonState::vc_47_add_var_f, &SimonState::vc_48, &SimonState::vc_49_set_bit, @@ -94,7 +94,7 @@ static const VgaOpcodeProc vga_opcode_table[] = { &SimonState::vc_61_sprite_change, &SimonState::vc_62_palette_thing, &SimonState::vc_63_palette_thing_2, - &SimonState::vc_64_skip_if_voice, + &SimonState::vc_64_skip_if_no_speech, &SimonState::vc_65_palette_thing_3, &SimonState::vc_66_skip_if_nz, &SimonState::vc_67_skip_if_ge, @@ -982,17 +982,15 @@ void SimonState::vc_12_delay() { _vc_ptr = (byte *)&vc_get_out_of_code; } -void SimonState::vc_13_offset_x() { +void SimonState::vc_13_set_sprite_offset_x() { VgaSprite *vsp = find_cur_sprite(); - int16 a = vc_read_next_word(); - vsp->x += a; + vsp->x += (int16)vc_read_next_word(); _vga_sprite_changed++; } -void SimonState::vc_14_offset_y() { +void SimonState::vc_14_set_sprite_offset_y() { VgaSprite *vsp = find_cur_sprite(); - int16 a = vc_read_next_word(); - vsp->y += a; + vsp->y += (int16)vc_read_next_word(); _vga_sprite_changed++; } @@ -1092,7 +1090,7 @@ void SimonState::vc_21_jump_if_code_word() { } } -void SimonState::vc_22_set_palette() { +void SimonState::vc_22_set_sprite_palette() { uint a = vc_read_next_word(); uint b = vc_read_next_word(); uint num = a == 0 ? 0x20 : 0x10; @@ -1116,7 +1114,7 @@ void SimonState::vc_22_set_palette() { _vga_sprite_changed++; } -void SimonState::vc_23_set_priority() { +void SimonState::vc_23_set_sprite_priority() { VgaSprite *vsp = find_cur_sprite(), *vus2; uint16 pri = vc_read_next_word(); VgaSprite bak; @@ -1347,7 +1345,7 @@ void SimonState::vc_36_saveload_thing() { } } -void SimonState::vc_37_offset_y_f() { +void SimonState::vc_37_set_sprite_offset_y() { VgaSprite *vsp = find_cur_sprite(); vsp->y += vc_read_var(vc_read_next_word()); _vga_sprite_changed++; @@ -1444,13 +1442,13 @@ void SimonState::vc_44_skip_if_bit_set() { } } -void SimonState::vc_45_set_x() { +void SimonState::vc_45_set_sprite_x() { VgaSprite *vsp = find_cur_sprite(); vsp->x = vc_read_var(vc_read_next_word()); _vga_sprite_changed++; } -void SimonState::vc_46_set_y() { +void SimonState::vc_46_set_sprite_y() { VgaSprite *vsp = find_cur_sprite(); vsp->y = vc_read_var(vc_read_next_word()); _vga_sprite_changed++; @@ -1601,7 +1599,7 @@ void SimonState::vc_58() { vc_ptr = _vc_ptr; _vc_ptr = (byte *)&tmp; - vc_23_set_priority(); + vc_23_set_sprite_priority(); _vc_ptr = vc_ptr; _vga_cur_sprite_id = sprite; @@ -1759,7 +1757,7 @@ void SimonState::vc_63_palette_thing_2() { _video_var_3 = false; } -void SimonState::vc_64_skip_if_voice() { +void SimonState::vc_64_skip_if_no_speech() { // Simon2 if (_sound->_voice_handle == 0) vc_skip_next_instruction(); |