I'm working on a pseudo power up, modifying the caped mario.
It's work that is you have a cape you fly like if on a blue winged yoshi. I already disabled spin jump, cape spin and cape flying.
you cannot fly if you hold an item and if you touch water you lose the powerup.
This is the main code till now:
CodeFLY:
LDA $75
AND #$01 ;|Lose cape
BNE LoseCape
LDA $148F
AND #$01 ;|Item? no jump
BNE Return
LDA $77 ;\
AND #$04 ;|Doesn't work if not in air
BNE Return ;/
LDA $14 ;\
LSR
LSR
AND #$03 ; |Pick pose frame 0/1
TAX ;/
LDA Pose2,x ;\Set the pose
STA $13E0 ;/
LDA #$80 ;\
CMP $007D ;|
BCC B ;|Check if your going down
LDA #$24 ;|
CMP $007D ;|
BCS B ;/
LDA #$24 ;\ if so, lower speed
STA $007D ;/
B:
LDA $16 ;\
AND #$80 ;|check if B is pressed
BEQ Return ;/
LDA #$BF ;\ If so, fly
STA $007D ;/
RTL
LoseCape:
LDA #$01
STA $19
JML $00F5F3
Return:
RTL
What I'm not able to do is to change the hitbox of mario only while he is in mid air...
I need that in mid air he goes on a 16x16, like a little bird.
What I was think was to simulate he is ducking and cover the ducking pose with the pose i already inserted...
Someone can help me?