All you need to do to find freespace is drag your rom on top of the Free Space logger executable. This will generate a text file with the addresses of your rom's freespace in both PC and SNES notation. Choose any address you want (provide there is enough space) and copy down the SNES address. Now open up the patch file in Notepad and paste the freespace address where specified.
III. Making a batch file
To make a batch file, open up Notepad and type the following:
xkas patchname.asm romname.smc cls
Where patchname and romname are the name of your patch and rom, respectively. Then save it as filename.bat (filename can be whatever you want).
IV. Patching your rom
All you have to do to patch your rom is run the batch file you just made. Just note that it won't work unless it, your rom, the patch, and xkas are all in the same folder.
V. The End
And that's the end of the tutorial. I hope that this has helped you learn how to patch with Xkas, and if you have any questions, don't hesitate to ask.
see? the pound.asm file already is pointed to some free space.
!Freespace = $1286B9 ;/ Freespace.
!RAM = $0660 ;\ Empty RAM for the pound flag.
!FreezeMarioTimer = $0D ;/ Time to freeze Mario in the air.
!AirSFX = $43 ;\ Sound when stomping in air..
!PoundSFX = $37 ;/ And on ground..
!GroundTimer = $28 ;\ Time to fall to ground (30 high)
!Player = $01
LDA $19 ;/
BEQ Return ;\ Doesn't work if Small Mario.
LDA $73 ;/ Or if you are ducking..
ORA $187A ;\ Or if you are on Yoshi.
AND #$04 ;/ If Mario's on the ground..
BNE CheckStomp ;\ Check for the pound flag.
LDA !RAM ;/ If the RAM is already set,
BNE Return ;\ Skip (prevent multiple button presses).
AND #$80 ;/ Only works if you press the X button.
LDA #!AirSFX ;\ Set sound when pound activated.
STZ $7D ;/ Temporarily freeze X
STZ $7B ;\ And Y speed.
STA $18BD ;\ For a defined period of time.
STA $140D ;/ Set spin jump flag...
STA $149B ;\ Set palette change...
STA $7D ;/ Set speed on coming back to ground..
LDA #$01 ;\ And set the pound flag on.
LDA !RAM ;\ If the flag hasn't been set..
BEQ Return ;/ Skip.
BEQ Clear ;\ Clear flag (for the block).
LDA $77 ;/ Skip if in air again.
LDA #!PoundSFX ;\ Set Pound SFX...
LDA $16 ;\ Part of the
AND #$10 ;/ Hijacked code.
so whats wrong??????
Not neccesarely freespace. There is a chance that it isn't freespace. You'd probably want to change it just in case.
Also I've done some renovations to his patch if you're interested. There are some bugs in there that I fixed.
You could ground pound during pause.
You could ground pound while swimming, or holding on nets.
If you ground pound in midair and land on yoshi, duck, land in water, or grab a net, then you could hold the attack with you which was odd.
If you ground pound in midair and pause then unpause when you hit the ground there is an odd delay of the smoke effects and the attack.
I need some help with patching my rom with fastrom and perfect sm3 powerdown.
First of all, No txt file will open if my rom is clean and I put it in slogger(Free Space Logger, so I tried patching it with xkas gui(2.2.3) and I do get a txt file, I run it in zsnes and... it doesnt run.
second thing is I input the "xkas patchname.asm romname.smc cls" code into a notepad file and tried to save as a batch file, no batch file savetype was found. So I saved it as a txt file and tried to change it to a bat file through renaming it. and I try running, not suprisingly I get jack.
I didnt run a txt file in zsnes I ran the newly patched rom in zsnes, which didnt run.
And I made the batch file which now runs and starts but it still deosnt seem to be working, I ran the smb3 powerdown patch through the steps double clicked it and I got squat when I ran the rom in zsnes afterwords.