Language…
12 users online:  AmperSam, CroNo, DanMario24YT, EvilAdmiralKivi, fsvgm777, Guido_Keller, JezJitzu, Sweetdude, timothy726, tOaO, Tomi P, Zavok - Guests: 261 - Bots: 319
Users: 64,795 (2,377 active)
Latest user: mathew

Patch for one level / Small mario after checkpoint patch?

I was wondering if there was any way to have a patch take place on a specific level. For example, the wall jump patch, if I wanted it to only apply for one level how could I get around doing it? I know there are blocks and it's just an example. Also, how do you remain small Mario after getting a checkpoint? I've wondered for a while...
Signature.


First, let's get the checkpoint issue out of the way since that's easier. You'll want to modify $00F2E2 to disable midway powerups. In case you're not familiar with how to do so, just save this as an ASM file and patch it:

Code
org $00F2E2
	db $80




For the other thing about patches on specific levels, that's a bit more complicated. First, UberASM will allow you to run code on a per-level basis, which is what you'd mainly use to that.

If a patch doesn't actually require a specific hijack (i.e. replacing original code instead of just adding new stuff), then you're usually able to just copy-paste the hijack's code there with little issue (though you'll want to learn some basic ASM first just to understand how patches work).

However, patches that actually do replace portions of code are more difficult. An easy method is to pick some unused RAM address, then use that as a flag to decide what code to run, like:

Code
Hijack:
	LDA !flag		; if the flag is clear, run original code
	BEQ .originalCode
	JMP .hijackedCode	; else, jump to new code

Then just set/clear that flag with UberASM as necessary. Obviously though, this will require a bit of ASM knowledge, so I recommend you learn a bit about that first.

Professional frame-by-frame time wizard. YouTube - Twitter - SMW Glitch List - SMW Randomizer