Language…
8 users online: dotCoockie, fanfan21, Ice Man, Jamie, Klug, neidoodle, Rykon-V73, SpaceGlam - Guests: 126 - Bots: 103
Users: 70,118 (2,533 active)
Latest user: efilyarps

Disable specific button until certain level is beaten

So, I’m currently using the Press R to switch
Mario and Luigi
UberASM. I was thinking it would be pretty cool to disable the “R” button until a specific level or collectible is found, making Luigi an unlockable! What do you think would be the best way to implement this?
You can add a check in the UberASM for the specific condition you want, probably at the start of main it's fine. For example, to check for a specific level beaten you can add this:
Code
LDX.b #$LevelNumber
LDA $1EA2|!addr,x
BMI +
RTL
+

where $LevelNumber uses the $13BF format (i.e., for levels 000-024 you just use $00-$24, for 101-13C you use $25-$60).
Originally posted by Kevin
You can add a check in the UberASM for the specific condition you want, probably at the start of main it's fine. For example, to check for a specific level beaten you can add this:
Code
LDX.b #$LevelNumber
LDA $1EA2|!addr,x
BMI +
RTL
+

where $LevelNumber uses the $13BF format (i.e., for levels 000-024 you just use $00-$24, for 101-13C you use $25-$60).

Awesome! Thank you Kevin. I’ll give this a try later on today!