Commit Graph
33 Commits
Author SHA1 Message Date
tustin2121 4730870646 VAR_RUN_TRIGGER_IMMEDIATELY -> TRIGGER_RUN_IMMEDIATELY
Getting rid of the VAR_ prefix, to avoid the porymap problem.
2022-10-18 21:12:31 -04:00
tustin2121 327c648e87 Document seldom-used trigger functionality
Added a define for use in overworld triggers where the goal is to run the provided script in the immediate script context instead of the global one like normal. This is used in triggers in the desert, on faraway island, and a couple other places to do weather effects quickly and on the same frame. Suggestions for a better define name are welcome.
2022-10-16 20:46:50 -04:00
tustin2121 ea168d1a6b Fix typo 2: revelations 2022-10-06 20:34:46 -04:00
tustin2121 f3bddd1ea6 Fix typo 2022-10-06 19:36:01 -04:00
tustin2121 5c55e44173 More diagrams
- Diagramed all subsprite tables in the code base. There's a LOT in the slot machine code.
2022-09-17 14:34:20 -04:00
tustin2121 c371a44a83 Formatting 2022-09-17 13:34:54 -04:00
tustin2121 13877f71dc Minor documentation
Some things I figured out while working on my hack.
- The Subsprite tables do not use `DISPLAY_WIDTH`, but rather use -16, since they are signed bytes. The negative numbers better illustrate what the tables are doing.
- Figured out the as-of-yet undocumented data in SpriteCB_FlygonSilhouette
2022-09-17 13:33:10 -04:00
tustin2121 33f10d2139 Adding missing externs
If there are not externs on these forward declarations, it's entirely possible for the program to link and missing data to be assigned to someplace presumed in IWRAM or something.
2022-09-05 09:49:20 -04:00
tustin2121 ec73158f16 Moving documentation comments per request
from the discord chat.
2022-08-15 16:37:38 -04:00
tustin2121 1cb659df8c Renaming Script Contexts
- Determined how the various script contexts were used and renamed accordingly.
- ScriptContext2_Enable/Disable => Lock/UnlockPlayerFieldControls - The sole purpose of the flag is to make sure the player can't move around in the overworld. It has nothing to do with script contexts.
- ScriptContext1 => ScriptContext - It is the global script context used to set up scripts which run over many frames.
- ScriptContext2_RunNewScript => RunScriptImmediately - ScriptContext2's sole purpose was to run scripts immediately and in a separate context, usually while the global context is waiting for things like map loads or screen changes.
2022-08-15 15:18:12 -04:00
tustin2121 be9100fe52 Review changes 2020-09-20 13:04:20 -04:00
tustin2121 832be34898 More documenting trainer hill
- Renamed members and added comments in the TrHillDisplay struct.
- Formatted the trainer hill data to better match the metatile layout its representing.
- Documented the function which uses this data.
2020-09-20 01:50:54 -04:00
tustin2121 0d3646c0b9 Trainer hill location data
Changed the trainer hill data for trainer locations, directions, and ranges from vague unusable numbers into readable data via use of preprocessor macros.
2020-09-20 01:09:22 -04:00
tustin2121 d4582cb874 Requested change from pkmn to mon 2019-11-04 16:25:46 -06:00
Tustin2121 2fe9d7a81f Document showing pokemon in credits 2019-11-04 16:25:46 -06:00
tustin2121 218fcd99b3 Itemfinder code should use flag constant 2019-10-31 21:34:03 -05:00
Tustin2121 5007d279fe Review fixes 2019-09-29 16:33:13 -04:00
tustin2121 711e7d884c Document cave transition code. 2019-09-10 13:43:33 -04:00
tustin2121 258784f263 Add supported but unused buttons to charmap.txt
These buttons are supported by the game but unused by vanilla. We should include them for use by hacks.
2019-09-08 10:44:43 -05:00
tustin2121 cdae0c1444 Change event object graphics pointer table to use explicit indexes
- This makes it easier for future hack makers to rearrange, add, or delete graphic object ids without having to count indexes or keep them in order.
- Porymap will have to be updated, but I have some code for this already in a fork.
2019-08-29 16:44:10 -05:00
tustin2121 82744ba636 Replace {STRING 5} with {KUN}
Since we already have the KUN placeholder, there's no need for this {STRING 5} stuff.

Also, it makes it easier to delete all the {KUN}s in hacks later on if desired.
2019-08-21 14:05:22 -04:00
Tustin2121 18dee14170 Review fixes 2019-08-17 23:26:46 -04:00
Tustin2121 d63a8ba817 Replaced createvobject numbers with EVENT_OBJ_GTX defines
Doing this allows someone to renumber the event object graphics and still have working contests.
2019-08-17 13:38:13 -04:00
Tustin2121 a708caac6d Suggested changes from review 2019-08-17 13:32:26 -04:00
Tustin2121 1069adae46 Renaming unknown link room ids to be the same as name
This descrepency was causing a lot of annoyance when using porymap, because porymap generated the ids in map_groups.h from the name, and mapjson was generating map_groups.h from the id in the json files. So just name them the same already like every other map in the repo.
2019-08-17 13:26:57 -04:00
Tustin2121 d12a8c10ee Documenting credits a bit 2019-08-17 13:26:44 -04:00
Tustin2121 bac8974ce3 Added note about addvar
The contest scripts actually use addvar to add a -1 to a variable instead of using subvar to subtract a positive number. This is fine in vanilla, where addvar script command does NOT support adding the value of a variable to another variable (like subvar supports), but should anyone want to change it, contests will be inexplicably broken.
2019-08-17 13:26:31 -04:00
Tustin2121 f4d4424618 Folded nops into hidemoneybox and updatemoneybox
The nops are essential to the hidemoneybox and updatemoneybox commands when using vanilla versions of those commands. Even though they're not actually used parameters in the command implementation, they are still consumed, which means if someone were to get rid of the nops (as I did in TriHard) it causes the commands to consume bytecode that are not theirs, resulting in undefined behavior usually leading to softlocks. Folding the extra bytes into the macros means there's no chance of the extra bytes getting losts in scripts.
2019-08-17 13:25:36 -04:00
Tustin2121 9bcd39d86c Document the braille window id. 2019-08-17 13:20:18 -04:00
Tustin2121 6508469259 Rename movobjectoffscreen to copyobjectxytoperm
Renaming the command to something that makes more sense as to what the command actually does. The command copies the current xy of the instantiated object back to its template, so that the object remains in the same place if the player walks away and despawns the object, and then comes back. "moveobjectoffscreen" implies that it might be taking the object and moving it physically to an off-screen location somehow.
2019-08-17 13:18:56 -04:00
Tustin2121 ea724278b7 Juan text buffer overflow note 2019-08-17 13:05:55 -04:00
Tustin2121 4a785e66ba Changing descriptions to not be file names 2019-02-24 10:20:31 -06:00
tustin2121 8711bc5156 Document HEALTHBOX_GRX_* in battle_interface.c
Most of these are referenced via offsets, like the HP bar, which uses [0 pixels] + (number of pixels) to reference which chunk to draw. Each corresponds to a 16x16 pixel in the graphic named. Up to you guys if you want to rename the constants.
2019-02-24 10:20:31 -06:00