Final Fantasy:ROM map

From Data Crystal
Revision as of 22:01, 23 September 2019 by FCandChill (talk | contribs) (BANK 0B)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Intro Values

  • 0x37F30 to 0x38000 (00D0) = Intro text, #$00 ends text
  • 0x3A12C to 0x----- (0001) = Intro text background color, original value = #$01
  • 0x3A2E3 to 0x----- (0001) = Text 'default' color after flicker, returns to this color
  • 0x3A2B8 to 0x----- (0001) = Text color that the above flicker math routine is applied to
  • 0x3A2C8 to 0x----- (0001) = Intro fade-in speed. Lower = fast & higher = slower, original value = #$0F
  • 0x3EB40 to 0x----- (0001) = Text color after flicker effect has been applied on text line
  • 0x3EB48 to 0x----- (0001) = Text 'color number 02' after flicker effect

Game Selecting Values

  • 0x3A263 - 0x3A281 (001F) = New Game/Continue/Respond Rate text
  • 0x384B8 - 0x384C7 (0010) = Copyright (for Square and Nintendo) text
  • 0x36843 - 0x36843 (0010) = Copyright (for Square and Nintendo) text

Starting Items

For Tents/Cabins/Houses and the Potions, the number given is the amount of them with which you start (eg., to start with 10 heal potions, set the byte at $3049 to $0A). For the rest, supply any non-zero value to start with that item.

  • 0x3026 to 0x----- (0001) = Sets off bridge scene prematurarly when game starts
  • 0x3031 to 0x----- (0001) = Lute
  • 0x3032 to 0x----- (0001) = Crown
  • 0x3033 to 0x----- (0001) = Crystal
  • 0x3034 to 0x----- (0001) = Herb
  • 0x3035 to 0x----- (0001) = Mystic Key
  • 0x3036 to 0x----- (0001) = TNT
  • 0x3037 to 0x----- (0001) = Adamant
  • 0x3038 to 0x----- (0001) = Slab
  • 0x3039 to 0x----- (0001) = Ruby
  • 0x303A to 0x----- (0001) = Rod
  • 0x303B to 0x----- (0001) = Floater
  • 0x303C to 0x----- (0001) = Chime
  • 0x303D to 0x----- (0001) = Tail
  • 0x303E to 0x----- (0001) = Cube
  • 0x303F to 0x----- (0001) = Bottle
  • 0x3040 to 0x----- (0001) = Oxyale
  • 0x3041 to 0x----- (0001) = Canoe appears on items screen (not working Canoe)
  • 0x3042 to 0x----- (0001) = Orb 1
  • 0x3043 to 0x----- (0001) = Orb 2
  • 0x3044 to 0x----- (0001) = Orb 3
  • 0x3045 to 0x----- (0001) = Orb 4
  • 0x3046 to 0x----- (0001) = Tents
  • 0x3047 to 0x----- (0001) = Cabins
  • 0x3048 to 0x----- (0001) = Houses
  • 0x3049 to 0x----- (0001) = Heal Potions
  • 0x304A to 0x----- (0001) = Pure Potions
  • 0x304B to 0x----- (0001) = Soft Potions

Starting Stats

There are 11 bytes for each character. 5 bytes with the value of "00" are used to seperate each character. Bytes are ordered as follows: Fighter, Thief, Black Belt, Red Mage, White Mage, Black Mage.

  • 0x3050 to 0x----- (0001) = Fighter's Listing Byte (normally 00)
  • 0x3051 to 0x----- (0001) = Fighter's Starting HP (normally 23)
  • 0x3052 to 0x----- (0001) = Fighter's Starting Strength (normally 14)
  • 0x3053 to 0x----- (0001) = Fighter's Starting Agility (normally 05)
  • 0x3054 to 0x----- (0001) = Fighter's Starting Intellect (normally 01)
  • 0x3055 to 0x----- (0001) = Fighter's Starting Vitality (normally 0A)
  • 0x3056 to 0x----- (0001) = Fighter's Starting Luck (normally 05)
  • 0x3057 to 0x----- (0001) = Fighter's Starting Damage (normally 0A)
  • 0x3058 to 0x----- (0001) = Fighter's Starting Hit% (normally 0A)
  • 0x3059 to 0x----- (0001) = Fighter's Starting Evade% (normally 35)
  • 0x305A to 0x----- (0001) = Fighter's Starting MagDef% (normally 15)

  • 0x3060 to 0x----- (0001) = Thief's Listing Byte (normally 01)
  • 0x3061 to 0x----- (0001) = Thief's Starting HP (normally 1E)

