mirror of
https://github.com/catseye/SixtyPical.git
synced 2024-11-22 01:32:13 +00:00
Save a few bytes in the demo game by using a for
loop.
This commit is contained in:
parent
7f38d04536
commit
a8a53e2ca9
@ -90,7 +90,7 @@ word delta
|
||||
vector logic_routine table[256] actor_logic
|
||||
vector logic_routine dispatch_logic
|
||||
|
||||
byte table[32] press_fire_msg: "PRESS`FIRE`TO`PLAY"
|
||||
byte table[18] press_fire_msg: "PRESS`FIRE`TO`PLAY"
|
||||
|
||||
//
|
||||
// Points to the routine that implements the current game state.
|
||||
@ -384,23 +384,14 @@ define enemy_logic logic_routine
|
||||
define game_state_title_screen game_state_routine
|
||||
{
|
||||
ld y, 0
|
||||
repeat {
|
||||
|
||||
// First we "clip" the index to 0-31 to ensure we don't
|
||||
// read outside the bounds of the table:
|
||||
ld a, y
|
||||
and a, 31
|
||||
ld y, a
|
||||
|
||||
for y up to 17 {
|
||||
ld a, press_fire_msg + y
|
||||
|
||||
st on, c
|
||||
sub a, 64 // yuck. oh well
|
||||
|
||||
st a, screen1 + y
|
||||
inc y
|
||||
cmp y, 18
|
||||
} until z
|
||||
}
|
||||
|
||||
st off, c
|
||||
call check_button
|
||||
|
Loading…
Reference in New Issue
Block a user