<- 1  -   of 222 ->
^^
vv
List results:
Search options:
Use \ before commas in usernames
Embarrasing Fact: Power suit made by lowest bidder
>Shadow34370
You just need to learn about numbering systems...
A bit is the smallest unit of memory, and is a 0 or a 1. Counting bits is done in binary (base 2).
A nybble is 4 bits, or a single digit of hexadecimal (each digit you see in a hex-editor). A value can be 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F.
A byte is 8 bits, or 2 nybbles / 2 digits of hexadecimal. This is the fundamental unit of size typically used by computers as far as addressing is concerned - Each address refers to a single byte.
A word, on the SNES, is 2 bytes, 4 digits, or 16 bits. Computers typically work with words at a time, and so on the SNES it typically stores data in groups of 2 bytes.

7E:09A2 is referring to 09A2 AND 09A3. 09A4 is referring to both 09A4 and 09A5. There are two arrays mentioned there, 09A2 is what items Samus currently is using (hilighted items on the screen), and 09A4 is what items Samus actually has (available items on the equipment screen). Grapple and X-ray work slightly differently though, it only matters if they're in 09A2.
Also, if you're using codes, they'll probably be hexadecimal values. So changing it to 01 in hex means 0000 0001 in binary. FF in hex means 1111 1111 in binary. Counting in binary is straightforward: 0000, 0001, 0010, 0011, 0100, 0101, 0110, 0111, 1000...

Super Metroid actually counts according to what equipment Samus has. Redesign's percentage calculation was rewritten to check what items were marked as collected.
Edit history:
Shadow34370: 2009-05-02 06:40:56 pm
I knew something was flawed with my thinking. Thanks Kejardon.  aiwebs_004

EDIT: New problem! How do I find where to hijack the ROM. I want it to be after Samus leaves Ceres and heads to Zebes. I did some research looking through all the text documents Kejardon and Jathys have put up, and nothing seems to work. I found this:
Testing gamestates:
00: Reset/Start
01: Opening
02: Game options menus
03: Unused? Points to an RTS.
04: Save game menus
05: Load Game map view
06: Loading game data?
07: Setting game up after loading the game?
08: Main gameplay
09: Hit a door block
0A: Loading next room?
0B: Loading next room?
0C: Pausing (normal gameplay but darkening)
0D: Paused, loading pause screen?
0E: Paused, continuation of above?
0F: Paused, map and item screens
10: Unpausing (Loading normal gameplay)
11: Unpausing (continuation of above)
12: Unpausing (normal gameplay but brightening)
13: Samus ran out of health
14: Continuing, black out surroundings
15: Continuing
16: Continuing, starting death animation
17: Continuing, flashing
18: Continuing, explosion
19: Continuing, black out (also cut to by timeup death)
1A: Game Over screen
1B: Reserve Tanks Auto

1D: Debug menu (End/Continue)
1E: Set up entirely new game with cutscenes?
1F: Set up new game (Ceres / Zebes?)
20: Made it to Ceres Elevator
21: Blackout from Ceres
22: Ceres goes boom, Samus goes to Zebes
23: Time up
24: Whiting out from time up (Goes to 19 directly if not on Ceres)
25: Ceres goes boom with Samus
26: Samus escapes from Zebes
27: Ending + Credits
28: Transition to demo movies
29: Continuation of above?
2A: Playing demo movies
2B: Transition from demo movies
2C: Continuation of above?


I think what I want is number 22: Ceres goes boom, Samus goes to Zebes. To find where that event starts I have to look at this?
This isn't lined up right...to see the correct version go here: http://jathys.zophar.net/supermetroid/kejardon/RandomRoutines.txt
0    1    2    3    4    5    6    7    8    9    A    B    C    D    E    F
E48A 088B 9FEB 0D8B E589 EA89 0080 208B 448B 69E1 B7E1 88E2 CF8C EF8C C890 E890
2493 6793 A193 80DC E0DC 71DD 87DD 9ADD AFDD C7DD E089 10DC 3F8B DB89 0E8B 0080
6783 8883 0E8B 1184 3184 0E8B BD84 138B 0080 2D85 4885 9385 FB85


