you must hex edit your level:
1) Make a couple pipes, and put the entrances on them. Give unique values for the Entrance Number. Give them the same Connected Pipe ID number, and click "Connected Pipe" on both. Camera, Destination Entrance, and View should be 0 (there might be some exceptions for this, i dunno). However, for the Destination Area field: the first entrance should have a value of 0, and the second entrance should have a value of 1. Okay, thats the easy part.
2) Open up the level in Hex Editor. The blocks we're going to be playing with are blocks 11 and 13.
---- Block 11 ----
This block is like a table of contents. Each 'entry' is 8 bits (or whatever) long. The structure is as follows:
Format:
CC CC RR RR TT TT 00 00
Example:
01 00 00 00 02 00 00 00
CC: This is the Pipe Connector ID. A pipe will only work if an entry in block 11 starts with its Connector ID.
RR: This value points to the row in Block 13 that contains its information.
TT: This value is the number of twists and turns the camera will follow, PLUS one. If you have a pipe with no bends, this value will be 2. If you have a pipe that goes left for a while, then up, then right, then goes down and exits you out, there are 4 twists and turns, so this value will be a 5.
00: While looking through the rom, these values are always 0. They might mean something, but then they might not.
---- Block 13 ----
This block contains the information for the twists and turns.
Format:
XX XX YY YY 00 00 00 00 00 00 00 00 00 00 DD 00
Example:
30 01 60 06 00 00 00 00 00 00 00 00 00 00 02 00
XX: The X position of the current destination. There appears to be an offset of 16 to 32... not sure why, tho.
YY: The Y position of the current destination. There is also an offset of 16 to 32 here. These values might take some denial and error (TPB reference )
00: These values appear to be 00 every time throughout the rom.
DD: This is the direction you come out of this pipe. Sometimes, it doesn't seem to matter what this value is, and Mario will come out of the pipe the right way, but other times, he wont. 00: Down | 01: Right | 02: Up 03: Left
First of all, the row that this data is on is important. the RR value in block 11 points to this row. The first row is, of course, 00. Then, 10, 20, etc.
The number of rows for each Connection ID is equal to the number of Twists and Turns (the value of TT in block 11).
Each row is a destination to a 'node' in the pipe. For a pipe with no bends, there are two nodes: The entrance and the exit. For a pipe with a couple bends, each bend is also a node and needs a row. If you have a pipe that has bends, but you only make rows for the entrance and the exit, the camera will pan to the exit automatically, even if the pan is diagonal.
If you make an L shaped pipe where you go Down, then you exit to the right after just a couple tiles, you wont need a third node - the camera will just focus on Mario as he exits the pipe.
So lets say you have a pipe that goes right, down, right. Lets also say that the pipe is long enough that we want four nodes.
Row 00 is the Entrance point. It should have an appropriate value for DD.
Row 10 is the first Bend. It doesn't matter what its DD is, though i think its best if you make it 00.
Row 20 is the second Bend.
Row 30 is the Exit end of the pipe. It should have an appropriate value for DD as well.
Row 40 should be the start of your NEXT Connected Pipe ID, and 40 should be entered into spot RR in Block 11.
If you want some in game examples, check out level 7-A Area 2, 4-Ghost House Area 1, and 7-3 Area 1.
I think it was first posted from Garmichael |