Main Menu Hand Cursor Data

  • 0x3B636 to 0x----- (0001) = X position of Character4 Sprite
  • 0x3B64A to 0x----- (0001) = Y position of Character4 Sprite
  • 0x3B8AC to 0x----- (0001) = X position of ORB 1
  • 0x3B8AE to 0x----- (0001) = Y position of ORB 1
  • 0x3B7E9 to 0x----- (0001) = X position of Character1 Hand Cursor
  • 0x3B7EA to 0x----- (0001) = Y position of Character1 Hand Cursor
  • 0x3B7EB to 0x----- (0001) = X position of Character2 Hand Cursor
  • 0x3B7EC to 0x----- (0001) = Y position of Character2 Hand Cursor
  • 0x3B7ED to 0x----- (0001) = X position of Character3 Hand Cursor
  • 0x3B7EE to 0x----- (0001) = Y position of Character3 Hand Cursor
  • 0x3B7EF to 0x----- (0001) = X position of Character4 Hand Cursor
  • 0x3B7F0 to 0x----- (0001) = Y position of Character4 Hand Cursor
  • 0x3B7F1 to 0x----- (0001) = Y position of ITEM Hand Cursor
  • 0x3B7F2 to 0x----- (0001) = Y position of MAGIC Hand Cursor
  • 0x3B7F3 to 0x----- (0001) = Y position of WEAPON Hand Cursor
  • 0x3B7F4 to 0x----- (0001) = Y position of STATUS Hand Cursor

Default Character Screen Data

  • 0x3A0C4 to 0x----- (0001) = X position of 4 letter name
  • 0x3A0C5 to 0x----- (0001) = Y position of 4 letter name
  • 0x3A0C6 to 0x----- (0001) = X position of Class Title
  • 0x3A0C7 to 0x----- (0001) = Y position of Class Title
  • 0x3A0C8 to 0x----- (0001) = X position of Character Sprite
  • 0x3A0C9 to 0x----- (0001) = Y position of Character Sprite
  • 0x3A0CA to 0x----- (0001) = X position of Background Window
  • 0x3A0CB to 0x----- (0001) = Y position of Background Window
  • 0x3A0CC to 0x----- (0001) = X position of Hand Cursor
  • 0x3A0CD to 0x----- (0001) = Y position of Hand Cursor

Random Window Stuff

  • 0x3D630 = window open speed
  • 0x3D6A9 = window close speed
  • 0x3E0AA to 0x----- (0001) = horizontal spacing between text and left boundary of window
  • 0x3E0B1 to 0x----- (0001) = vertical spacing between text and top boundary of window
  • 0x3E082 to 0x----- (0001) = horizontal window border subtraction
  • 0x3E089 to 0x----- (0001) = vertical window border subtraction