From that I counted out 22 and it seemed to come out as 0E8B or 8B0E (once its flipped.)
So I tried the hijack point of 828B0E, but nothing happened... I am sure I am thinking about this wrong, but hopefully I am on the right track?
Edit history:
TailsLover: 2009-05-02 08:00:41 pm
Merry Christmas
The no shinespark damage patch isnt working what am I doing wrong
¯\_(ツ)_/¯
Quote from Shadow34370:
Shadow's post thingy
If you want stuff to line up correctly, you can use [code] tags. Also, those values are a table, not a list; 22 is A193 (93A1 once flipped) on that list.
Merry Christmas
I got it to work finally. *Takes deep breath* I gotta work on my hack
Embarrasing Fact: Power suit made by lowest bidder
Quote from Shadow34370:
EDIT: New problem! How do I find where to hijack the ROM. I want it to be after Samus leaves Ceres and heads to Zebes. I did some research looking through all the text documents Kejardon and Jathys have put up, and nothing seems to work. I found this:
I think what I want is number 22: Ceres goes boom, Samus goes to Zebes. To find where that event starts I have to look at this?
From that I counted out 22 and it seemed to come out as 0E8B or 8B0E (once its flipped.)
So I tried the hijack point of 828B0E, but nothing happened... I am sure I am thinking about this wrong, but hopefully I am on the right track?

This sounds actually entirely correct*. The problem must be with how you are hijacking the code.
The typical method for hijacking code is to replace an instruction with a JSR to free space in the same bank (or if needed, a JSL to free space elsewhere in the ROM), write the code there to do whatever you want, and then put the original instruction you replaced at the end, and finally RTS (or RTL) to the original code.

*To nitpick, this isn't how I would do it because the code would run every frame during that cutscene, but it should work just fine.
Edit history:
Shadow34370: 2009-05-03 08:48:38 am
Alright, last questions...  Liar

1. Who is right about reading that chart above?
Quote from uNsane:
Also, those values are a table, not a list; 22 is A193 (93A1 once flipped) on that list.


or
Quote from Kejardon:
This sounds actually entirely correct



...and my second problem...
I actually got it working now, but its not working at the same time. I know I have my code in the right spot, because whenever I get to the elevator on Ceres and the game is about to go to the cut screen, the screen goes black and thats it... I think I am overwriting code that needs to be there, so my question is how to I add code without overwriting the previous code? Here is what I have now...(this is set up to give your morph ball automatically after leaving Ceres station.) In this particular case I was trying repoint the code to free space in the ROM. I think the problem is that the first line, JSL $848B0E, overwrites whatever the first line originally was...
Code:
lorom

org $828B0E

JSL $84FFD0

org $84FFD0

LDA #$0004
STA $7E09A2		;Turns morph ball on
STA $7E09A4		;Puts morph in your inventory


RTL


Here is what I originally had, before I added the jumps. It still led me to a black screen though...
Code:
org $828B0E

LDA #$0004
STA $7E09A2		;Turns morph ball on
STA $7E09A4		;Puts morph in your inventory

RTS


Also, how would you go about doing this Kejardon? To make it more efficient instead of running every frame?
Embarrasing Fact: Power suit made by lowest bidder
I would probably have it run when Samus touches the elevator on Ceres, I guess. The hijack point you found should work fine though, it's just I tend to obsess about optimizing things. :P
A193 is 12, not 22. I doublechecked real quick yesterday in a debugger and 828B0E is correct.

The code you have without jumps won't work well, you're overwriting code and then letting it pick back up wherever it might end up. The code you have with jumps would *almost* work right, you just need to put the instruction you overwrote at the end.
Code:
lorom

org $828B0E

JSL $84FFD0		;This was originally a JSL $8BA35B

org $84FFD0

LDA #$0004
STA $7E09A2		;Turns morph ball on
STA $7E09A4		;Puts morph in your inventory

JSL $8BA35B		;Your code is done, now do what the code was originally supposed to do*

RTL


