Now with 20% more walruses
Started by JWinslow23, June 19, 2017, 10:19:21 pm
0 Members and 1 Guest are viewing this topic.
A6 F0 LDX $F0 ; Load current indexE0 0F CPX.B #$0F ; If this is within the code...90 06 BCC EndOfMod ; ...skip to end of modA9 00 LDA.B #$00 ; Store the value #$00...9F 00 FF FF STA.L $FFFF00, X ; ...into the current index:EndOfModE6 F0 INC $F0 ; Increment index6B RTL ; End of mod code
A9 01 LDA.B #$01 ; Store the value #$01...8D 1E 14 STA.W $141E ; ...into "Yoshi has wings" flag ; Usually, this is #$00 when Yoshi doesn't have wings, ; and #$02 when he does. ; Setting this to #$01 is apparently an unused mode. ; With it, Mario (in any powerup) can shoot fire, ; but flight and the tongue attack are disabled.6B RTL ; End mod code
A9 12 LDA.B #$12 ; Load the letter "I"...8D 31 0F STA.W $0F31 ; ...into the hundreds digitA9 17 LDA.B #$17 ; Load the letter "N"...8D 32 0F STA.W $0F32 ; ...into the tens digitA9 0F LDA.B #$0F ; Load the letter "F"...8D 33 0F STA.W $0F33 ; ...into the ones digit8D 30 0F STA.W $0F30 ; Store some non-zero value into the timer frame counter6B RTL ; End of mod code
A5 18 LDA $18 ; Load some controller data29 40 AND.B #%01000000 ; If X isn't being pressed...F0 1E BEQ EndOfMod ; ...skip to end of modA2 09 LDX.B #$09 ; Load #$09 into X:LoopStartBD C8 14 LDA.W $14C8, X ; Load enemy stateC9 08 CMP.B #$08 ; If enemy state < #$08...90 12 BCC NextEnemy ; ...skip the current enemyBD 7A 16 LDA.W $167A, X ; Load sprite properties29 02 AND.B #$02 ; If invincible to fire/cape/etc...1D D0 15 ORA.W $15D0,X ; ...or being eaten...1D 32 16 ORA.W $1632,X ; ...or not able to interact with player...D0 05 BNE NextEnemy ; ...skip the current enemyA9 02 LDA.B #$02 ; Load #$02 (enemy killed, falling off screen) into A9D C8 14 STA.W $14C8, X ; Store "enemy killed" into the current enemy state:NextEnemyCA DEX ; Decrement XD0 E4 BNE LoopStart ; Branch back if X is not 0:EndOfMod6B RTL ; End of mod code
9C CC 13 STZ.W $13CC ; By default, never add coins to your coin totalA2 00 LDX.B #$00 ; Load #$00 into X ("already added coin" flag)A5 72 LDA $72 ; Load "player is in air" flagC9 0B CMP.B #$0B ; If "player is in air" flag < #$0B...90 0C BCC ClearFlag ; ...clear jumping flagC9 0D CMP.B #$0D ; If "player is in air" flag >= #$0D...B0 08 BCS ClearFlag ; ...clear jumping flagA5 F0 LDA $F0 ; If "already added coin" flag is set...D0 06 BNE EndOfMod ; ...skip to end of modEE CC 13 INC.W $13CC ; Increment coinsE8 INX ; Increment X:ClearFlag86 F0 STX $F0 ; Store X (0 or 1) into "already added coin" flag:EndOfMod6B RTL ; End of mod code
AD E4 13 LDA.W $13E4 ; Load player dash timerC9 70 CMP.B #$70 ; If player dash timer < #$70 (max run speed)...90 05 BCC EndOfMod ; ...skip to end of modA9 1D LDA #$1D ; Store ending value of star timer - 1...8D 90 14 STA.W $1490 ; ...into star timer:EndOfMod6B RTL ; End of mod code
AD E4 13 LDA.W $13E4 ; If player dash timer is zero...F0 0A BEQ EndOfMod ; ...skip to end of modA5 71 LDA $71 ; Load current player animationC9 09 CMP.B #$09 ; If player already dying...F0 04 BEQ EndOfMod ; ...skip to end of mod22 06 F6 00 JSR.L $00F606 ; Jump to death subroutine:EndOfMod6B RTL ; End of mod code
A5 75 LDA $75 ; If player is underwater...0D F3 13 ORA.W $13F3 ; ...or flying with a P-Balloon...D0 22 BEQ EndPound ; ...make sure player isn't poundingA5 F0 LDA $F0 ; If player is already ground-pounding...D0 0D BNE GroundPound ; ...skip to ground-pounding codeA5 72 LDA $72 ; Load "player in air" flag1A INC A ; Increment (to make this comparison shorter)25 16 AND $16 ; AND with controller data29 04 AND #$04 ; If player is not pressing down and not in air...F0 15 BEQ EndPound ; ...make sure player isn't pounding64 7D STZ $7D ; Stop any current movement upwards85 F0 STA $F0 ; Store something non-zero into "ground-pounding" flag:GroundPound64 7B STZ $7B ; Make the player not move horizontallyC6 80 DEC $80 ; Make the player move downA9 1C LDA.B #$1C ; Store the "butt-slide" pose...8D E0 13 STA.W $13E0 ; ...into player's current poseA5 72 LDA $72 ; If player is still in the air...D0 06 BNE EndOfMod ; ...skip to end of mod22 BF 86 02 JSR.L $0286BF ; Cause a Yellow-Yoshi stomp earthquake:EndPound64 F0 STZ $F0 ; Player is not ground-pounding anymore6B RTL ; End of mod code
; Variables used:; $F0 = Time to flutter jump If this is non-zero value, it will apply flutter effect; $F1 = Flutter jump rest Amount of time left; $F2 = Flutter carry Calculated player Y speedAD 7A 18 LDA.W $187A ; If player isn't on Yoshi...F0 ?? BEQ Reset ; ...stop the flutter jumpA5 72 LDA $72 ; If player is on the ground...F0 ?? BEQ Reset ; ...stop the flutter jumpA5 74 LDA $74 ; If player is climbing...05 75 ORA $75 ; ...or swimming...D0 ?? BNE Reset ; ...stop the flutter jumpA5 19 LDA $19 ; Load player powerupC9 02 CMP.B #$02 ; If player has cape...F0 ?? BEQ Reset ; ...stop the flutter jumpA5 F0 LDA $F0 ; If player isn't flutter jumping...F0 ?? BEQ NoFlutter ; ...don't apply its effectsA5 F2 LDA $F2 ; Load flutter carry3A DEC A ; Decrement it30 ?? BMI Label1 ; If player is supposed to be rising...3A DEC A ; ...rise twice as fast:Label185 7D STA $7D ; Store into player Y speed85 F2 STA $F2 ; Store into flutter carryA5 7B LDA $7B ; If player is moving left...30 ?? BMI MoveLeft ; ...jump to code for moving leftC9 20 CMP.B $#20 ; If player X speed < #$20 (not quite running, to the right)...90 ?? BCC Label2 ; ...jump past speed-limiting codeA9 20 LDA.B #$20 ; Load #$20 into A80 ?? BRA Label2 ; Jump past code for moving left:MoveLeftC9 DF CMP.B $#DF ; If player X speed >= #$DF (not quite running, to the left)...B0 ?? BCS Label2 ; ...jump past speed-limiting codeA9 DF LDA.B #$DF ; Load #$DF into A:Label285 7B STA $7B ; Store into player X speedA5 7D LDA $7D ; If player is falling...10 ?? BPL Fluttered ; ...jump past flutter decrementC9 E0 CMP.B #$E0 ; If player is almost done rising...B0 ?? BCS Fluttered ; ...jump past flutter decrementC6 F0 DEC $F0 ; Decrement the flutter jump counter80 ?? BRA Fluttered ; Don't run the resting code if we're flutter jumping:NoFlutterA5 F1 LDA $F1 ; If there is still flutter jump rest time...F0 ?? BEQ NoRest ; ...don't decrement the rest timerC6 F1 DEC $F1 ; Else, do:NoRest:FlutteredA5 15 LDA $15 ; Load some controller data89 80 BIT.B #$80 ; If player isn't holding the jump button...F0 ?? BEQ EndOfMod ; ...skip to end of modA5 7D LDA $7D ; If player is rising...30 ?? BMI EndOfMod ; ...skip to end of modC9 20 CMP #$20 ; If player is just starting to fall...90 ?? BCC EndOfMod ; ...skip to end of mod9C 0D 14 STZ.W $140D ; Disable spinjumpingA5 F1 LDA $F1 ; If we are resting...D0 ?? BNE EndOfMod ; ...skip to end of modA9 01 LDA.B #$01 ; Store the value #$01...85 F0 STA $F0 ; ...into the flutter jump timerA5 7D LDA $7D ; Store the player Y speed...85 F1 STA $F1 ; ...into the flutter carryA9 30 LDA.B #$30 ; Store the resting time...85 F2 STA $F2 ; ...into the flutter rest timerA9 09 LDA.B #$09 ; Load sound #$09 (cape fly sound)8D F9 1D STA.W #$1DF9 ; Play sound:EndOfMod6B RTL ; End of mod code:Reset64 F0 STZ $F0 ; Reset64 F1 STZ $F1 ; every64 F2 STZ $F2 ; flag6B RTL ; .
CodeWalr.us 2.0 © 2019, DJ Omnimaga & Juju
Page created in 0.073 seconds with 36 queries.