How do I make that shooter spawn normal sprites instead of custom sprites?
Note: I am still using Sprite Tool and don't have plans to upgrade to PIXI.
Code;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Pipe Goomba Spawner
;; By Sonikku
;; Description: Spawns the SMB3 Goomba sprites from a pipe, as seen primarily
;; in Super Mario Bros 3's grassland levels.
!Sprite = $69 ; custom sprite number to spawn
!Sound = $00 ; $00 for no sound.
!Port = $1DFC ; can be $1DF9, $1DFA, or $1DFC
;; X position of shooter within level determines the direction in which the
;; Goombas will spawn in.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
PRINT "INIT ",pc
LDA #$30
STA $17AB,x
PRINT "MAIN ",pc
PHB
PHK
PLB
JSR PipeGoomba_Main
PLB
RTL
PipeGoomba_Main:
LDA $17A3,x
XBA
LDA $179B,x
REP #$20
SEC
SBC $1A
CMP #$0100
BCC .onscreen
+ SEP #$20
RTS
.onscreen
SEP #$20
LDA $179B,x
LSR : LSR : LSR : LSR
AND #$01
BNE +
JSR GetXPos
BMI .spawn
RTS
+ JSR GetXPos
BMI .return
.spawn LDA $17AB,x
BNE .return
LDA #$60
STA $17AB,x
JSR GenerateGoomba
.return RTS
GetXPos:
LDA $17A3,x
XBA
LDA $179B,x
REP #$20
SEC
SBC $94
SEP #$20
RTS
GenerateGoomba:
JSL $02A9DE
BMI .noslot
LDA #!Sound
BEQ +
STA !Port
+ PHX
TYX
LDA #!Sprite
STA $7FAB9E,x ; custom sprite number.
LDA #$01
STA $14C8,x
JSL $07F7D2 ; initialize sprite.
JSL $0187A7 ; mark as custom sprite.
LDA #$88
STA $7FAB10,x ; initialized.
LDA #$24 ; set walking out of pipe timer.
STA $1540,x
PLX
LDA $179B,x ; set x coordinates.
STA $00E4,y
LDA $17A3,x
STA $14E0,y
LDA $178B,x ; set y coordinates.
SEC
SBC #$06
STA $00D8,y
LDA $1793,x
SBC #$00
STA $14D4,y
LDA $179B,x
LSR : LSR : LSR : LSR
AND #$01
STA $157C,y
.noslot RTS