mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2024-09-09 09:51:34 -07:00
Merge branch 'master' of https://github.com/PikalaxALT/pokecrystal into PikalaxALT-master
This commit is contained in:
commit
65c38930a3
@ -258,21 +258,21 @@ UpdateChannels: ; e8125
|
|||||||
.asm_e8159
|
.asm_e8159
|
||||||
bit NOTE_REST, [hl] ; rest
|
bit NOTE_REST, [hl] ; rest
|
||||||
jr nz, .ch1rest
|
jr nz, .ch1rest
|
||||||
bit NOTE_UNKN_4, [hl]
|
bit NOTE_NOISE_SAMPLING, [hl]
|
||||||
jr nz, .asm_e81a2
|
jr nz, .asm_e81a2
|
||||||
bit NOTE_UNKN_1, [hl]
|
bit NOTE_FREQ_OVERRIDE, [hl]
|
||||||
jr nz, .asm_e816b
|
jr nz, .frequency_override
|
||||||
bit NOTE_UNKN_6, [hl]
|
bit NOTE_VIBRATO_OVERRIDE, [hl]
|
||||||
jr nz, .asm_e8184
|
jr nz, .asm_e8184
|
||||||
jr .asm_e8175
|
jr .check_duty_override
|
||||||
|
|
||||||
.asm_e816b
|
.frequency_override
|
||||||
ld a, [wCurTrackFrequency]
|
ld a, [wCurTrackFrequency]
|
||||||
ld [rNR13], a
|
ld [rNR13], a
|
||||||
ld a, [wCurTrackFrequency + 1]
|
ld a, [wCurTrackFrequency + 1]
|
||||||
ld [rNR14], a
|
ld [rNR14], a
|
||||||
.asm_e8175
|
.check_duty_override
|
||||||
bit NOTE_UNKN_0, [hl]
|
bit NOTE_DUTY_OVERRIDE, [hl]
|
||||||
ret z
|
ret z
|
||||||
ld a, [wCurTrackDuty]
|
ld a, [wCurTrackDuty]
|
||||||
ld d, a
|
ld d, a
|
||||||
@ -321,11 +321,11 @@ UpdateChannels: ; e8125
|
|||||||
add hl, bc
|
add hl, bc
|
||||||
bit NOTE_REST, [hl] ; rest
|
bit NOTE_REST, [hl] ; rest
|
||||||
jr nz, .ch2rest
|
jr nz, .ch2rest
|
||||||
bit NOTE_UNKN_4, [hl]
|
bit NOTE_NOISE_SAMPLING, [hl]
|
||||||
jr nz, .asm_e8204
|
jr nz, .asm_e8204
|
||||||
bit NOTE_UNKN_6, [hl]
|
bit NOTE_VIBRATO_OVERRIDE, [hl]
|
||||||
jr nz, .asm_e81e6
|
jr nz, .asm_e81e6
|
||||||
bit NOTE_UNKN_0, [hl]
|
bit NOTE_DUTY_OVERRIDE, [hl]
|
||||||
ret z
|
ret z
|
||||||
ld a, [wCurTrackDuty]
|
ld a, [wCurTrackDuty]
|
||||||
ld d, a
|
ld d, a
|
||||||
@ -381,9 +381,9 @@ UpdateChannels: ; e8125
|
|||||||
add hl, bc
|
add hl, bc
|
||||||
bit NOTE_REST, [hl] ; rest
|
bit NOTE_REST, [hl] ; rest
|
||||||
jr nz, .ch3rest
|
jr nz, .ch3rest
|
||||||
bit NOTE_UNKN_4, [hl]
|
bit NOTE_NOISE_SAMPLING, [hl]
|
||||||
jr nz, .asm_e824d
|
jr nz, .asm_e824d
|
||||||
bit NOTE_UNKN_6, [hl]
|
bit NOTE_VIBRATO_OVERRIDE, [hl]
|
||||||
jr nz, .asm_e823a
|
jr nz, .asm_e823a
|
||||||
ret
|
ret
|
||||||
|
|
||||||
@ -482,7 +482,7 @@ endr
|
|||||||
add hl, bc
|
add hl, bc
|
||||||
bit NOTE_REST, [hl] ; rest
|
bit NOTE_REST, [hl] ; rest
|
||||||
jr nz, .ch4rest
|
jr nz, .ch4rest
|
||||||
bit NOTE_UNKN_4, [hl]
|
bit NOTE_NOISE_SAMPLING, [hl]
|
||||||
jr nz, .asm_e82d4
|
jr nz, .asm_e82d4
|
||||||
ret
|
ret
|
||||||
|
|
||||||
@ -853,7 +853,7 @@ HandleTrackVibrato: ; e8466
|
|||||||
ld [wCurTrackDuty], a
|
ld [wCurTrackDuty], a
|
||||||
ld hl, Channel1NoteFlags - Channel1
|
ld hl, Channel1NoteFlags - Channel1
|
||||||
add hl, bc
|
add hl, bc
|
||||||
set NOTE_UNKN_0, [hl]
|
set NOTE_DUTY_OVERRIDE, [hl]
|
||||||
.next
|
.next
|
||||||
ld hl, Channel1Flags2 - Channel1
|
ld hl, Channel1Flags2 - Channel1
|
||||||
add hl, bc
|
add hl, bc
|
||||||
@ -930,9 +930,9 @@ HandleTrackVibrato: ; e8466
|
|||||||
ld d, a
|
ld d, a
|
||||||
ld a, e
|
ld a, e
|
||||||
sub d
|
sub d
|
||||||
jr nc, .asm_e84ef
|
jr nc, .no_carry
|
||||||
ld a, 0
|
ld a, 0
|
||||||
jr .asm_e84ef
|
jr .no_carry
|
||||||
|
|
||||||
.down
|
.down
|
||||||
; vibrato up
|
; vibrato up
|
||||||
@ -943,14 +943,14 @@ HandleTrackVibrato: ; e8466
|
|||||||
swap a ; move it to lo
|
swap a ; move it to lo
|
||||||
;
|
;
|
||||||
add e
|
add e
|
||||||
jr nc, .asm_e84ef
|
jr nc, .no_carry
|
||||||
ld a, $ff
|
ld a, $ff
|
||||||
.asm_e84ef
|
.no_carry
|
||||||
ld [wCurTrackFrequency], a
|
ld [wCurTrackFrequency], a
|
||||||
;
|
;
|
||||||
ld hl, Channel1NoteFlags - Channel1
|
ld hl, Channel1NoteFlags - Channel1
|
||||||
add hl, bc
|
add hl, bc
|
||||||
set NOTE_UNKN_6, [hl]
|
set NOTE_VIBRATO_OVERRIDE, [hl]
|
||||||
.quit
|
.quit
|
||||||
ret
|
ret
|
||||||
|
|
||||||
@ -1067,8 +1067,8 @@ ApplyPitchWheel: ; e84f9
|
|||||||
ld [hl], d
|
ld [hl], d
|
||||||
ld hl, Channel1NoteFlags - Channel1
|
ld hl, Channel1NoteFlags - Channel1
|
||||||
add hl, bc
|
add hl, bc
|
||||||
set NOTE_UNKN_1, [hl]
|
set NOTE_FREQ_OVERRIDE, [hl]
|
||||||
set NOTE_UNKN_0, [hl]
|
set NOTE_DUTY_OVERRIDE, [hl]
|
||||||
ret
|
ret
|
||||||
|
|
||||||
; e858c
|
; e858c
|
||||||
@ -1145,7 +1145,7 @@ ReadNoiseSample: ; e85af
|
|||||||
|
|
||||||
ld hl, Channel1NoteFlags - Channel1
|
ld hl, Channel1NoteFlags - Channel1
|
||||||
add hl, bc
|
add hl, bc
|
||||||
set NOTE_UNKN_4, [hl]
|
set NOTE_NOISE_SAMPLING, [hl]
|
||||||
ret
|
ret
|
||||||
|
|
||||||
.quit
|
.quit
|
||||||
@ -1206,7 +1206,7 @@ ParseMusic: ; e85e1
|
|||||||
; ????
|
; ????
|
||||||
ld hl, Channel1NoteFlags - Channel1
|
ld hl, Channel1NoteFlags - Channel1
|
||||||
add hl, bc
|
add hl, bc
|
||||||
set NOTE_UNKN_4, [hl]
|
set NOTE_NOISE_SAMPLING, [hl]
|
||||||
jp LoadNote
|
jp LoadNote
|
||||||
|
|
||||||
.rest
|
.rest
|
||||||
@ -1288,7 +1288,7 @@ ParseSFXOrRest: ; e8698
|
|||||||
; turn noise sampling on
|
; turn noise sampling on
|
||||||
ld hl, Channel1NoteFlags - Channel1
|
ld hl, Channel1NoteFlags - Channel1
|
||||||
add hl, bc
|
add hl, bc
|
||||||
set NOTE_UNKN_4, [hl] ; noise sample
|
set NOTE_NOISE_SAMPLING, [hl] ; noise sample
|
||||||
; update note duration
|
; update note duration
|
||||||
ld a, [CurMusicByte]
|
ld a, [CurMusicByte]
|
||||||
call SetNoteDuration ; top nybble doesnt matter?
|
call SetNoteDuration ; top nybble doesnt matter?
|
||||||
|
@ -55,9 +55,9 @@ SOUND_VIBRATO_DIR EQU 0
|
|||||||
SOUND_PITCH_WHEEL_DIR EQU 1
|
SOUND_PITCH_WHEEL_DIR EQU 1
|
||||||
|
|
||||||
; NoteFlags
|
; NoteFlags
|
||||||
NOTE_UNKN_0 EQU 0
|
NOTE_DUTY_OVERRIDE EQU 0
|
||||||
NOTE_UNKN_1 EQU 1
|
NOTE_FREQ_OVERRIDE EQU 1
|
||||||
NOTE_UNKN_3 EQU 3
|
NOTE_UNKN_3 EQU 3
|
||||||
NOTE_UNKN_4 EQU 4
|
NOTE_NOISE_SAMPLING EQU 4
|
||||||
NOTE_REST EQU 5
|
NOTE_REST EQU 5
|
||||||
NOTE_UNKN_6 EQU 6
|
NOTE_VIBRATO_OVERRIDE EQU 6
|
||||||
|
@ -230,8 +230,7 @@ NUM_SPRITEHEADER_FIELDS EQU const_value
|
|||||||
const SPRITEMOVEDATA_BOULDERDUST ; 22
|
const SPRITEMOVEDATA_BOULDERDUST ; 22
|
||||||
const SPRITEMOVEDATA_GRASS ; 23
|
const SPRITEMOVEDATA_GRASS ; 23
|
||||||
const SPRITEMOVEDATA_LAPRAS ; 24
|
const SPRITEMOVEDATA_LAPRAS ; 24
|
||||||
const SPRITEMOVEDATA_25 ; 25
|
NUM_SPRITEMOVEDATA EQU const_value
|
||||||
NUM_SPRITEMOVEDATA EQU const_value +- 1
|
|
||||||
SPRITEMOVEDATA_FIELDS EQU 6
|
SPRITEMOVEDATA_FIELDS EQU 6
|
||||||
|
|
||||||
; sprite movement functions
|
; sprite movement functions
|
||||||
@ -303,50 +302,50 @@ MAX_OUTDOOR_SPRITES EQU 23
|
|||||||
const PERSON_ACTION_SPIN
|
const PERSON_ACTION_SPIN
|
||||||
const PERSON_ACTION_SPIN_FLICKER
|
const PERSON_ACTION_SPIN_FLICKER
|
||||||
const PERSON_ACTION_FISHING
|
const PERSON_ACTION_FISHING
|
||||||
const PERSON_ACTION_07
|
const PERSON_ACTION_SHADOW
|
||||||
const PERSON_ACTION_EMOTE
|
const PERSON_ACTION_EMOTE
|
||||||
const PERSON_ACTION_09
|
const PERSON_ACTION_BIG_SNORLAX
|
||||||
const PERSON_ACTION_0A
|
const PERSON_ACTION_BOUNCE
|
||||||
const PERSON_ACTION_0B
|
const PERSON_ACTION_WEIRD_TREE
|
||||||
const PERSON_ACTION_0C
|
const PERSON_ACTION_BIG_LAPRAS
|
||||||
const PERSON_ACTION_0D
|
const PERSON_ACTION_BIG_DOLL
|
||||||
const PERSON_ACTION_0E
|
const PERSON_ACTION_BOULDER_DUST
|
||||||
const PERSON_ACTION_0F
|
const PERSON_ACTION_GRASS_SHAKE
|
||||||
const PERSON_ACTION_10
|
const PERSON_ACTION_SKYFALL
|
||||||
|
|
||||||
const_def
|
const_def
|
||||||
const FACING_00
|
const FACING_STEP_DOWN_0
|
||||||
const FACING_01
|
const FACING_STEP_DOWN_1
|
||||||
const FACING_02
|
const FACING_STEP_DOWN_2
|
||||||
const FACING_03
|
const FACING_STEP_DOWN_3
|
||||||
const FACING_04
|
const FACING_STEP_UP_0
|
||||||
const FACING_05
|
const FACING_STEP_UP_1
|
||||||
const FACING_06
|
const FACING_STEP_UP_2
|
||||||
const FACING_07
|
const FACING_STEP_UP_3
|
||||||
const FACING_08
|
const FACING_STEP_LEFT_0
|
||||||
const FACING_09
|
const FACING_STEP_LEFT_1
|
||||||
const FACING_0A
|
const FACING_STEP_LEFT_2
|
||||||
const FACING_0B
|
const FACING_STEP_LEFT_3
|
||||||
const FACING_0C
|
const FACING_STEP_RIGHT_0
|
||||||
const FACING_0D
|
const FACING_STEP_RIGHT_1
|
||||||
const FACING_0E
|
const FACING_STEP_RIGHT_2
|
||||||
const FACING_0F
|
const FACING_STEP_RIGHT_3
|
||||||
const FACING_10
|
const FACING_FISH_DOWN
|
||||||
const FACING_11
|
const FACING_FISH_UP
|
||||||
const FACING_12
|
const FACING_FISH_LEFT
|
||||||
const FACING_13
|
const FACING_FISH_RIGHT
|
||||||
const FACING_EMOTE
|
const FACING_EMOTE
|
||||||
const FACING_15
|
const FACING_SHADOW
|
||||||
const FACING_16
|
const FACING_BIG_DOLL_ASYM
|
||||||
const FACING_17
|
const FACING_BIG_DOLL_SYM
|
||||||
const FACING_18
|
const FACING_WEIRD_TREE_0
|
||||||
const FACING_19
|
const FACING_WEIRD_TREE_1
|
||||||
const FACING_1A
|
const FACING_WEIRD_TREE_2
|
||||||
const FACING_1B
|
const FACING_WEIRD_TREE_3
|
||||||
const FACING_1C
|
const FACING_BOULDER_DUST_1
|
||||||
const FACING_1D
|
const FACING_BOULDER_DUST_2
|
||||||
const FACING_1E
|
const FACING_GRASS_1
|
||||||
const FACING_1F
|
const FACING_GRASS_2
|
||||||
|
|
||||||
const_def
|
const_def
|
||||||
const SPRITEANIMSTRUCT_INDEX ; 0
|
const SPRITEANIMSTRUCT_INDEX ; 0
|
||||||
|
@ -3,42 +3,42 @@ sprite_movement_data: macro
|
|||||||
dn \6, 0
|
dn \6, 0
|
||||||
endm
|
endm
|
||||||
|
|
||||||
; function, facing, action, flags1, flags2, palette flags
|
; function, facing, action, flags1, flags2, palette flags
|
||||||
sprite_movement_data SPRITEMOVEFN_00, DOWN, PERSON_ACTION_STAND, $02, $00, %0000 ; 00
|
sprite_movement_data SPRITEMOVEFN_00, DOWN, PERSON_ACTION_STAND, $02, $00, %0000 ; 00
|
||||||
sprite_movement_data SPRITEMOVEFN_STANDING, DOWN, PERSON_ACTION_STAND, $0c, $00, %0000 ; 01
|
sprite_movement_data SPRITEMOVEFN_STANDING, DOWN, PERSON_ACTION_STAND, $0c, $00, %0000 ; 01
|
||||||
sprite_movement_data SPRITEMOVEFN_RANDOM_WALK_XY, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 02
|
sprite_movement_data SPRITEMOVEFN_RANDOM_WALK_XY, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 02
|
||||||
sprite_movement_data SPRITEMOVEFN_SLOW_RANDOM_SPIN, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 03
|
sprite_movement_data SPRITEMOVEFN_SLOW_RANDOM_SPIN, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 03
|
||||||
sprite_movement_data SPRITEMOVEFN_RANDOM_WALK_Y, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 04
|
sprite_movement_data SPRITEMOVEFN_RANDOM_WALK_Y, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 04
|
||||||
sprite_movement_data SPRITEMOVEFN_RANDOM_WALK_X, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 05
|
sprite_movement_data SPRITEMOVEFN_RANDOM_WALK_X, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 05
|
||||||
sprite_movement_data SPRITEMOVEFN_STANDING, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 06
|
sprite_movement_data SPRITEMOVEFN_STANDING, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 06
|
||||||
sprite_movement_data SPRITEMOVEFN_STANDING, UP, PERSON_ACTION_STAND, $00, $00, %0000 ; 07
|
sprite_movement_data SPRITEMOVEFN_STANDING, UP, PERSON_ACTION_STAND, $00, $00, %0000 ; 07
|
||||||
sprite_movement_data SPRITEMOVEFN_STANDING, LEFT, PERSON_ACTION_STAND, $00, $00, %0000 ; 08
|
sprite_movement_data SPRITEMOVEFN_STANDING, LEFT, PERSON_ACTION_STAND, $00, $00, %0000 ; 08
|
||||||
sprite_movement_data SPRITEMOVEFN_STANDING, RIGHT, PERSON_ACTION_STAND, $00, $00, %0000 ; 09
|
sprite_movement_data SPRITEMOVEFN_STANDING, RIGHT, PERSON_ACTION_STAND, $00, $00, %0000 ; 09
|
||||||
sprite_movement_data SPRITEMOVEFN_FAST_RANDOM_SPIN, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 0a
|
sprite_movement_data SPRITEMOVEFN_FAST_RANDOM_SPIN, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 0a
|
||||||
sprite_movement_data SPRITEMOVEFN_OBEY_DPAD, DOWN, PERSON_ACTION_STAND, $02, $00, %0000 ; 0b
|
sprite_movement_data SPRITEMOVEFN_OBEY_DPAD, DOWN, PERSON_ACTION_STAND, $02, $00, %0000 ; 0b
|
||||||
sprite_movement_data SPRITEMOVEFN_08, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 0c
|
sprite_movement_data SPRITEMOVEFN_08, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 0c
|
||||||
sprite_movement_data SPRITEMOVEFN_09, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 0d
|
sprite_movement_data SPRITEMOVEFN_09, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 0d
|
||||||
sprite_movement_data SPRITEMOVEFN_0A, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 0e
|
sprite_movement_data SPRITEMOVEFN_0A, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 0e
|
||||||
sprite_movement_data SPRITEMOVEFN_0B, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 0f
|
sprite_movement_data SPRITEMOVEFN_0B, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 0f
|
||||||
sprite_movement_data SPRITEMOVEFN_0C, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 10
|
sprite_movement_data SPRITEMOVEFN_0C, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 10
|
||||||
sprite_movement_data SPRITEMOVEFN_0D, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 11
|
sprite_movement_data SPRITEMOVEFN_0D, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 11
|
||||||
sprite_movement_data SPRITEMOVEFN_0E, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 12
|
sprite_movement_data SPRITEMOVEFN_0E, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 12
|
||||||
sprite_movement_data SPRITEMOVEFN_FOLLOW, DOWN, PERSON_ACTION_STAND, $02, $00, %0000 ; 13
|
sprite_movement_data SPRITEMOVEFN_FOLLOW, DOWN, PERSON_ACTION_STAND, $02, $00, %0000 ; 13
|
||||||
sprite_movement_data SPRITEMOVEFN_SCRIPTED, DOWN, PERSON_ACTION_STAND, $02, $00, %0000 ; 14
|
sprite_movement_data SPRITEMOVEFN_SCRIPTED, DOWN, PERSON_ACTION_STAND, $02, $00, %0000 ; 14
|
||||||
sprite_movement_data SPRITEMOVEFN_BIG_SNORLAX, DOWN, PERSON_ACTION_09, $2e, $01, %1100 ; 15
|
sprite_movement_data SPRITEMOVEFN_BIG_SNORLAX, DOWN, PERSON_ACTION_BIG_SNORLAX, $2e, $01, %1100 ; 15
|
||||||
sprite_movement_data SPRITEMOVEFN_BOUNCE, DOWN, PERSON_ACTION_0A, $2e, $00, %0000 ; 16
|
sprite_movement_data SPRITEMOVEFN_BOUNCE, DOWN, PERSON_ACTION_BOUNCE, $2e, $00, %0000 ; 16
|
||||||
sprite_movement_data SPRITEMOVEFN_STANDING, DOWN, PERSON_ACTION_STAND, $0c, $00, %0000 ; 17
|
sprite_movement_data SPRITEMOVEFN_STANDING, DOWN, PERSON_ACTION_STAND, $0c, $00, %0000 ; 17
|
||||||
sprite_movement_data SPRITEMOVEFN_STANDING, DOWN, PERSON_ACTION_STAND, $2e, $10, %0000 ; 18
|
sprite_movement_data SPRITEMOVEFN_STANDING, DOWN, PERSON_ACTION_STAND, $2e, $10, %0000 ; 18
|
||||||
sprite_movement_data SPRITEMOVEFN_STRENGTH, DOWN, PERSON_ACTION_STAND, $2e, $00, %0100 ; 19
|
sprite_movement_data SPRITEMOVEFN_STRENGTH, DOWN, PERSON_ACTION_STAND, $2e, $00, %0100 ; 19
|
||||||
sprite_movement_data SPRITEMOVEFN_FOLLOWNOTEXACT, DOWN, PERSON_ACTION_STAND, $02, $00, %0000 ; 1a
|
sprite_movement_data SPRITEMOVEFN_FOLLOWNOTEXACT, DOWN, PERSON_ACTION_STAND, $02, $00, %0000 ; 1a
|
||||||
sprite_movement_data SPRITEMOVEFN_SHADOW, DOWN, PERSON_ACTION_00, $8e, $01, %0000 ; 1b
|
sprite_movement_data SPRITEMOVEFN_SHADOW, DOWN, PERSON_ACTION_00, $8e, $01, %0000 ; 1b
|
||||||
sprite_movement_data SPRITEMOVEFN_EMOTE, DOWN, PERSON_ACTION_EMOTE, $8e, $02, %0000 ; 1c
|
sprite_movement_data SPRITEMOVEFN_EMOTE, DOWN, PERSON_ACTION_EMOTE, $8e, $02, %0000 ; 1c
|
||||||
sprite_movement_data SPRITEMOVEFN_SCREENSHAKE, DOWN, PERSON_ACTION_00, $82, $00, %0000 ; 1d
|
sprite_movement_data SPRITEMOVEFN_SCREENSHAKE, DOWN, PERSON_ACTION_00, $82, $00, %0000 ; 1d
|
||||||
sprite_movement_data SPRITEMOVEFN_SPIN_COUNTERCLOCKWISE, LEFT, PERSON_ACTION_STAND, $00, $00, %0000 ; 1e
|
sprite_movement_data SPRITEMOVEFN_SPIN_COUNTERCLOCKWISE, LEFT, PERSON_ACTION_STAND, $00, $00, %0000 ; 1e
|
||||||
sprite_movement_data SPRITEMOVEFN_SPIN_CLOCKWISE, RIGHT, PERSON_ACTION_STAND, $00, $00, %0000 ; 1f
|
sprite_movement_data SPRITEMOVEFN_SPIN_CLOCKWISE, RIGHT, PERSON_ACTION_STAND, $00, $00, %0000 ; 1f
|
||||||
sprite_movement_data SPRITEMOVEFN_STRENGTH, DOWN, PERSON_ACTION_0C, $2e, $01, %1100 ; 20
|
sprite_movement_data SPRITEMOVEFN_STRENGTH, DOWN, PERSON_ACTION_BIG_LAPRAS, $2e, $01, %1100 ; 20
|
||||||
sprite_movement_data SPRITEMOVEFN_STRENGTH, DOWN, PERSON_ACTION_0D, $2e, $01, %1100 ; 21
|
sprite_movement_data SPRITEMOVEFN_STRENGTH, DOWN, PERSON_ACTION_BIG_DOLL, $2e, $01, %1100 ; 21
|
||||||
sprite_movement_data SPRITEMOVEFN_BOULDERDUST, DOWN, PERSON_ACTION_0E, $8e, $01, %0000 ; 22
|
sprite_movement_data SPRITEMOVEFN_BOULDERDUST, DOWN, PERSON_ACTION_BOULDER_DUST, $8e, $01, %0000 ; 22
|
||||||
sprite_movement_data SPRITEMOVEFN_GRASS, DOWN, PERSON_ACTION_0F, $8e, $02, %0000 ; 23
|
sprite_movement_data SPRITEMOVEFN_GRASS, DOWN, PERSON_ACTION_GRASS_SHAKE, $8e, $02, %0000 ; 23
|
||||||
sprite_movement_data SPRITEMOVEFN_RANDOM_WALK_XY, DOWN, PERSON_ACTION_STAND, $00, $00, %0010 ; 24
|
sprite_movement_data SPRITEMOVEFN_RANDOM_WALK_XY, DOWN, PERSON_ACTION_STAND, $00, $00, %0010 ; 24
|
||||||
sprite_movement_data SPRITEMOVEFN_00, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 25
|
sprite_movement_data SPRITEMOVEFN_00, DOWN, PERSON_ACTION_STAND, $00, $00, %0000 ; 25
|
||||||
|
@ -1,36 +1,36 @@
|
|||||||
Facings: ; 4049
|
Facings: ; 4049
|
||||||
dw Facing00
|
dw FacingStepDown0
|
||||||
dw Facing01
|
dw FacingStepDown1
|
||||||
dw Facing02
|
dw FacingStepDown2
|
||||||
dw Facing03
|
dw FacingStepDown3
|
||||||
dw Facing04
|
dw FacingStepUp0
|
||||||
dw Facing05
|
dw FacingStepUp1
|
||||||
dw Facing06
|
dw FacingStepUp2
|
||||||
dw Facing07
|
dw FacingStepUp3
|
||||||
dw Facing08
|
dw FacingStepLeft0
|
||||||
dw Facing09
|
dw FacingStepLeft1
|
||||||
dw Facing10
|
dw FacingStepLeft2
|
||||||
dw Facing11
|
dw FacingStepLeft3
|
||||||
dw Facing12
|
dw FacingStepRight0
|
||||||
dw Facing13
|
dw FacingStepRight1
|
||||||
dw Facing14
|
dw FacingStepRight2
|
||||||
dw Facing15
|
dw FacingStepRight3
|
||||||
dw Facing16
|
dw FacingFishDown
|
||||||
dw Facing17
|
dw FacingFishUp
|
||||||
dw Facing18
|
dw FacingFishLeft
|
||||||
dw Facing19
|
dw FacingFishRight
|
||||||
dw Facing20
|
dw FacingEmote
|
||||||
dw Facing21
|
dw FacingShadow
|
||||||
dw Facing22
|
dw FacingBigDollAsymmetric
|
||||||
dw Facing23
|
dw FacingBigDollSymmetric
|
||||||
dw Facing24
|
dw FacingWeirdTree0
|
||||||
dw Facing25
|
dw FacingWeirdTree1
|
||||||
dw Facing26
|
dw FacingWeirdTree2
|
||||||
dw Facing27
|
dw FacingWeirdTree3
|
||||||
dw Facing28
|
dw FacingBoulderDust1
|
||||||
dw Facing29
|
dw FacingBoulderDust2
|
||||||
dw Facing30
|
dw FacingGrass1
|
||||||
dw Facing31
|
dw FacingGrass2
|
||||||
FacingsEnd: dw 0
|
FacingsEnd: dw 0
|
||||||
|
|
||||||
NUM_FACINGS EQU (FacingsEnd - Facings) / 2
|
NUM_FACINGS EQU (FacingsEnd - Facings) / 2
|
||||||
@ -47,10 +47,10 @@ Y_FLIP EQU 1 << OAM_Y_FLIP
|
|||||||
BEHIND_BG EQU 1 << OAM_PRIORITY
|
BEHIND_BG EQU 1 << OAM_PRIORITY
|
||||||
|
|
||||||
|
|
||||||
Facing00:
|
FacingStepDown0:
|
||||||
Facing02:
|
FacingStepDown2:
|
||||||
Facing24:
|
FacingWeirdTree0:
|
||||||
Facing26: ; standing down
|
FacingWeirdTree2: ; standing down
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 0, 0, $00
|
db 0, 0, 0, $00
|
||||||
db 0, 8, 0, $01
|
db 0, 8, 0, $01
|
||||||
@ -58,7 +58,7 @@ Facing26: ; standing down
|
|||||||
db 8, 8, 2, $03
|
db 8, 8, 2, $03
|
||||||
; 409c
|
; 409c
|
||||||
|
|
||||||
Facing01: ; walking down 1
|
FacingStepDown1: ; walking down 1
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 0, 0, $80
|
db 0, 0, 0, $80
|
||||||
db 0, 8, 0, $81
|
db 0, 8, 0, $81
|
||||||
@ -66,7 +66,7 @@ Facing01: ; walking down 1
|
|||||||
db 8, 8, 2, $83
|
db 8, 8, 2, $83
|
||||||
; 40ad
|
; 40ad
|
||||||
|
|
||||||
Facing03: ; walking down 2
|
FacingStepDown3: ; walking down 2
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 8, X_FLIP, $80
|
db 0, 8, X_FLIP, $80
|
||||||
db 0, 0, X_FLIP, $81
|
db 0, 0, X_FLIP, $81
|
||||||
@ -74,8 +74,8 @@ Facing03: ; walking down 2
|
|||||||
db 8, 0, 2 | X_FLIP, $83
|
db 8, 0, 2 | X_FLIP, $83
|
||||||
; 40be
|
; 40be
|
||||||
|
|
||||||
Facing04:
|
FacingStepUp0:
|
||||||
Facing06: ; standing up
|
FacingStepUp2: ; standing up
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 0, 0, $04
|
db 0, 0, 0, $04
|
||||||
db 0, 8, 0, $05
|
db 0, 8, 0, $05
|
||||||
@ -83,7 +83,7 @@ Facing06: ; standing up
|
|||||||
db 8, 8, 2, $07
|
db 8, 8, 2, $07
|
||||||
; 40cf
|
; 40cf
|
||||||
|
|
||||||
Facing05: ; walking up 1
|
FacingStepUp1: ; walking up 1
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 0, 0, $84
|
db 0, 0, 0, $84
|
||||||
db 0, 8, 0, $85
|
db 0, 8, 0, $85
|
||||||
@ -91,7 +91,7 @@ Facing05: ; walking up 1
|
|||||||
db 8, 8, 2, $87
|
db 8, 8, 2, $87
|
||||||
; 40e0
|
; 40e0
|
||||||
|
|
||||||
Facing07: ; walking up 2
|
FacingStepUp3: ; walking up 2
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 8, X_FLIP, $84
|
db 0, 8, X_FLIP, $84
|
||||||
db 0, 0, X_FLIP, $85
|
db 0, 0, X_FLIP, $85
|
||||||
@ -99,8 +99,8 @@ Facing07: ; walking up 2
|
|||||||
db 8, 0, 2 | X_FLIP, $87
|
db 8, 0, 2 | X_FLIP, $87
|
||||||
; 40f1
|
; 40f1
|
||||||
|
|
||||||
Facing08:
|
FacingStepLeft0:
|
||||||
Facing10: ; standing left
|
FacingStepLeft2: ; standing left
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 0, 0, $08
|
db 0, 0, 0, $08
|
||||||
db 0, 8, 0, $09
|
db 0, 8, 0, $09
|
||||||
@ -108,8 +108,8 @@ Facing10: ; standing left
|
|||||||
db 8, 8, 2, $0b
|
db 8, 8, 2, $0b
|
||||||
; 4102
|
; 4102
|
||||||
|
|
||||||
Facing12:
|
FacingStepRight0:
|
||||||
Facing14: ; standing right
|
FacingStepRight2: ; standing right
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 8, X_FLIP, $08
|
db 0, 8, X_FLIP, $08
|
||||||
db 0, 0, X_FLIP, $09
|
db 0, 0, X_FLIP, $09
|
||||||
@ -117,8 +117,8 @@ Facing14: ; standing right
|
|||||||
db 8, 0, 2 | X_FLIP, $0b
|
db 8, 0, 2 | X_FLIP, $0b
|
||||||
; 4113
|
; 4113
|
||||||
|
|
||||||
Facing09:
|
FacingStepLeft1:
|
||||||
Facing11: ; walking left
|
FacingStepLeft3: ; walking left
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 0, 0, $88
|
db 0, 0, 0, $88
|
||||||
db 0, 8, 0, $89
|
db 0, 8, 0, $89
|
||||||
@ -126,8 +126,8 @@ Facing11: ; walking left
|
|||||||
db 8, 8, 2, $8b
|
db 8, 8, 2, $8b
|
||||||
; 4124
|
; 4124
|
||||||
|
|
||||||
Facing13:
|
FacingStepRight1:
|
||||||
Facing15: ; walking right
|
FacingStepRight3: ; walking right
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 8, X_FLIP, $88
|
db 0, 8, X_FLIP, $88
|
||||||
db 0, 0, X_FLIP, $89
|
db 0, 0, X_FLIP, $89
|
||||||
@ -135,7 +135,7 @@ Facing15: ; walking right
|
|||||||
db 8, 0, 2 | X_FLIP, $8b
|
db 8, 0, 2 | X_FLIP, $8b
|
||||||
; 4135
|
; 4135
|
||||||
|
|
||||||
Facing16: ; fishing down
|
FacingFishDown: ; fishing down
|
||||||
db 5 ; #
|
db 5 ; #
|
||||||
db 0, 0, 0, $00
|
db 0, 0, 0, $00
|
||||||
db 0, 8, 0, $01
|
db 0, 8, 0, $01
|
||||||
@ -144,7 +144,7 @@ Facing16: ; fishing down
|
|||||||
db 16, 0, 4, $fc
|
db 16, 0, 4, $fc
|
||||||
; 414a
|
; 414a
|
||||||
|
|
||||||
Facing17: ; fishing up
|
FacingFishUp: ; fishing up
|
||||||
db 5 ; #
|
db 5 ; #
|
||||||
db 0, 0, 0, $04
|
db 0, 0, 0, $04
|
||||||
db 0, 8, 0, $05
|
db 0, 8, 0, $05
|
||||||
@ -153,7 +153,7 @@ Facing17: ; fishing up
|
|||||||
db -8, 0, 4, $fc
|
db -8, 0, 4, $fc
|
||||||
; 415f
|
; 415f
|
||||||
|
|
||||||
Facing18: ; fishing left
|
FacingFishLeft: ; fishing left
|
||||||
db 5 ; #
|
db 5 ; #
|
||||||
db 0, 0, 0, $08
|
db 0, 0, 0, $08
|
||||||
db 0, 8, 0, $09
|
db 0, 8, 0, $09
|
||||||
@ -162,7 +162,7 @@ Facing18: ; fishing left
|
|||||||
db 5, -8, 4 | X_FLIP, $fd
|
db 5, -8, 4 | X_FLIP, $fd
|
||||||
; 4174
|
; 4174
|
||||||
|
|
||||||
Facing19: ; fishing right
|
FacingFishRight: ; fishing right
|
||||||
db 5 ; #
|
db 5 ; #
|
||||||
db 0, 8, X_FLIP, $08
|
db 0, 8, X_FLIP, $08
|
||||||
db 0, 0, X_FLIP, $09
|
db 0, 0, X_FLIP, $09
|
||||||
@ -171,7 +171,7 @@ Facing19: ; fishing right
|
|||||||
db 5, 16, 4, $fd
|
db 5, 16, 4, $fd
|
||||||
; 4189
|
; 4189
|
||||||
|
|
||||||
Facing20: ; emote
|
FacingEmote: ; emote
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 0, 4, $f8
|
db 0, 0, 4, $f8
|
||||||
db 0, 8, 4, $f9
|
db 0, 8, 4, $f9
|
||||||
@ -179,13 +179,13 @@ Facing20: ; emote
|
|||||||
db 8, 8, 4, $fb
|
db 8, 8, 4, $fb
|
||||||
; 419a
|
; 419a
|
||||||
|
|
||||||
Facing21: ; shadow
|
FacingShadow: ; shadow
|
||||||
db 2 ; #
|
db 2 ; #
|
||||||
db 0, 0, 4, $fc
|
db 0, 0, 4, $fc
|
||||||
db 0, 8, 4 | X_FLIP, $fc
|
db 0, 8, 4 | X_FLIP, $fc
|
||||||
; 41a3
|
; 41a3
|
||||||
|
|
||||||
Facing23: ; big snorlax or lapras doll
|
FacingBigDollSymmetric: ; big snorlax or lapras doll
|
||||||
db 16 ; #
|
db 16 ; #
|
||||||
db 0, 0, 0, $00
|
db 0, 0, 0, $00
|
||||||
db 0, 8, 0, $01
|
db 0, 8, 0, $01
|
||||||
@ -205,7 +205,7 @@ Facing23: ; big snorlax or lapras doll
|
|||||||
db 24, 16, X_FLIP, $07
|
db 24, 16, X_FLIP, $07
|
||||||
; 41e4
|
; 41e4
|
||||||
|
|
||||||
Facing25: ; 41e4
|
FacingWeirdTree1: ; 41e4
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 0, 0, $04
|
db 0, 0, 0, $04
|
||||||
db 0, 8, 0, $05
|
db 0, 8, 0, $05
|
||||||
@ -213,7 +213,7 @@ Facing25: ; 41e4
|
|||||||
db 8, 8, 0, $07
|
db 8, 8, 0, $07
|
||||||
; 41f5
|
; 41f5
|
||||||
|
|
||||||
Facing27: ; 41f5
|
FacingWeirdTree3: ; 41f5
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 8, X_FLIP, $04
|
db 0, 8, X_FLIP, $04
|
||||||
db 0, 0, X_FLIP, $05
|
db 0, 0, X_FLIP, $05
|
||||||
@ -221,7 +221,7 @@ Facing27: ; 41f5
|
|||||||
db 8, 0, X_FLIP, $07
|
db 8, 0, X_FLIP, $07
|
||||||
; 4206
|
; 4206
|
||||||
|
|
||||||
Facing22: ; big doll other than snorlax or lapras
|
FacingBigDollAsymmetric: ; big doll other than snorlax or lapras
|
||||||
db 14 ; #
|
db 14 ; #
|
||||||
db 0, 0, 0, $00
|
db 0, 0, 0, $00
|
||||||
db 0, 8, 0, $01
|
db 0, 8, 0, $01
|
||||||
@ -239,7 +239,7 @@ Facing22: ; big doll other than snorlax or lapras
|
|||||||
db 24, 16, 0, $0b
|
db 24, 16, 0, $0b
|
||||||
; 423f
|
; 423f
|
||||||
|
|
||||||
Facing28: ; boulder dust 1
|
FacingBoulderDust1: ; boulder dust 1
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 0, 4, $fe
|
db 0, 0, 4, $fe
|
||||||
db 0, 8, 4, $fe
|
db 0, 8, 4, $fe
|
||||||
@ -247,7 +247,7 @@ Facing28: ; boulder dust 1
|
|||||||
db 8, 8, 4, $fe
|
db 8, 8, 4, $fe
|
||||||
; 4250
|
; 4250
|
||||||
|
|
||||||
Facing29: ; boulder dust 2
|
FacingBoulderDust2: ; boulder dust 2
|
||||||
db 4 ; #
|
db 4 ; #
|
||||||
db 0, 0, 4, $ff
|
db 0, 0, 4, $ff
|
||||||
db 0, 8, 4, $ff
|
db 0, 8, 4, $ff
|
||||||
@ -255,13 +255,13 @@ Facing29: ; boulder dust 2
|
|||||||
db 8, 8, 4, $ff
|
db 8, 8, 4, $ff
|
||||||
; 4261
|
; 4261
|
||||||
|
|
||||||
Facing30: ; 4261
|
FacingGrass1: ; 4261
|
||||||
db 2 ; #
|
db 2 ; #
|
||||||
db 8, 0, 4, $fe
|
db 8, 0, 4, $fe
|
||||||
db 8, 8, 4 | X_FLIP, $fe
|
db 8, 8, 4 | X_FLIP, $fe
|
||||||
; 426a
|
; 426a
|
||||||
|
|
||||||
Facing31: ; 426a
|
FacingGrass2: ; 426a
|
||||||
db 2 ; #
|
db 2 ; #
|
||||||
db 9, -1, 4, $fe
|
db 9, -1, 4, $fe
|
||||||
db 9, 9, 4 | X_FLIP, $fe
|
db 9, 9, 4 | X_FLIP, $fe
|
||||||
|
@ -14,23 +14,23 @@
|
|||||||
; 445f
|
; 445f
|
||||||
|
|
||||||
Pointers445f: ; 445f
|
Pointers445f: ; 445f
|
||||||
dw SetFacingStanding, SetFacingStanding ; 00
|
dw SetFacingStanding, SetFacingStanding ; 00
|
||||||
dw Function44b5, SetFacingCurrent ; 01 standing?
|
dw SetFacingStandAction, SetFacingCurrent ; 01 standing?
|
||||||
dw Function44c1, SetFacingCurrent ; 02 walking?
|
dw SetFacingStepAction, SetFacingCurrent ; 02 walking?
|
||||||
dw Function4508, SetFacingCurrent ; 03 bumping?
|
dw SetFacingBumpAction, SetFacingCurrent ; 03 bumping?
|
||||||
dw Function4529, SetFacingCurrent ; 04
|
dw SetFacingCounterclockwiseSpin, SetFacingCurrent ; 04
|
||||||
dw Function4539, SetFacingStanding ; 05
|
dw SetFacingCounterclockwiseSpin2, SetFacingStanding ; 05
|
||||||
dw Function456e, Function456e ; 06
|
dw SetFacingFish, SetFacingFish ; 06
|
||||||
dw Function457b, SetFacingStanding ; 07
|
dw SetFacingShadow, SetFacingStanding ; 07
|
||||||
dw Function4582, Function4582 ; 08
|
dw SetFacingEmote, SetFacingEmote ; 08
|
||||||
dw Function4589, Function4589 ; 09
|
dw SetFacingBigDollSym, SetFacingBigDollSym ; 09
|
||||||
dw Function4590, Function45a4 ; 0a
|
dw SetFacingBounce, SetFacingFreezeBounce ; 0a
|
||||||
dw Function45ab, SetFacingCurrent ; 0c
|
dw SetFacingWeirdTree, SetFacingCurrent ; 0b
|
||||||
dw Function45be, Function45be ; 0b
|
dw SetFacingBigDollAsym, SetFacingBigDollAsym ; 0c
|
||||||
dw Function45c5, Function45c5 ; 0d
|
dw SetFacingBigDoll, SetFacingBigDoll ; 0d
|
||||||
dw Function45da, SetFacingStanding ; 0e
|
dw SetFacingBoulderDust, SetFacingStanding ; 0e
|
||||||
dw Function45ed, SetFacingStanding ; 0f
|
dw SetFacingGrassShake, SetFacingStanding ; 0f
|
||||||
dw Function44e4, SetFacingCurrent ; 10
|
dw SetFacingSkyfall, SetFacingCurrent ; 10
|
||||||
; 44a3
|
; 44a3
|
||||||
|
|
||||||
SetFacingStanding: ; 44a3
|
SetFacingStanding: ; 44a3
|
||||||
@ -42,23 +42,23 @@ SetFacingStanding: ; 44a3
|
|||||||
|
|
||||||
SetFacingCurrent: ; 44aa
|
SetFacingCurrent: ; 44aa
|
||||||
call GetSpriteDirection
|
call GetSpriteDirection
|
||||||
or 0 ; useless
|
or FACING_STEP_DOWN_0 ; useless
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], a
|
ld [hl], a
|
||||||
ret
|
ret
|
||||||
; 44b5
|
; 44b5
|
||||||
|
|
||||||
Function44b5: ; 44b5
|
SetFacingStandAction: ; 44b5
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld a, [hl]
|
ld a, [hl]
|
||||||
and 1
|
and 1
|
||||||
jr nz, Function44c1
|
jr nz, SetFacingStepAction
|
||||||
jp SetFacingCurrent
|
jp SetFacingCurrent
|
||||||
; 44c1
|
; 44c1
|
||||||
|
|
||||||
Function44c1: ; 44c1
|
SetFacingStepAction: ; 44c1
|
||||||
ld hl, OBJECT_FLAGS1
|
ld hl, OBJECT_FLAGS1
|
||||||
add hl, bc
|
add hl, bc
|
||||||
bit SLIDING, [hl]
|
bit SLIDING, [hl]
|
||||||
@ -77,7 +77,7 @@ Function44c1: ; 44c1
|
|||||||
ld d, a
|
ld d, a
|
||||||
|
|
||||||
call GetSpriteDirection
|
call GetSpriteDirection
|
||||||
or 0 ; useless
|
or FACING_STEP_DOWN_0 ; useless
|
||||||
or d
|
or d
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
@ -85,7 +85,7 @@ Function44c1: ; 44c1
|
|||||||
ret
|
ret
|
||||||
; 44e4
|
; 44e4
|
||||||
|
|
||||||
Function44e4: ; 44e4
|
SetFacingSkyfall: ; 44e4
|
||||||
ld hl, OBJECT_FLAGS1
|
ld hl, OBJECT_FLAGS1
|
||||||
add hl, bc
|
add hl, bc
|
||||||
bit SLIDING, [hl]
|
bit SLIDING, [hl]
|
||||||
@ -104,7 +104,7 @@ Function44e4: ; 44e4
|
|||||||
ld d, a
|
ld d, a
|
||||||
|
|
||||||
call GetSpriteDirection
|
call GetSpriteDirection
|
||||||
or 0 ; useless
|
or FACING_STEP_DOWN_0 ; useless
|
||||||
or d
|
or d
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
@ -112,7 +112,7 @@ Function44e4: ; 44e4
|
|||||||
ret
|
ret
|
||||||
; 4508
|
; 4508
|
||||||
|
|
||||||
Function4508: ; 4508
|
SetFacingBumpAction: ; 4508
|
||||||
ld hl, OBJECT_FLAGS1
|
ld hl, OBJECT_FLAGS1
|
||||||
add hl, bc
|
add hl, bc
|
||||||
bit SLIDING, [hl]
|
bit SLIDING, [hl]
|
||||||
@ -130,7 +130,7 @@ Function4508: ; 4508
|
|||||||
ld d, a
|
ld d, a
|
||||||
|
|
||||||
call GetSpriteDirection
|
call GetSpriteDirection
|
||||||
or 0 ; useless
|
or FACING_STEP_DOWN_0 ; useless
|
||||||
or d
|
or d
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
@ -138,24 +138,28 @@ Function4508: ; 4508
|
|||||||
ret
|
ret
|
||||||
; 4529
|
; 4529
|
||||||
|
|
||||||
Function4529: ; 4529
|
SetFacingCounterclockwiseSpin: ; 4529
|
||||||
call Function453f
|
call CounterclockwiseSpinAction
|
||||||
ld hl, OBJECT_FACING
|
ld hl, OBJECT_FACING
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld a, [hl]
|
ld a, [hl]
|
||||||
or 0 ; useless
|
or FACING_STEP_DOWN_0 ; useless
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], a
|
ld [hl], a
|
||||||
ret
|
ret
|
||||||
; 4539
|
; 4539
|
||||||
|
|
||||||
Function4539: ; 4539
|
SetFacingCounterclockwiseSpin2: ; 4539
|
||||||
call Function453f
|
call CounterclockwiseSpinAction
|
||||||
jp SetFacingStanding
|
jp SetFacingStanding
|
||||||
; 453f
|
; 453f
|
||||||
|
|
||||||
Function453f: ; 453f
|
CounterclockwiseSpinAction: ; 453f
|
||||||
|
; Here, OBJECT_STEP_FRAME consists of two 2-bit components,
|
||||||
|
; using only bits 0,1 and 4,5.
|
||||||
|
; bits 0,1 is a timer (4 overworld frames)
|
||||||
|
; bits 4,5 determines the facing - the direction is counterclockwise.
|
||||||
ld hl, OBJECT_STEP_FRAME
|
ld hl, OBJECT_STEP_FRAME
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld a, [hl]
|
ld a, [hl]
|
||||||
@ -195,39 +199,39 @@ Function453f: ; 453f
|
|||||||
db OW_DOWN, OW_RIGHT, OW_UP, OW_LEFT
|
db OW_DOWN, OW_RIGHT, OW_UP, OW_LEFT
|
||||||
; 456e
|
; 456e
|
||||||
|
|
||||||
Function456e: ; 456e
|
SetFacingFish: ; 456e
|
||||||
call GetSpriteDirection
|
call GetSpriteDirection
|
||||||
rrca
|
rrca
|
||||||
rrca
|
rrca
|
||||||
add $10
|
add FACING_FISH_DOWN
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], a
|
ld [hl], a
|
||||||
ret
|
ret
|
||||||
; 457b
|
; 457b
|
||||||
|
|
||||||
Function457b: ; 457b
|
SetFacingShadow: ; 457b
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], FACING_15
|
ld [hl], FACING_SHADOW
|
||||||
ret
|
ret
|
||||||
; 4582
|
; 4582
|
||||||
|
|
||||||
Function4582: ; 4582 emote
|
SetFacingEmote: ; 4582 emote
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], FACING_EMOTE
|
ld [hl], FACING_EMOTE
|
||||||
ret
|
ret
|
||||||
; 4589
|
; 4589
|
||||||
|
|
||||||
Function4589: ; 4589
|
SetFacingBigDollSym: ; 4589
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], FACING_17
|
ld [hl], FACING_BIG_DOLL_SYM
|
||||||
ret
|
ret
|
||||||
; 4590
|
; 4590
|
||||||
|
|
||||||
Function4590: ; 4590
|
SetFacingBounce: ; 4590
|
||||||
ld hl, OBJECT_STEP_FRAME
|
ld hl, OBJECT_STEP_FRAME
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld a, [hl]
|
ld a, [hl]
|
||||||
@ -235,21 +239,21 @@ Function4590: ; 4590
|
|||||||
and %00001111
|
and %00001111
|
||||||
ld [hl], a
|
ld [hl], a
|
||||||
and %00001000
|
and %00001000
|
||||||
jr z, Function45a4
|
jr z, SetFacingFreezeBounce
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], FACING_04
|
ld [hl], FACING_STEP_UP_0
|
||||||
ret
|
ret
|
||||||
; 45a4
|
; 45a4
|
||||||
|
|
||||||
Function45a4: ; 45a4
|
SetFacingFreezeBounce: ; 45a4
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], 0
|
ld [hl], FACING_STEP_DOWN_0
|
||||||
ret
|
ret
|
||||||
; 45ab
|
; 45ab
|
||||||
|
|
||||||
Function45ab: ; 45ab
|
SetFacingWeirdTree: ; 45ab
|
||||||
ld hl, OBJECT_STEP_FRAME
|
ld hl, OBJECT_STEP_FRAME
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld a, [hl]
|
ld a, [hl]
|
||||||
@ -258,28 +262,28 @@ Function45ab: ; 45ab
|
|||||||
and %00001100
|
and %00001100
|
||||||
rrca
|
rrca
|
||||||
rrca
|
rrca
|
||||||
add $18
|
add FACING_WEIRD_TREE_0
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], a
|
ld [hl], a
|
||||||
ret
|
ret
|
||||||
; 45be
|
; 45be
|
||||||
|
|
||||||
Function45be: ; 45be
|
SetFacingBigDollAsym: ; 45be
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], FACING_16
|
ld [hl], FACING_BIG_DOLL_ASYM
|
||||||
ret
|
ret
|
||||||
; 45c5
|
; 45c5
|
||||||
|
|
||||||
Function45c5: ; 45c5
|
SetFacingBigDoll: ; 45c5
|
||||||
ld a, [VariableSprites + SPRITE_BIG_DOLL - SPRITE_VARS]
|
ld a, [VariableSprites + SPRITE_BIG_DOLL - SPRITE_VARS]
|
||||||
ld d, FACING_17 ; symmetric
|
ld d, FACING_BIG_DOLL_SYM ; symmetric
|
||||||
cp SPRITE_BIG_SNORLAX
|
cp SPRITE_BIG_SNORLAX
|
||||||
jr z, .ok
|
jr z, .ok
|
||||||
cp SPRITE_BIG_LAPRAS
|
cp SPRITE_BIG_LAPRAS
|
||||||
jr z, .ok
|
jr z, .ok
|
||||||
ld d, FACING_16 ; asymmetric
|
ld d, FACING_BIG_DOLL_ASYM ; asymmetric
|
||||||
|
|
||||||
.ok
|
.ok
|
||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
@ -288,7 +292,7 @@ Function45c5: ; 45c5
|
|||||||
ret
|
ret
|
||||||
; 45da
|
; 45da
|
||||||
|
|
||||||
Function45da: ; 45da
|
SetFacingBoulderDust: ; 45da
|
||||||
ld hl, OBJECT_STEP_FRAME
|
ld hl, OBJECT_STEP_FRAME
|
||||||
add hl, bc
|
add hl, bc
|
||||||
inc [hl]
|
inc [hl]
|
||||||
@ -297,15 +301,15 @@ Function45da: ; 45da
|
|||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
and 2
|
and 2
|
||||||
ld a, FACING_1C
|
ld a, FACING_BOULDER_DUST_1
|
||||||
jr z, .ok
|
jr z, .ok
|
||||||
inc a ; FACING_1D
|
inc a ; FACING_BOULDER_DUST_2
|
||||||
.ok
|
.ok
|
||||||
ld [hl], a
|
ld [hl], a
|
||||||
ret
|
ret
|
||||||
; 45ed
|
; 45ed
|
||||||
|
|
||||||
Function45ed: ; 45ed
|
SetFacingGrassShake: ; 45ed
|
||||||
ld hl, OBJECT_STEP_FRAME
|
ld hl, OBJECT_STEP_FRAME
|
||||||
add hl, bc
|
add hl, bc
|
||||||
inc [hl]
|
inc [hl]
|
||||||
@ -313,9 +317,9 @@ Function45ed: ; 45ed
|
|||||||
ld hl, OBJECT_FACING_STEP
|
ld hl, OBJECT_FACING_STEP
|
||||||
add hl, bc
|
add hl, bc
|
||||||
and 4
|
and 4
|
||||||
ld a, FACING_1E
|
ld a, FACING_GRASS_1
|
||||||
jr z, .ok
|
jr z, .ok
|
||||||
inc a ; FACING_1F
|
inc a ; FACING_GRASS_2
|
||||||
|
|
||||||
.ok
|
.ok
|
||||||
ld [hl], a
|
ld [hl], a
|
||||||
|
@ -776,7 +776,7 @@ MapObjectMovementPattern: ; 47dd
|
|||||||
ld [hl], STANDING
|
ld [hl], STANDING
|
||||||
ld hl, OBJECT_ACTION
|
ld hl, OBJECT_ACTION
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], PERSON_ACTION_09
|
ld [hl], PERSON_ACTION_BIG_SNORLAX
|
||||||
ld hl, OBJECT_STEP_TYPE
|
ld hl, OBJECT_STEP_TYPE
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], STEP_TYPE_04
|
ld [hl], STEP_TYPE_04
|
||||||
@ -789,7 +789,7 @@ MapObjectMovementPattern: ; 47dd
|
|||||||
ld [hl], STANDING
|
ld [hl], STANDING
|
||||||
ld hl, OBJECT_ACTION
|
ld hl, OBJECT_ACTION
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], PERSON_ACTION_0A
|
ld [hl], PERSON_ACTION_BOUNCE
|
||||||
ld hl, OBJECT_STEP_TYPE
|
ld hl, OBJECT_STEP_TYPE
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], STEP_TYPE_04
|
ld [hl], STEP_TYPE_04
|
||||||
@ -864,7 +864,7 @@ MapObjectMovementPattern: ; 47dd
|
|||||||
call ._MovementShadow_Grass_Emote_BoulderDust
|
call ._MovementShadow_Grass_Emote_BoulderDust
|
||||||
ld hl, OBJECT_ACTION
|
ld hl, OBJECT_ACTION
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], PERSON_ACTION_07
|
ld [hl], PERSON_ACTION_SHADOW
|
||||||
ld hl, OBJECT_STEP_DURATION
|
ld hl, OBJECT_STEP_DURATION
|
||||||
add hl, de
|
add hl, de
|
||||||
ld a, [hl]
|
ld a, [hl]
|
||||||
@ -921,7 +921,7 @@ MapObjectMovementPattern: ; 47dd
|
|||||||
call ._MovementShadow_Grass_Emote_BoulderDust
|
call ._MovementShadow_Grass_Emote_BoulderDust
|
||||||
ld hl, OBJECT_ACTION
|
ld hl, OBJECT_ACTION
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], PERSON_ACTION_0E
|
ld [hl], PERSON_ACTION_BOULDER_DUST
|
||||||
ld hl, OBJECT_STEP_DURATION
|
ld hl, OBJECT_STEP_DURATION
|
||||||
add hl, de
|
add hl, de
|
||||||
ld a, [hl]
|
ld a, [hl]
|
||||||
@ -965,7 +965,7 @@ MapObjectMovementPattern: ; 47dd
|
|||||||
call ._MovementShadow_Grass_Emote_BoulderDust
|
call ._MovementShadow_Grass_Emote_BoulderDust
|
||||||
ld hl, OBJECT_ACTION
|
ld hl, OBJECT_ACTION
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], PERSON_ACTION_0F
|
ld [hl], PERSON_ACTION_GRASS_SHAKE
|
||||||
ld hl, OBJECT_STEP_DURATION
|
ld hl, OBJECT_STEP_DURATION
|
||||||
add hl, de
|
add hl, de
|
||||||
ld a, [hl]
|
ld a, [hl]
|
||||||
@ -1804,7 +1804,7 @@ SkyfallTop: ; 4f83
|
|||||||
.Init:
|
.Init:
|
||||||
ld hl, OBJECT_ACTION
|
ld hl, OBJECT_ACTION
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], PERSON_ACTION_10
|
ld [hl], PERSON_ACTION_SKYFALL
|
||||||
ld hl, OBJECT_STEP_DURATION
|
ld hl, OBJECT_STEP_DURATION
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], 16
|
ld [hl], 16
|
||||||
|
@ -365,7 +365,7 @@ Movement_tree_shake: ; 5279
|
|||||||
|
|
||||||
ld hl, OBJECT_ACTION
|
ld hl, OBJECT_ACTION
|
||||||
add hl, bc
|
add hl, bc
|
||||||
ld [hl], PERSON_ACTION_0B
|
ld [hl], PERSON_ACTION_WEIRD_TREE
|
||||||
|
|
||||||
ld hl, OBJECT_DIRECTION_WALKING
|
ld hl, OBJECT_DIRECTION_WALKING
|
||||||
add hl, bc
|
add hl, bc
|
||||||
|
Loading…
Reference in New Issue
Block a user