*to nitpick AGAIN, since you have a JSL followed immediately by an RTL, you can forget the RTL and change the JSL to JML
Edit history:
Shadow34370: 2009-05-03 01:55:03 pm
One more question. How did you find out that the original instruction was JSL $8BA35B. I thought that is what I was doing wrong, but didn't know how to find out what I was overwriting.

EDIT: Two extra notes:

1. It worked, thanks!  aiwebs_011
2. I received morph ball right from the beginning not after I left Ceres. (Not really a problem) Just odd that, that particular code must be ran sometime before Samus leaves Ceres.
What'd you say?
How do I get enemy F213 to work?

I have 5 of them stacked one on top of another. Here is their info:
Special: 6800 (respawn, move off screen)
speed: 0000
orientation: 0000
speed2: 3030 on the first one and 3000 on the rest.
enemies to clear the room: 03

They are still in the floor but won't move upwards.
I had a similar problem. My problem was that you need to make sure all 5 enemies in order with their index. In other words hold your mouse over one of the enemies. If it says "3" than you need all enemies in order. (Ex: 0,1,2,3,4, or 3,4,5,6,7) (Bad Ex: 0,2,3,4,5 or 1,3,5,6,7)
What'd you say?
Alright I got them in this order: 0,1,2,3,4 But I have another problem with them, they coem up once but after that they just stay in the ground. Any ideas?
I know this is kind of obvious, but did you set them to respawn Question
What'd you say?
Quote from tyjet66:
Here is their info:
Special: 6800 (respawn, move off screen)
speed: 0000
orientation: 0000
speed2: 3030 on the first one and 3000 on the rest.
enemies to clear the room: 03


Yeah I have set them for respawn, they respawn in the floor where I can kill them and they can hurt me but they wont come up.
Embarrasing Fact: Power suit made by lowest bidder
Quote from Shadow34370:
One more question. How did you find out that the original instruction was JSL $8BA35B. I thought that is what I was doing wrong, but didn't know how to find out what I was overwriting.

Haha, seriously? You know enough asm to write a simple code, but you don't know how to read existing code? Kinda odd order of learning things.
You could use a debugger set to break on executing 828B0E, you could run a trace and search for 82/8B0E, you can open the rom in a hex-editor to address 10B0E (assuming no header) and see 22 5B A3 8B (which a 65816 doc will tell you is JSL $8BA35B), or you can run a disassembler on that section of the rom. All four options are viable and useful in different situations, and it'll take a while to learn and master each approach.

Quote:
I received morph ball right from the beginning not after I left Ceres. (Not really a problem) Just odd that, that particular code must be ran sometime before Samus leaves Ceres.

Hmm. Not entirely sure why that happens off the top of my head, and I'm not up to looking into it right now.. oh well, if it's not a problem, :shrug:
OMG FLAN!!!!!!!
Would it be possible to slightly raise the speed of a vertical Shinespark so you can pass through a 8 pixel slope? I've put slopes that are 8 pixels high along a ceiling (upside down), so you can fall through, but not jump back up. What I'd like is for a shinespark to go fast enough to pass through the blocks, but normal jumping won't.

If it helps it's the first slope.
Merry Christmas
How do I add rooms?
Quote from Rydia3667:
How do I add rooms?


Someone made a tutorial about it a few months ago (I do not remember who), but I saved it in my computer.
Here it is

Free space is anything like..

FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF ..and so on.

Adding an entirely new room, you gonna need a few tools:

Lunar Address
Your hex editor of course and also..
SMILE which I assume you're using.

Mmkay, gonna take you through how I make an extra room.

Open your ROM with SMILE and select any room you want to use, I'm gonna use the room to the right of the landing site of Samus' ship, the small tunnel. The room is 795D4. Run Lunar Address and select the auto detect and choose your metroid ROM.

Now open your ROM with the hex editor(if your hex editor can't open it since SMILE has it in use, grab WindHex32, it'll work) and find some empty space in which some starts at offset
002F51C0. I'm gonna use offset 002F51E0 in this example.

