today’s nintendo goal: completed!
this screenshot is of a modified version of one of No Carrier’s tutorial programs. here’s a link to what my goal was - here.
i’ll keep your dashboard tidy and hide the rest of this behind the cut.
first, i added two variables for the horizontal and vertical positions of the sprite right after the variables that were already listed:
buttons EQU $20 ; variables for the buttons
oldbuttons EQU $22
justpressed EQU $24
v_position EQU $6000
h_position EQU $6001
then i modified the rom header information to support the MMC1 mapper.
.ORG $7ff0 ; start at $7ff0 - 16 byte .NES header (iNES format)
Header: ; this is used only for emulators
.db “NES”, $1a
easy enough so far. next step, i’ll make it so when you press start, it saves the vertical and horizontal positions of the sprite to the two variables i created earlier.
and now i’ll make it so when you press select, it will store the info from the variables into the horizontal and vertical positions of the sprite.
and that’s it! open the program, move the sprite around, save it’s position, close / reopen the program, then when you press select it will move the sprite to wherever you had saved it. works perfect. aside from those few changes, the code is exactly the same as what’s in the zip file i linked before.
this is pretty basic but i’m really excited that i’ve figured it out.
here’s a link to download my modified version of the sprite program - http://www.box.net/shared/5seixkoha1