This means all tile moves are the same speed for both player and
enemies. The AI script will determine when to move for enemies later on.
This will allow choosing between a more real time and a more tactical
gameplay style.
#define WRAM 0xC000
#define WRAMLEN 0xFFF
-#define STAT_MAX 100
+#define STAT_MAX 255
+
+; game speed defs
+#define GAME_SPEED_SLOW 128
+#define GAME_SPEED_NORMAL 235
+#define GAME_SPEED_FAST 255
+
+#define GAME_SPEED_DEFAULT GAME_SPEED_NORMAL
#define NULL 0
ld bc, st_size
call memcpy
+
+ ; set up default game speed
+ ld a, GAME_SPEED_DEFAULT
+ ld [game_speed], a
+
; load a demo
; ld hl, demo_inputs1
; call load_demo_ptr
; returns:
; a: speed stat
stat_calc_speed:
- ld hl, act_dex
- add hl, de ; hl = speed stat
- ld a, [hl]
+ ld a, [game_speed]
ret
; seed must never be 0
srand: .adv 2
+ ; game speed variable
+ ; this controls how fast the
+ ; game runs
+game_speed: .adv 1
+
; last d16 result
d16: .adv 1
scroll_move_y: .adv 1
scroll_move_x: .adv 1
+ ; the current floor
+floor: .adv 1
+
; scroll location
scroll_y: .adv 1
scroll_x: .adv 1