To Lunar Address, enter on the PC File Address side $2F:51E0, the SNES address will pop up on the right((DED1E0) write it down on paper or whatever and save for later) you want to use then take it and go back to SMILE>Edit>Pointers, up topleft is the level data this is where that SNES address is gonna go. Remember the address that is currently there as you're going to replace it back.

So the data is stored at C3BCD2, replace that with the new address DED1E0, save pointers and then save the ROM. Go back into Edit>Pointers and set it back to C3BCD2, again, save pointers then save ROM. Back to the hex editor, reopen the ROM, if you're using WindHex32 its CTRL+U and you'll see that the data got stored there at that offset, now close SMILE, DO NOT SAVE. Lunar Address can also be closed as it is no longer needed.

Goto the room name that was in the drop down list which is the offset(795D4) and write down on paper the 44 bytes there and no further which is..

0D 00 20 04 01 01 70 A0 00 FB 95 E6 -16 bytes
E5 D2 BC C3 00 00 00 68 81 3B 8B 33 82 00 00 00 -32 bytes
00 00 00 00 00 46 82 00 00 D3 91 C6 8A D2 8A 0E -44 bytes

Now we're gonna use that new data to link to an entirely new room. Goto the bank that stores the room's, which is 78, so to offset 00078000(when making lots of rooms, stay within the bounds of 78000 to 7FFFF or errors will occur) and scroll down til you find empty data which starts at 7E99B, I will use 7E9A0 so to offset 0007E9A0. Place what you just wrote down into the new offset as so..

0D 00 20 04 01 01 70 A0 00 FB 95 E6 E5 D2 BC C3 -16 bytes
00 00 00 68 81 3B 8B 33 82 00 00 00 00 00 00 00 -32 bytes
00 46 82 00 00 D3 91 C6 8A D2 8A 0E -44 bytes

If you didn't know, bytes are 2 numbers smacked together so each 2 are a byte (01, 0A, 1C, etc.)

At bytes 14(D2), 15(BC) and 16(C3.) Place the number you wrote down from Lunar Address awhile back which was DED1E0 except put it in backwards, so the way to flip it would be E0D1DE(front to back<>back to front), now put that as bytes 14(E0), 15(D1) and 16(DE) then save.

Goto your SMILE folder now and open up the mdb file. smile>files>mdb. Scroll down to the very bottom and make a new line and put in the offset that the new room was made at so that it looks like so..

7E06B
7E0B5
7E82C
7E9A0

Save then close the file. Now reopen SMILE and on the drop down list of the room's, your newly added room will be on the very bottom. All done, enjoy! 
Quote from Rydia3667:
How do I add rooms?
you could also use this one too it will help adding new doors to that new room of you'res


this is what i did to copy/make new room and new door pointers hopefully this will help


follow some of the instructions from above.BUT it changes alittle but i will try to explain to the best of my knowledge.

in hex find room 791F8: and write on paper for notes and to reduce headaches if you need to start from scratch again...and make  back up's!! well the bytes are:

00 00 17 00 09 05 70 A0 00 7B 92 12 E6 0E 61 92
69 E6 47 92 12 E6 00 2D 92 E6 E5 BB C2 C2 01 06
05 C0 80 3D 88 93 81 81 01 83 92 00 00 16 C1 00
80 6A B7 C9 91 BB C2 C2 00 06 06 C0 80 3D 88 93
81 81 01 83 92 00 00 16 C1 00 80 6A B7 C9 91 BB
C2 C2 00 0C 05 D0 80 3D 88 93 81 81 01 83 92 00
00 16 C1 00 80 6A B7 C9 91 BB C2 C2 00 00 00 00
80 0D 8C 83 82 81 01 83 92 00 00 20 C1 26 80 6A
B7 BD 91 16 89 22 89 2E 89 3A 89 00 00 02 02 02
02 02 02 02 00 00 02 02 02 02 02 02 02 01 00 02
02 02 02 02 02 02 00 00 02 02 02 02 02 02 02 01
01 01 01 01 01 01 01 01 13 01 80 01

and the level data is C2C2BB
now i found free space at 2F51C0 (DED1C0)-go to smile/files/level entries go to the very end and type DED1C0 and save.

