unit: Added stub for unit find at
authorLukas Krickl <lukas@krickl.dev>
Thu, 14 Aug 2025 04:54:01 +0000 (06:54 +0200)
committerLukas Krickl <lukas@krickl.dev>
Thu, 14 Aug 2025 04:54:01 +0000 (06:54 +0200)
src/battle.s
src/unit.s

index 6d4c2d10b910db118c0ba5926e72df46a49cacdd..bfa1618fdcec9e6be93d7dd94f4b7347687391a1 100644 (file)
@@ -9,8 +9,11 @@
        ; inputs:
        ;               de: player actor
 battle_enter:
+       call unit_find_at
        ret
 
+
+
        ; exits battle mode
        ; and reloads the map
        ; without re-generating it.
index 7537776b868d868aa1b312d1b5927aeab9040017..7fc1d74b432abf840ee6d4793ceeb104a8b47e16 100644 (file)
@@ -790,6 +790,14 @@ unit_set_draw:
        ld a, b 
        ld [hl], a
        ret
+       
+       ; finds a unit at a specific location
+       ; inputs:
+       ;               bc: y/x
+       ;       returns:
+       ;               hl: unit ptr or NULL if not found
+unit_find_at:
+       ret
 
 st_unit_idle:
   st_def 0x00, unit_idle, st_unit_idle