Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified patches/ips/momentum_conservation.ips
Binary file not shown.
Binary file modified patches/ips/split_speed.ips
Binary file not shown.
18 changes: 0 additions & 18 deletions patches/src/momentum_conservation.asm
Original file line number Diff line number Diff line change
@@ -1,18 +1,9 @@
; Patch to conserve Samus' horizontal momentum when landing while running
; Author: Scyzer, with updates by Nodever2 & OmegaDragnet7
lorom

!bank_90_free_space_start = $90F800
!bank_90_free_space_end = $90F880

!equipped_items = $09A2
!blue_booster = $0040
!spark_booster = $0080
!speed_booster = $2000
!any_booster = !blue_booster|!spark_booster|!speed_booster

lorom

; ASM to keep running speed while landing. This is more effective than simply changing the pose table,
; as you can have variables, and doesn't move you forward a pixel.

Expand Down Expand Up @@ -65,15 +56,6 @@ SPEEDKEEP:
LDA $0B40 : BEQ + : LDA #$0003 : JSL $80914D ; resume speed booster sfx if needed
+ ; next two lines of code are mostly only needed because of a dumb vanilla bug with $91DA74

lda !equipped_items
bit #!blue_booster|!speed_booster
bne .skip
sep #$20
lda #$01
sta $0b3e
rep #$20

.skip:
LDA #$0001 : STA $0AD0 ; update samus palette next frame
LDA #$0004 : STA $0ACE ; reset samus speed booster/screw attack palette index
PLP : RTS
Expand Down
11 changes: 5 additions & 6 deletions patches/src/split_speed.asm
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ org $82C04A
org $82C2A6
list_boots_equip_tilemaps:
dw $BFD2, $BFE4, tilemap_blue_booster, tilemap_spark_booster
warnpc $82C2B7
assert pc() <= $82C2B7

org !bank_82_free_space_start

Expand All @@ -97,8 +97,6 @@ list_boots_equip_bitmasks:

list_boots_ram_tilemaps:
dw $3CAA, $3CEA, $3D2A, $3D6A

warnpc !bank_82_free_space_end
assert pc() <= !bank_82_free_space_end

org !bank_82_freespace2_start
Expand All @@ -109,7 +107,6 @@ boots_item_selector_positions:
dw $00CC, $00A4
dw $00CC, $00AC

warnpc !bank_82_freespace2_end
assert pc() <= !bank_82_freespace2_end

; Accelerate Samus' animation with any booster item:
Expand Down Expand Up @@ -344,8 +341,10 @@ spark_booster_lose_blue:
;sta $0AAE
jsl .remove_echoes

stz $0b3e ; Clear dash counter

;stz $0b3e ; Clear dash counter
lda #$0001 ; reset speed booster timer to 1 (should fix xmode and momenutm conservation), $90857D automatically decrements this, if its at 0 it underflows causing animation issues with xmode/mc
sta $0b3e

lda #$0000
rtl
.skip_lose_blue:
Expand Down
Loading