Battle Values

  • 0x31751 to 0x----- (0001) = all characters default sprite staring X coordinates
  • 0x3175F to 0x----- (0001) = character 1 default sprite Y coordinate
  • 0x31764 to 0x----- (0001) = character 2 default sprite Y coordinate
  • 0x31769 to 0x----- (0001) = character 3 default sprite Y coordinate
  • 0x3176E to 0x----- (0001) = character 4 default sprite Y coordinate
  • 0x3E0C8 to 0x----- (0001) = where (on name table) to load left window tile, original vaue $FA
  • 0x3E0CD to 0x----- (0001) = where (on name table) to load background tile, original vaue $FF
  • 0x3E0D5 to 0x----- (0001) = where (on name table) to load right tile, original vaue $FB
  • 0x3E11F to 0x----- (0001) = where (on name table) to load upper-left tile, original vaue $F7
  • 0x3E124 to 0x----- (0001) = where (on name table) to load top tile, original vaue $F8
  • 0x3E12C to 0x----- (0001) = where (on name table) to load upper-right tile, original vaue $F9
  • 0x3F2F5 to 0x----- (0001) = main battle border X & Y position
  • 0x3F2FA to 0x----- (0001) = main battle border Width (should not be below 3)
  • 0x3F2FC to 0x----- (0001) = main battle border Height (should not be below 3)
  • 0x3F301 to 0x----- (0001) = character battle border X position
  • 0x3F306 to 0x----- (0001) = character battle border Y position
  • 0x3F308 to 0x----- (0001) = character battle border Width
  • 0x3F30A to 0x----- (0001) = character battle border Height
  • 0x3f3a3 to 0x------(0001) = background width
  • 0x3f384 to 0x3f386 (0001) = menu fill
  • 0x3F3E0 to 0x----- (0001) = stat battle width for all 4 stat windows
  • 0x3F30F to 0x----- (0001) = stat battle x position for all 4 stat windows
  • 0x3F311 to 0x----- (0001) = stat battle window 4 y position
  • 0x3F316 to 0x----- (0001) = stat battle window 3 y position
  • 0x3F31B to 0x----- (0001) = stat battle window 2 y position
  • 0x3F320 to 0x----- (0001) = stat battle window 1 y position
  • 0x3F355 to 0x----- (0001) = row 1 BG × position and type
  • 0x3F39D to 0x----- (0001) = how many tiles the first section of the BG should draw
  • 0x3F3AA to 0x----- (0001) = how many tiles the second section of the BG should draw
  • 0x3F35D to 0x----- (0001) = row 1 BG environment tile set (00,04,08,0C)
  • 0x3F364 to 0x----- (0001) = row 2 BG environment tile set (00,04,08,0C)
  • 0x3F36B to 0x----- (0001) = row 3 BG environment tile set (00,04,08,0C)
  • 0x3F372 to 0x----- (0001) = row 4 BG environment tile set (00,04,08,0C)
  • 0x3f64c to 0x3f653 (0001) = bottom of enemy border
  • 0x3F410 to 0x3F44F (0040) = Battle Screen Attribute Data
  • 0x3F9F5 to 0x----- (0001) = Enemy window X coordinate
  • 0x3F9F6 to 0x----- (0001) = Enemy window Y coordinate
  • 0x3F9F7 to 0x----- (0001) = Enemy window Width
  • 0x3F9F8 to 0x----- (0001) = Enemy window Height
  • 0x3F9FA to 0x----- (0001) = current Attacker window X coordinate
  • 0x3F9FB to 0x----- (0001) = current Attacker window Y coordinate
  • 0x3F9FC to 0x----- (0001) = current Attacker window Width
  • 0x3F9FD to 0x----- (0001) = current Attacker window Height
  • 0x3F9FF to 0x----- (0001) = current Attacker text X coordinate
  • 0x3FA00 to 0x----- (0001) = current Attacker text Y coordinate
  • 0x3FA02 to 0x----- (0001) = hit number window X coordinate
  • 0x3FA03 to 0x----- (0001) = hit number window Y coordinate
  • 0x3FA04 to 0x----- (0001) = hit number window Width
  • 0x3FA05 to 0x----- (0001) = hit number window Height
  • 0x3FA07 to 0x----- (0001) = hit number text X coordinate
  • 0x3FA08 to 0x----- (0001) = hit number text Y coordinate
  • 0x3FA0A to 0x----- (0001) = current Attackee window X coordinate
  • 0x3FA0B to 0x----- (0001) = current Attackee window Y coordinate
  • 0x3FA0C to 0x----- (0001) = current Attackee window Width
  • 0x3FA0D to 0x----- (0001) = current Attackee window Height
  • 0x3FA0F to 0x----- (0001) = current Attackee text X coordinate
  • 0x3FA10 to 0x----- (0001) = current Attackee text Y coordinate
  • 0x3FA12 to 0x----- (0001) = Attack Status window X coordinate
  • 0x3FA13 to 0x----- (0001) = Attack Status window Y coordinate
  • 0x3FA14 to 0x----- (0001) = Attack Status window Width
  • 0x3FA15 to 0x----- (0001) = Attack Status window Height
  • 0x3FA17 to 0x----- (0001) = Attack Status text X coordinate
  • 0x3FA18 to 0x----- (0001) = Attack Status text Y coordinate
  • 0x3FA1A to 0x----- (0001) = Battle Info window X coordinate
  • 0x3FA1B to 0x----- (0001) = Battle Info window Y coordinate
  • 0x3FA1C to 0x----- (0001) = Battle Info window Width
  • 0x3FA1D to 0x----- (0001) = Battle Info window Height
  • 0x3FA1F to 0x----- (0001) = Battle Info text X coordinate
  • 0x3FA20 to 0x----- (0001) = Battle Info text Y coordinate
  • 0x3FA22 to 0x----- (0001) = Magic window X coordinate
  • 0x3FA23 to 0x----- (0001) = Magic window Y coordinate
  • 0x3FA24 to 0x----- (0001) = Magic window Width
  • 0x3FA25 to 0x----- (0001) = Magic window Height
  • 0x3FA27 to 0x----- (0001) = Drink window X coordinate
  • 0x3FA28 to 0x----- (0001) = Drink window Y coordinate
  • 0x3FA29 to 0x----- (0001) = Drink window Width
  • 0x3FA2A to 0x----- (0001) = Drink window Height
  • 0x3FA2C to 0x----- (0001) = Battle options window X coordinate
  • 0x3FA2D to 0x----- (0001) = Battle options window Y coordinate
  • 0x3FA2E to 0x----- (0001) = Battle options window Width
  • 0x3FA2F to 0x----- (0001) = Battle options window Height
  • 0x3FA31 to 0x----- (0001) = "FIGHT" battle X coordinate
  • 0x3FA32 to 0x----- (0001) = "FIGHT" battle Y coordinate
  • 0x3FA33 to 0x----- (0001) = Text pointer byte (Low)
  • 0x3FA34 to 0x----- (0001) = Text pointer byte (High)
  • 0x3FA36 to 0x----- (0001) = "MAGIC" battle X coordinate
  • 0x3FA37 to 0x----- (0001) = "MAGIC" battle Y coordinate
  • 0x3FA38 to 0x----- (0001) = Text pointer byte (Low)
  • 0x3FA39 to 0x----- (0001) = Text pointer byte (High)
  • 0x3FA3B to 0x----- (0001) = "DRINK" battle X coordinate
  • 0x3FA3C to 0x----- (0001) = "DRINK" battle Y coordinate
  • 0x3FA3D to 0x----- (0001) = Text pointer byte (Low)
  • 0x3FA3E to 0x----- (0001) = Text pointer byte (High)
  • 0x3FA40 to 0x----- (0001) = "ITEM" battle X coordinate
  • 0x3FA41 to 0x----- (0001) = "ITEM" battle Y coordinate
  • 0x3FA42 to 0x----- (0001) = Text pointer byte (Low)
  • 0x3FA43 to 0x----- (0001) = Text pointer byte (High)
  • 0x3FA45 to 0x----- (0001) = "RUN" battle X coordinate
  • 0x3FA46 to 0x----- (0001) = "RUN" battle Y coordinate
  • 0x3FA47 to 0x----- (0001) = Text pointer byte (Low)
  • 0x3FA48 to 0x----- (0001) = Text pointer byte (High)
  • 0x3FA49 to 0x----- (0001) = Pattern table location for "FIGHT" tiles (through 3FA4C)
  • 0x3FA4E to 0x----- (0001) = Pattern table location for "MAGIC" tiles (through 3FA51)
  • 0x3FA53 to 0x----- (0001) = Pattern table location for "DRINK" tiles (through 3FA56)
  • 0x3FA58 to 0x----- (0001) = Pattern table location for "ITEM" tiles (through 3FA5B)
  • 0x3FA5D to 0x----- (0001) = Pattern table location for "RUN" tiles (through 3FA5F)
  • 0x3FA61 to 0x----- (0001) = value for which string to display in Enemy name slot 1
  • 0x3FA63 to 0x----- (0001) = value for which string to display in Enemy name slot 2
  • 0x3FA65 to 0x----- (0001) = value for which string to display in Enemy name slot 3
  • 0x3FA67 to 0x----- (0001) = value for which string to display in Enemy name slot 4

