;This block spawns a throw block in Mario's hands, pretty much making it act like an infinite throw block since it doesn't disappear. ;Should act like tile 130 in Lunar Magic. db $42; Enable corner and inside-offsets. JMP MarioBelow : JMP MarioAbove : JMP MarioSide : JMP SpriteV : JMP SpriteH : JMP MarioCape : JMP MarioFireBall : JMP MarioCorner : JMP HeadInside : JMP BodyInside MarioAbove: MarioSide: MarioCorner: HeadInside: BodyInside: LDA $16 AND #$40 BNE SpawnNorm MarioBelow: SpriteV: SpriteH: MarioCape: MarioFireBall: RTL ;=====================================================; ;Spawn a normal sprite at Mario's position ; ;This part of the code is nicely stolen from the code library on SMWC. Isn't it awesome?; ;=====================================================; !Sprite = $53 ; Sprite to spawn !State = $0B ; State of sprite ($14C8,x) SpawnNorm: JSL $02A9DE BMI Return PHX TYX LDA #!State STA $14C8,x LDA #!Sprite STA $9E,x JSL $07F7D2 LDA #$FF STA $1540,x ;Store it to Mario's position. LDA $94 STA $E4,x LDA $95 STA $14E0,x LDA $96 STA $D8,x LDA $97 STA $14D4,x PLX Return: RTL