Language…
11 users online:  Anorakun, Azula16,  bebn legg, Daniel30sp, EntySky,  idol, Jaozin712, katun24, Natsuz2, Pink Gold Peach, TheSpreee333 - Guests: 101 - Bots: 221
Users: 69,709 (2,536 active)
Latest user: Spudd_4343

Make Patch only apply to Luigi (or Player 2)

Hey guys,


The hack I'm working on will let you switch between Mario & Luigi using the Press R to Switch Mario and Luigi Overworld Uberasm. I am also applying the SMB2/SMA Style Luigi Scuttle & a modified version of this Luigi Physics patch. In addition to making these changes, I want to disable Air Flight/Max Speed:
Code
org $00D66F|
	db $80 ; Disable air flight/max speed.

The code above achieves exactly what I want, but I want its effect to only apply to Luigi (leaving Mario in his Vanilla state). As far I can tell, in order to apply something only to Luigi, I should use the RAM address below:
Code
$0DB3

I've been messing around with it a little, but I'm still learning to make patches and my Brain's pretty shot, so please be patient with me. Your help would be greatly appreciated!

*Post Edited multiple times (because I'm a dumb-dumb)
This isn't a question for the request forums since you can just edit the patch to make it happen. I'm going to move this to the help forums for that reason.
Edit: deleted this reply because it wasn't relevant. Decided to edit original thread post instead.
How about this:
Code

assert read1($00FFD5) == $20
!bank = $800000

org $00D66F
autoclean JML hijack

freecode
hijack:
    LDA $0DB3
    BNE CODE_00D67D
	BCC CODE_00D67D				;$00D66F	||/
	LDA.w $149F					;$00D671	||\ Don't reset the takeoff timer if it's already set.
	JML $00D674|!bank
	; BNE CODE_00D67B				;$00D674	||/
	; LDA.b #$50					;$00D676	||\\ Set the takeoff timer.
	; STA.w $149F					;$00D678	||/


CODE_00D67D:
LDA.b #$0B					;$00D668
JML $00D67D|!bank
Originally posted by spooonsss
How about this:
Code

assert read1($00FFD5) == $20
!bank = $800000

org $00D66F
autoclean JML hijack

freecode
hijack:
    LDA $0DB3
    BNE CODE_00D67D
	BCC CODE_00D67D				;$00D66F	||/
	LDA.w $149F					;$00D671	||\ Don't reset the takeoff timer if it's already set.
	JML $00D674|!bank
	; BNE CODE_00D67B				;$00D674	||/
	; LDA.b #$50					;$00D676	||\\ Set the takeoff timer.
	; STA.w $149F					;$00D678	||/


CODE_00D67D:
LDA.b #$0B					;$00D668
JML $00D67D|!bank


Hmm, I wasn't able to get this to work. Any changes I would need to make before inserting?
Seems to work fine for me, Mario can fly but Luigi can't. Did you try on a clean rom?
Are you using SA-1? The code appears to be LoROM exclusive (although conversion would be easy).
Originally posted by spooonsss
Seems to work fine for me, Mario can fly but Luigi can't. Did you try on a clean rom?

Finally was able to try it on a clean rom. Worked perfectly! Now the fun begins finding the conflict...