World map data

Free bytes in the original FF1 ROM

This is a list of known free bytes available in the original FF1 ROM. These bytes were gleaned from examining the ROM and Disch's 1.0 Disassembly.
Banks are noted as BANK # +/- offset (free bytes total).
Addresses are noted as Bank Address : ROM Address (Bytes free) with optional notes).
In each bank, the offset is added to or subtract from the bank address to get the ROM address.

BANK 01

+3FF0 (30 total bytes)

  • BFE2 : 0x07FF2 (30 bytes)

BANK 09

-1c010 (88 total bytes)

  • B980 : 0x27990 (384 bytes)
  • BBDA : 0x27BEA (38 bytes)
  • BEEB : 0x27EFB (21 bytes)
  • BF30 : 0x27F40 (4 bytes)
  • BF67 : 0x27F77 (25 bytes)

BANK 0B

-24010 (5 total bytes)

  • 9093 : 0x2DA03 (1 bytes)
  • A7FC : 0x2E80C (4 bytes)

BANK 0C

-28010 (37 total bytes)

  • 851C : 0x3052C (4 bytes) (padding)
  • 92F4 : 0x31304 (12 bytes)
  • BC95 : 0x33CA5 (16 bytes) (maybe)
  • BFFB : 0x3400B (5 bytes)

