You've already forked pokecrystal-board
mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2025-09-08 08:13:02 -07:00
Identify more sprite move data flag bits
This commit is contained in:
@@ -93,7 +93,7 @@ Function437b: ; 437b
|
||||
.ok2
|
||||
ld hl, OBJECT_FLAGS1
|
||||
add hl, bc
|
||||
bit 1, [hl]
|
||||
bit WONT_DELETE_F, [hl]
|
||||
jr nz, .yes2
|
||||
call DeleteMapObject
|
||||
scf
|
||||
@@ -3063,7 +3063,7 @@ InitSprites: ; 5991
|
||||
ld e, [hl]
|
||||
inc hl
|
||||
ld a, [hFFC1]
|
||||
bit 2, e
|
||||
bit ABSOLUTE_TILE_ID_F, e
|
||||
jr z, .nope1
|
||||
xor a
|
||||
.nope1
|
||||
@@ -3072,7 +3072,7 @@ InitSprites: ; 5991
|
||||
ld [bc], a ; tile id
|
||||
inc c
|
||||
ld a, e
|
||||
bit 1, a
|
||||
bit RELATIVE_ATTRIBUTES_F, a
|
||||
jr z, .nope2
|
||||
ld a, [hFFC2]
|
||||
or e
|
||||
|
||||
@@ -7,31 +7,32 @@ Function6ec1: ; 6ec1
|
||||
|
||||
ld hl, OBJECT_FLAGS1
|
||||
add hl, bc
|
||||
bit 4, [hl] ; lost, uncomment next line to fix
|
||||
; jr nz, .resume
|
||||
bit NOCLIP_TILES_F, [hl] ; lost, uncomment next line to fix
|
||||
; jr nz, .noclip_tiles
|
||||
push hl
|
||||
push bc
|
||||
call Function6f2c
|
||||
call WillObjectBumpIntoLand
|
||||
pop bc
|
||||
pop hl
|
||||
ret c
|
||||
jr .resume
|
||||
jr .continue
|
||||
|
||||
.not_swimming
|
||||
ld hl, OBJECT_FLAGS1
|
||||
add hl, bc
|
||||
bit 4, [hl]
|
||||
jr nz, .resume
|
||||
bit NOCLIP_TILES_F, [hl]
|
||||
jr nz, .noclip_tiles
|
||||
push hl
|
||||
push bc
|
||||
call Function6f07
|
||||
call WillObjectBumpIntoWater
|
||||
pop bc
|
||||
pop hl
|
||||
ret c
|
||||
|
||||
.resume
|
||||
bit 6, [hl]
|
||||
jr nz, .bit_6
|
||||
.noclip_tiles
|
||||
.continue
|
||||
bit NOCLIP_OBJS_F, [hl]
|
||||
jr nz, .noclip_objs
|
||||
|
||||
push hl
|
||||
push bc
|
||||
@@ -40,9 +41,9 @@ Function6ec1: ; 6ec1
|
||||
pop hl
|
||||
ret c
|
||||
|
||||
.bit_6
|
||||
bit 5, [hl]
|
||||
jr nz, .bit_5
|
||||
.noclip_objs
|
||||
bit MOVE_ANYWHERE_F, [hl]
|
||||
jr nz, .move_anywhere
|
||||
push hl
|
||||
call HasObjectReachedMovementLimit
|
||||
pop hl
|
||||
@@ -53,13 +54,13 @@ Function6ec1: ; 6ec1
|
||||
pop hl
|
||||
ret c
|
||||
|
||||
.bit_5
|
||||
.move_anywhere
|
||||
and a
|
||||
ret
|
||||
; 6f07
|
||||
|
||||
|
||||
Function6f07: ; 6f07
|
||||
WillObjectBumpIntoWater: ; 6f07
|
||||
call Function6f5f
|
||||
ret c
|
||||
ld hl, OBJECT_NEXT_MAP_X
|
||||
@@ -78,12 +79,12 @@ Function6f07: ; 6f07
|
||||
ld d, a
|
||||
call GetTileCollision
|
||||
and a ; LANDTILE
|
||||
jr z, Function6f3e
|
||||
jr z, WillObjectBumpIntoTile
|
||||
scf
|
||||
ret
|
||||
; 6f2c
|
||||
|
||||
Function6f2c: ; 6f2c
|
||||
WillObjectBumpIntoLand: ; 6f2c
|
||||
call Function6f5f
|
||||
ret c
|
||||
ld hl, OBJECT_NEXT_TILE
|
||||
@@ -91,12 +92,12 @@ Function6f2c: ; 6f2c
|
||||
ld a, [hl]
|
||||
call GetTileCollision
|
||||
cp WATERTILE
|
||||
jr z, Function6f3e
|
||||
jr z, WillObjectBumpIntoTile
|
||||
scf
|
||||
ret
|
||||
; 6f3e
|
||||
|
||||
Function6f3e: ; 6f3e
|
||||
WillObjectBumpIntoTile: ; 6f3e
|
||||
ld hl, OBJECT_NEXT_TILE
|
||||
add hl, bc
|
||||
ld a, [hl]
|
||||
|
||||
Reference in New Issue
Block a user