boosprites2

by snydej

Game:

Description: Sprites are boos when not being looked at

!replace_sprite = $37
!koopakid = $29
!frame_counter = $13
!sprite_id_table = $9e
!player_direction = $76
!saved_sprite_table = $7FBA00
	LDA !frame_counter
	AND #$0f
	CMP #$0c
	BPL Done
	TAX
	LDA !sprite_id_table,X
	CMP #!koopakid
	BEQ Done
	CMP #!replace_sprite
	BEQ SkipStore
	STA !saved_sprite_table,X
SkipStore:
	JSL SubHorizPos
	TYA
	EOR !player_direction
	BEQ Facing
	LDA #!replace_sprite
	BRA Change
Facing:
	LDA !saved_sprite_table,X
Change:
	STA !sprite_id_table,X
Done:
	RTL
SubHorizPos:
	PEA $AD2E
	JML $01AD30
back to listings