The current URL is datacrystal.tcrf.net.
EarthBound/Map Data/Per-Sector Attributes Table: Difference between revisions
m (Infobox table change.) |
(Correction to "number of entries") |
||
Line 4: | Line 4: | ||
|start=0x17B400 | |start=0x17B400 | ||
|end=0x17C800 | |end=0x17C800 | ||
|numentries= | |numentries=2560 | ||
|entrylength=2 bytes (0x2) | |entrylength=2 bytes (0x2) | ||
|totallength=5120 bytes (0x1400) | |totallength=5120 bytes (0x1400) |
Revision as of 13:33, 1 January 2011
Per-Sector Attributes Table | |
Game | EarthBound |
Start Address | 0x17B400 |
End Address | 0x17C800 |
# of Entries | 2560 |
Entry Length | 2 bytes (0x2) |
Total Length | 5120 bytes (0x1400) |
Back to the ROM map |
The Per-Sector Attributes Table controls specific sector attributes for the map sectors in EarthBound. Every 2 bytes controls the data for an 8x4 tile area (or 'sector') on the map. This data includes graphics effects, which town map to use, exit mouse compatibility, Type-58 item usage, and other such components of the game.
Format
Each entry is made up of two bytes:
Byte 1
Byte 1 stores its data in binary, and contains most of the detailed information in the table. An easy way to find the hex equivalent without converting from binary is to just find the sum of the bit numbers you want activated. (I.E. 80, 40, and 08 - 11001000 - would equal 0x80 + 0x40 + 0x8 - 0xC8.)
[80 40 20 10 | 08 04 02 01]
- Bit 0x80: Teleportation inhibitor. PSI Teleport may not be used in this sector if this bit is toggled on.
- Bit 0x40: As far as we can tell, this bit is unused. We believe it may have been part of the town map section below.
- Bits 0x20, 0x10, and 0x08: Controls town map data. There are 8 different possible settings to pick.
- 000: No Map
- 001: Onett
- 010: Twoson
- 011: Threed
- 100: Fourside
- 101: Scaraba
- 110: Summers
- 111: No Map
- Bits 0x04, 0x02, and 0x01: Controls miscellaneous settings for the map. There are, again, 8 possible settings for this data.
- 000: No special settings
- 001: Area is indoors (Indoor areas indicate that you appear in your last position on the town map from when you went through a door.)
- 010: Exit Mice will function
- 011: Lost Underworld sprites
- 100: Magicant sprites
- 101: Robotomized sprites
- 110: Super-frequent Magic Butterflies
- 111: Super-frequent Magic Butterflies (this setting might indicate a combination of effects of 110 and 001
Byte 2
Byte 2 is an item number. Items in EB all have a specific item type number that indicates how they are used in the game. Type 58 items are special in that they can not be used if the player is not in a specific area. This byte controls that function.
To allow a player to use a type 58 item in a sector, you must program the item's number (displayed next to its name in PK Hack) into Byte 2. See below for some examples of how this byte is used (as well as the other settings in general).
Examples of Default Settings
- 00 00 = [0000|0000][00] (Wide variety of places)
- No settings
- 00 AF = [0000|0000][AF] (Deep Darkness)
- Item #AF (Hawk Eye) may be used in this area.
- 00 B0 = [0000|0000][B0] (Peaceful Rest Valley)
- Item #B0 (Bicycle) may be used in this area.
- 03 00 = [0000|0011][00] (Lost Underworld)
- Lost Underworld sprites are active.
- 08 B0 = [0000|1000][B0] (Onett)
- Onett shown in Town Map
- Item #B0 (Bicycle) may be used in this area.
- 10 B0 = [0001|0000][B0] (Twoson & Happy Happy Village)
- Twoson shown in Town Map
- Item #B0 (Bicycle) may be used in this area.
- 18 00 = [0001|1000][00] (Threed)
- Threed shown in Town Map
- 20 00 = [0010|0000][00] (Fourside)
- Fourside shown in Town Map
- 28 00 = [0010|1000][00] (Scaraba)
- Scaraba shown in Town Map
- 30 00 = [0011|0000][00] (Summers)
- Summers shown in Town Map
- 80 00 = [1000|0000][00] (Ness flashback house)
- Teleport inhibited
- 81 00 = [1000|0001][00] (Indoor areas, no map)
- Teleport inhibited
- Indoor area
- 82 00 = [1000|0010][00] (Caves)
- Teleport inhibited
- Exit mouse compatible
- 84 00 = [1000|0100][00] (Magicant)
- Teleport inhibited
- Magicant sprites
- 85 00 = [1000|0101][00] (Devil's Machine, Cave in the Past)
- Teleport inhibitead
- Robotomized sprites
- Indoor area