mirror of
https://github.com/zeldaret/oot.git
synced 2025-07-17 13:24:45 +00:00
Automate fixing BSS ordering (#2009)
* Automate fixing BSS ordering * Typo * Some cleanups * Move pragma check after printing BSS info * Some proofreading * multiprocessing, require version, some colors * Tweak output * Black + mypy * Move logging and sys.exit out of helper functions * Use stdout instead of stderr in fix_bss.py * Add suggestion to conflicting offsets error Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * Remove var = list[T]() * Improve error handling Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * Add error if no pointers to BSS * Add comment about process_file_worker * Only print updates if stdout is a tty * Use new binary-search-esque candidate generation algorithm Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com> * Add Wikipedia link * More comment tweaks --------- Co-authored-by: Dragorn421 <Dragorn421@users.noreply.github.com>
This commit is contained in:
parent
078e21f6c6
commit
0da402b9de
21 changed files with 1071 additions and 352 deletions
|
@ -7,10 +7,7 @@
|
|||
#include "assets/objects/gameplay_keep/gameplay_keep.h"
|
||||
#include "assets/objects/gameplay_field_keep/gameplay_field_keep.h"
|
||||
|
||||
// For retail BSS ordering, the block number of sLensFlareUnused must be lower
|
||||
// than the extern variables declared in the header (e.g. gLightningStrike)
|
||||
// while the block number of sNGameOverLightNode must be higher.
|
||||
#pragma increment_block_number 80
|
||||
#pragma increment_block_number "gc-eu:128 gc-eu-mq:128"
|
||||
|
||||
typedef enum {
|
||||
/* 0x00 */ LIGHTNING_BOLT_START,
|
||||
|
@ -215,10 +212,7 @@ s16 sLightningFlashAlpha;
|
|||
s16 sSunDepthTestX;
|
||||
s16 sSunDepthTestY;
|
||||
|
||||
// These variables could be moved farther down in the file to reduce the amount
|
||||
// of block number padding here, but currently this causes BSS ordering issues
|
||||
// for debug.
|
||||
#pragma increment_block_number 217
|
||||
#pragma increment_block_number "gc-eu:128 gc-eu-mq:128"
|
||||
|
||||
LightNode* sNGameOverLightNode;
|
||||
LightInfo sNGameOverLightInfo;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue