Post subject: SMAS SMB memory address find problem
YaLTeR
He/Him
Joined: 12/2/2011
Posts: 129
Location: Moscow, Russia
Hello! I am trying to find memory addresses for SMB from SMAS(SMAS ROM without SMW). I have found speed address, but I can't find the X subpixel address. I have tried to find it like in original NES SMB: while running full-speed(speed = 40) value is changing every frame and is the same every other frame, but this didn't work. Any help?
Site Admin, Skilled player (1236)
Joined: 4/17/2010
Posts: 11264
Location: RU
Try watching the non-filtered addresses and getting/losing acceleration. Shall be located somewhere near the main X addresses.
Warning: When making decisions, I try to collect as much data as possible before actually deciding. I try to abstract away and see the principles behind real world events and people's opinions. I try to generalize them and turn into something clear and reusable. I hate depending on unpredictable and having to make lottery guesses. Any problem can be solved by systems thinking and acting.
Editor, Skilled player (1404)
Joined: 3/31/2010
Posts: 2086
Subpixel addresses tend to be kind of tricky to find, as they are rather volatile. I'm not sure whether it's handled any different from SMB1, so I think the best you can do is keep trying. Predict how the address behaves and search accordingly, you should be able to find it eventually.
Player (131)
Joined: 5/21/2012
Posts: 74
Location: Cary, NC
I'm not sure if this applies but if SNES9x has Gens' ram watch stuff then it should I guess. Easiest way I've found to dig out values is load a state, do something known to change a value you want to find (i.e. just walk left for a couple frames), save the state, reload the earlier state, don't do that thing for the same number of frames, save that in another slot, reset your change count in the RAM watch, load the other state, and then drop everything with zero changes. This gives you only values that are different between the states. This should severely reduce the number of values listed. Then, don't do anything that would change the value for a while (i.e. stand still), then drop anything which still increased in change count, since those are changing even though you're not moving. Watch the remaining values (there should be very little left), try to figure out how they relate to your movement, and you should find it.
YaLTeR
He/Him
Joined: 12/2/2011
Posts: 129
Location: Moscow, Russia
The thing is... When I just stand still and do a "Not changed" search... I get a bunch of values that are all 24 and are not changing at all. That's it. But anyway I'm not planning to do a TAS on it, I'm just doing another "tool-assisted playthrough" because I wanted to play SMB from SMAS after completing NES SMB. And I can still do most of the glitches I use (like block enter or flagpole glitch) knowing only X speed value.
Player (131)
Joined: 5/21/2012
Posts: 74
Location: Cary, NC
OK I'll go through what worked for me: - Start the game up, get Mario to a dead stop - Pause emulation - Save in slot 1 - Hold down the Right button, advance until Mario moves 1 frame to the right, then 1 frame further so you know you get some subpixel movement in but not a pixel move. This wound up being 6 frames. - Save in slot 2 - Load slot 1 - Advance the same number of frames (6) - Open RAM Search, Reset, Clear Change Count - Load slot 2 - Set filter to Greater Than, Number of Changes, 0 - Click Search For me, this knocked the RAM value list down to just 25 values. Unpause emulation, wait until Mario comes to a stop, then watch the remaining values and see what continues to change. If something keeps going up in change count, it isn't movement-related. Eliminate it. Pace around a bit, some values will rapidly increase in change count. Some values only changed while changing direction, some changed a lot. I got a few of them up into the hundreds, then eliminated anything below 100. This got it down to 10 values. Of what's left: 7E005D: Goes down to -24 when full speed walk left, increases to 24 when full speed right. This is obviously your X speed. 7E0219: Changes entirely based on X location on screen. This is your X coordinate, or at least related to or part of it. 7E0290: Changes between a very small number of values in a short range, which isn't typical of subpixel behavior. 7E0700: Always the absolute value of 7E005D. This is your abs speed. 2 of the values are highly volatile, i.e. they cover a very wide range of values: 7E0401 and 7E0705. Of those two, 7E0219 changes value every time 7E0401 crosses 0. This means it is probably your subpixel X. Y is harder to tell since it changes so much from gravity, but it's probably either 7E041C or 7E043C.