i typed the bytes at 7E9C0 and save
then i went into the smile/files/mdb and at the very end i typed 7E9C0 and save

ok now open up the rom in smile and go to your new room which is 7E9C0 it should look like the orignal

now open the pointer window and change C2C2BB to DED1C0 but! delete some tiles 1st so you don't overwrite anything else while you save the new level data pointer after that save room.

now in hex go back to offset 7E9C0 and at bytes 14,15,16 type DED1C0 but backwards so it should look like this C0D1DE
example:

00 00 17 00 09 05 70 A0 00 7B 92 12 E6 C0 D1 DE
69 E6 47 92 12 E6 00 2D 92 E6 E5 BB C2 C2 01 06
05 C0 80 3D 88 93 81 81 01 83 92 00 00 16 C1 00
80 6A B7 C9 91 BB C2 C2 00 06 06 C0 80 3D 88 93
81 81 01 83 92 00 00 16 C1 00 80 6A B7 C9 91 BB
C2 C2 00 0C 05 D0 80 3D 88 93 81 81 01 83 92 00
00 16 C1 00 80 6A B7 C9 91 BB C2 C2 00 00 00 00
80 0D 8C 83 82 81 01 83 92 00 00 20 C1 26 80 6A
B7 BD 91 16 89 22 89 2E 89 3A 89 00 00 02 02 02
02 02 02 02 00 00 02 02 02 02 02 02 02 01 00 02
02 02 02 02 02 02 00 00 02 02 02 02 02 02 02 01
01 01 01 01 01 01 01 01 13 01 80 01

save.

that should be it for the room.

now to make new door out pointer for 7E9C0

(bank 83) go to offset 1AD70-1ADA0 and type this in

CO E9 00 05 8E 16 08 01 00 80 00 00 FF FF FF FF
CO E9 00 05 8E 16 08 01 00 80 00 00 FF FF FF FF
CO E9 00 05 8E 16 08 01 00 80 00 00 FF FF FF FF
CO E9 00 05 8E 16 08 01 00 80 00 00 FF FF FF FF

save.

now go to offset 7E9B0 and type
70 AD 80 AD 90 AD A0 AD
change the two FF's after the last door's pointer to 01 01,so that smile doesn't weird out trying to read it. this is what we should end up with at 7E9B0

70 AD 80 AD 90 AD A0 AD 01 01 FF FF FF FF FF FF FF FF

save.

now in smile in the pointer window-door out type E9C0
save, now a window is going to pop up asking you would you like to free up the space from the original door out pointer click "NO"!!!!
because if you click 'yes' the original door out pointer will get deleted and you WILL run into problems!!

now save room and your good to go!!!!!!!! yay.

and just encase reopen the rom in hex and then save so all the new work you added in smile stays in hex.
Err, I feel kind of silly asking this but, when I'm trying to make a door go to a new room, usually it'll work fine after I edit where the game points you to, but sometimes when I go through the door one way it'll look fine, but when I go through it the opposite way it'll be one tile down and it wont look right.

Picture:

That normally happens when your doors are lined up incorrectly. Make sure they are both, 5 (I think?) blocks up from the bottom of the scroll area. If you have one at 5 blocks and the other at 4 that glitch normally happens.
They are both 6 tiles from the top and bottom of the scroll block. Worst comes to worst, I'll just put a room between the two doors.
What'd you say?
Make sure both doors are on the very edge of the scroll box and they have red (or no) scroll area behind them; they must also be 6 tiles from the bottom and 6 tiles from the top (dead center.)
Edit history:
Obsy: 2009-05-06 03:10:34 pm
Mistic Eyes Of Death Perception! Chibi Style!
how do you completely remove the scrowling sky? I want to use a different background. Shocked

EDIT: How do you make the layer 2 visible and STATIONARY? I dont want it to scroll but it doesn't even show.
Now with AFC done, I'm able to spend more time working on figuring out things so I can write up stuff that lets other people figure out how to do them. The patch is an example of messing around with FX1 palettes (NOT palette blends, but the glow colors and stuff.)

There's a lot of them left to document, but I thought this was funny and would make a good preview of what's to come.
attachment: