You've already forked pokecrystal-board
mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2025-04-09 05:44:44 -07:00
Adjust MAPSETUP_ENTERLEVEL (#4) and misc clean up
This commit is contained in:
@@ -2,29 +2,30 @@
|
||||
|
||||
- **hCurBoardEvent**: holds a *BOARDEVENT_* value.
|
||||
|
||||
- **wTurnData** ~ **wTurnDataEnd**: not preserved on save, and cleared at the beginning of BoardMenuScript (i.e. on turn begin). It's part of *wMapStatus* ~ *wMapStatusEnd*, so it's also cleared by *StartMap*. Includes:
|
||||
- **wTurnData** ~ **wTurnDataEnd**: turn-scoped, not preserved on save, and cleared at the beginning of BoardMenuScript (i.e. on turn begin). It's part of *wMapStatus* ~ *wMapStatusEnd*, so it's also cleared by *StartMap*. Includes:
|
||||
- **wDieRoll**
|
||||
- **wSpacesLeft**
|
||||
|
||||
- Addresses within *wCurMapData* ~ *wCurMapDataEnd*: preserved on save. Initialized when entering a level (in StartMap), and updated accordingly throughout the level. Includes:
|
||||
- **wCurTurn**
|
||||
- **wCurSpace**
|
||||
- **wCurLevelCoins**
|
||||
- **wCurLevelExp**
|
||||
- Addresses within *wCurMapData* ~ *wCurMapDataEnd*: level-scoped or turn-scoped, preserved on save. Initialized when entering a level if required (in StartMap), and updated accordingly throughout the level. Includes:
|
||||
- **wCurTurn**: initialized when entering a level (in StartMap)
|
||||
- **wCurSpace**: initialized when entering a level (in StartMap)
|
||||
- **wCurLevelCoins**: initialized when entering a level (in StartMap)
|
||||
- **wCurLevelExp**: initialized when entering a level (in StartMap)
|
||||
- **wCurSpaceStruct**:
|
||||
- **wCurSpaceXCoord**
|
||||
- **wCurSpaceYCoord**
|
||||
- **wCurSpaceEffect** for non-branch spaces, or **wCurSpaceBranchStructPtr** (two bytes) for branch spaces
|
||||
- **wCurSpaceNextSpace** for non-branch spaces
|
||||
- **wCurOverworldMiscPal**
|
||||
|
||||
- Addresses within *wPlayerData* ~ *wPlayerDataEnd*: preserved on save. Includes:
|
||||
- Addresses within *wPlayerData* ~ *wPlayerDataEnd*: game-scoped (change between levels or on level start/end, but now within), preserved on save. Includes:
|
||||
- **wUnlockedLevels**: flag array that tracks progression regarding which levels have been unlocked.
|
||||
- **wClearedLevelsStage\<N\>**: flag array that tracks progression regarding which levels have been cleared. Each level can have up to four stages (clearable endings).
|
||||
- **wUnlockedTechniques**: flag array that tracks progression regarding which techniques have been unlocked.
|
||||
- **wCurLevel**: initialized in LevelSelectionMenu (where it is also used), and stays static during the level.
|
||||
- **wDefaultLevelSelectionMenuLandmark**: used to know in which landmark to place the player when entering level selection menu.
|
||||
- **wCurOverworldMiscPal**
|
||||
- **wLevelSelectionMenuEntryEventQueue**: which events have to be triggered the next time the player enters the level selection menu.
|
||||
- **wLastUnlockedLevelsCount**, **wLastUnlockedLevels**: temporary list of unlocked levels during post-level screen
|
||||
|
||||
- These addresses share memory region with string buffers from *wStringBuffer3* onwards. They are placed in memory in the following order.
|
||||
- **wTempSpaceStruct**: Temporary scope. Same structure as *wCurSpaceStruct*
|
||||
@@ -44,7 +45,7 @@
|
||||
- **wDisabledSpacesBackups**: preserved on save to **sDisabledSpacesBackups**.
|
||||
- **wMapObjectsBackups**: preserved on save to **sMapObjectsBackups**.
|
||||
|
||||
- **wLevelSelectionMenu\*** addresses, union under the *"Miscellaneous WRAM 1"* section. Temporary scope during level selection menu, except for *wLevelSelectionMenuEntryEventQueue*.
|
||||
- **wLevelSelectionMenu\*** addresses, union under the *"Miscellaneous WRAM 1"* section. Temporary scope during level selection menu (not the case for *wLevelSelectionMenuEntryEventQueue*, which is in *wPlayerData* instead, as mentioned above).
|
||||
|
||||
- Other WRAM 0 addresses (not preserved on save):
|
||||
- **wText2bpp**
|
||||
|
Reference in New Issue
Block a user