BANK 0D

-2C010 (70 total bytes)

  • 9DF9 : 0x35E09 (7 bytes)
  • A779 : 0x36789 (7 bytes)
  • A7E5 : 0x367F5 (27 bytes) (almost looks like it might be attributes)
  • AE02 : 0x36E12 (14 bytes)  ?unused -- fragmented code?
  • AFFE : 0x3700E (2 bytes) (that $60 might be an unused RTS -- but who cares)
  • BA9F : 0x37AAF (1 bytes)
  • BAF9 : 0x37B09 (7 bytes) (unknown / unused)
  • BEFB : 0x37F0B (5 bytes)

BANK 0E

-30010 (114 total bytes)

  • 84E2 : 0x384F2 (30 bytes)
  • 9088 : 0x39098 (9 bytes) (ClearGameEventFlag unused by the original game)
  • 94EF : 0x394FF (1 bytes) (truly unused -- no entry in the jump table)
  • 9586 : 0x39596 (14 bytes) Talk_CubeBotBad
  • 9B3E : 0x39B4E (22 bytes) UnusedRoutine_9B3E, Faux/Unused routine
  • BF3A : 0x3BF4A (22 bytes) Unused Phantom Code
  • BFF0 : 0x3C000 (16 bytes)


BANK 0F

-30010 (128 total bytes)

  • C464 : 0x3C474 (5 bytes)
  • D7BF : 0x3D7CF (3 bytes) (unused/unreachable call)
  • DB09 : 0x3DB19 (2 bytes) (unused NOPs)
  • E4BF : 0x3E4CF (8 bytes)
  • ECB9 : 0x3ECC9 (1 bytes)
  • FCBB : 0x3FCCB (7 bytes) (UNUSED_DrawBattle_IncSrcPtr)
  • FDF1 : 0x3FE01 (15 bytes) (Unused space)
  • FEEB : 0x3FEFB (23 bytes)
  • FF3C : 0x3FF4C (4 bytes)
  • FF81 : 0x3FF91 (15 bytes)
  • FFA4 : 0x3FFB4 (4 bytes)
  • FFB9 : 0x3FFC9 (7 bytes)
  • FFCD : 0x3FFDD (22 bytes) space before "FINAL FANTASY"
  • FFF0 : 0x40000 (10 bytes) space after "FINAL FANTASY"

Unused routines in the original US FF1 ROM

The following routines are either completely or partially unused in the original US FF1 ROM and can be recycled as free space.

Bank C

  • [$B674 :: 0x33684] lut_IBCharStatsPtrTable_alt - 8 bytes
  • [$B67C :: 0x3368C] lut_CharStatsPtrTable_alt - 8 bytes
 These are duplicates of the lut_IBCharStatsPtrTable and
 lut_CharStatsPtrTable tables. References to the duplicates
 can be updated to point to the originals, and the 16 contiguous
 bytes here can be used for other LUTs or a short routine.
  • [$B684 :: 0x33694] PreparePlayerMagAttack - 41 bytes
 41 of the last 42 bytes in this routine perform tasks that have no effect.
 Those bytes can be moved out of the routine and used for other tasks.
  • [$B730 :: 0x33740] PrepareEnemyMagAttack - 39 bytes
 The entire routine loads stats that simply aren't used by the routine
 or its caller.

Bank E

  • [$BEF7 :: 0x3BF07] UpdateEquipMenuModeAttrib - 55 bytes
 Likely a holdover from the Japanese version, it has no visible effect
 in the US version (since the palettes involved are identical) and
 would need to be refactored to work as intended anyway.

Bank F

  • [$FAA6 :: 0x3FAB6] DrawBattleString_ExpandChar - 55 bytes
 Another holdover from the Japanese version, part of this function
 attempts to assign the top half of characters when drawing a string.
 The default is a blank (space) character.
 Since this is always a space character in the US ROM, the code
 to choose that top tile could be removed, since a space will always
 be used.


Internal Data for Final Fantasy

ROM MapRAM MapText TableNotesTutorials