aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.nasm/segments.txt2
-rw-r--r--src/items.s14
2 files changed, 10 insertions, 6 deletions
diff --git a/.nasm/segments.txt b/.nasm/segments.txt
index 2d03c64..a741401 100644
--- a/.nasm/segments.txt
+++ b/.nasm/segments.txt
@@ -1,4 +1,4 @@
- HEADER: 16/16 (100%)
-- ROM0: 9114/32762 (27.82%)
+- ROM0: 9120/32762 (27.84%)
- ROMV: 6/6 (100%)
- ROM2: 8192/8192 (100%)
diff --git a/src/items.s b/src/items.s
index 164d5b7..9ad1aba 100644
--- a/src/items.s
+++ b/src/items.s
@@ -130,7 +130,9 @@
.proc init_level
ldx #0
- lda Globals::zp_level_kind
+ ;; We have to re-assemble the shuttle every 4 stages.
+ lda Globals::zp_level
+ and #$03
bne @other_screens
;; Zero out the state except for the 'C' bit.
@@ -640,9 +642,10 @@
bit Items::zp_state
bmi @next
- ;; We don't need extra precautions except when the level kind is the
- ;; first one. In that case we must guarantee the right shuttle order.
- lda Globals::zp_level_kind
+ ;; We don't need extra precautions except when we are re-arrenging the
+ ;; shuttle. In that case we must guarantee the right shuttle order.
+ lda Globals::zp_level
+ and #$03
bne @do_follow_player
;; Is this the first shuttle part to be collected?
@@ -1005,7 +1008,8 @@
.proc prepare_background_scene
jsr draw_low_part_shuttle
- lda Globals::zp_level_kind
+ lda Globals::zp_level
+ and #$03
beq @end
@rest_of_the_rocket: