View Single Post
  #160    
Old September 9th, 2011 (12:13 AM). Edited September 9th, 2011 by DavidJCobb.
DavidJCobb DavidJCobb is offline
RESIDENT RAAAAAAAAAAAAGEMASTER
 
Join Date: Jul 2010
Gender: Male
Nature: Lonely
Posts: 275
Quote originally posted by knizz:
DavidJCobb, I wish I knew you when I was still ROM Hacking. Great work.
Thanks. I've seen some of your work; coming from someone of your skill, that compliment means a lot.

* * * * *

Building on some work by knizz --

Quote originally posted by knizz:
As I said once in another thread there is an array of npc-data at 02036E38 . . .
-- I have deciphered more of the OW/Person data structure:

Bytes 0 - 8: Unknown.
Byte 9: Map number for this Person event.
Byte 10: Map bank number for this Person event.
Bytes 11 - 15: Unknown
Bytes 16 - 17: Tile X (stepping off of)
Bytes 18 - 19: Tile Y (stepping off of)
Bytes 20 - 21: Tile X (stepping onto)
Bytes 22 - 23: Tile Y (stepping oto)
Byte 24: Unknown. Changes with last movement direction. (11 down, 44 right, 33 left)
Bytes 25 - 27: Unknown.
Byte 28: Sprite frame
Bytes 29 - 31: Unknown.
Byte 32: Facing direction (same format as PLAYERFACING script var's values).
Bytes 33 - 35: Unknown.

Offset of the facing direction byte for Person event N: 0x02036E38 + (0x24 * N) + 0x20

* * * * *

EDIT: Found offsets for some scripts that people may find interesting.

0x081A4EB4 and 0x081A4EC1
Something to do with trainer battles... Is this used by the core game engine?

0x081A6843
This script handles hidden-item Signposts. Inputs are 0x8005 (item ID) and 0x8006 (amount). If the item ID is 0 (item: ????????) then it is treated as a Coins pickup.

0x081A6955
Script for the PC.

0x081A6AC8
Script for SURF. It does not include the badge check; that is evidently done in ASM before this is called.

0x081A6B0D
Script for current that is too fast to SURF in.

0x081A7705
Script for the Mystery Gift questionnaire.

0x081A77A0
Appears to be the script that is executed if you press Select without having a Key Item registered to that button.

0x081A8D49
I have no idea, but it has something to do with digging up an item. Where in FireRed can you do that?

0x081A8D97
Script for PokeCenter healing after whiting out.

0x081A8DD8
Script for Mom healing after whiting out.

0x081A8DFD
Script for whiting out (on the overworld, in battles, or both?).

0x081AD008
Script for a Fame Checker entry. This actually runs inside the Fame Checker. The others probably do, too.

0x081BE2B7
Script for WATERFALL. Like the SURF script, the badge check is performed elsewhere.

0x081BE38B
Script for DIVE (submerging). Apparently an R/S/E leftover. Like SURF and WATERFALL, there's no badge check here.

0x081BE3D4
Script for DIVE (emerging). No badge check.

0x081BE420
Script for if you try to use DIVE when you cannot emerge at the spot you're currently standing on.

0x081BF546
Internal script for hatching an EGG (by walking).

0x081BFB65
Script executed when REPEL wears off.

* * * * *

And some string offsets:

0x0826CF8C - 0x0826D19D
Nicknames of the Pokemon you can receive in in-game trades.

0x081C55C9
Strings for saving the game.

0x081B2DF8 - 0x081BB1B3(?)
L/R help strings.
__________________
Reply With Quote