docs: complete legacy source analysis

This commit is contained in:
Nighthawk42
2026-08-23 21:11:48 -04:00
parent f96ad71673
commit b2e8b2e38d
5 changed files with 156 additions and 57 deletions
+2 -2
View File
@@ -6,7 +6,7 @@ This branch is an analysis-only bootstrap for a Mainline-first modernization of
The preserved 8,401-line Mainline source must be analyzed sequentially, in evidence-backed batches, before runtime work begins. All behavior-critical shortened symbols must be resolved and all batches must be complete before any public Lua API, runtime module, modern TOC, packaging, or release work is added.
Batches 0116 (lines 18,000) are documented. The final batch remains scheduled but not analyzed.
All 17 batches (lines 18,401) are documented. Runtime work remains gated on a cross-batch audit that resolves or classifies the remaining behavior-critical `working`/`unresolved` ledger entries and verifies every retained Retail API contract.
## Goal
@@ -26,6 +26,6 @@ The eventual addon will target current Retail/Mainline World of Warcraft while p
Analysis contributions must proceed in schedule order and cite exact legacy line numbers. Record every shortened identifier by declaration and lexical scope, distinguish evidence from inference, retain unresolved names when proof is incomplete, and update the shared ledger with each batch. Do not edit preserved legacy code or assets.
Runtime contributions are premature until all 8,401 lines have been covered exactly once and behavior-critical symbols are resolved. Future Lua must remain Lua 5.1 compatible and must use current, verified Mainline APIs.
Runtime contributions remain premature until the completed coverage is converted into a closed behavior-critical symbol audit and implementation-ready API contract set. Future Lua must remain Lua 5.1 compatible and must use current, verified Mainline APIs.
See `ACKNOWLEDGEMENT.md` for attribution and the boundary between preserved legacy material and newly authored MIT-licensed work.
+1 -1
View File
@@ -20,6 +20,6 @@ The immutable analysis source is `Legacy/Bejeweled_Mainline.lua` from commit `6f
| 14 | 65017000 | 500 | `lines-6501-7000.md` | complete |
| 15 | 70017500 | 500 | `lines-7001-7500.md` | complete |
| 16 | 75018000 | 500 | `lines-7501-8000.md` | complete |
| 17 | 80018401 | 401 | `lines-8001-8401.md` | pending |
| 17 | 80018401 | 401 | `lines-8001-8401.md` | complete |
Count check: `16 × 500 + 401 = 8,401`.
+100 -53
View File
@@ -5,7 +5,7 @@ Each row identifies one declaration, not merely one spelling. `chunk` means the
| Legacy identifier / lexical scope | Decl. | Observed reads, writes, calls, keys, arithmetic | Working or proposed name | Status | Confidence / evidence | Firstlast batch | Target subsystem | Open question |
| --- | ---: | --- | --- | --- | --- | --- | --- | --- |
| `t` / chunk (first binding) | 4 | String initializer only before shadow at 186. | `addonRootPath` | dead | High: path literal at 4; no read before 186. | 0101 | Core/Constants | Was elimination intentional? |
| `l` / chunk | 5 | Image/font root used for bundled fonts and attempted legal-popup background path (5, 618, 633, 1664). | `imageRootPath` | resolved | High: literal and direct asset-path consumers. | 0104 | Core/Constants | Other consumers remain to inventory. |
| `l` / chunk | 5 | Image/font root used for bundled fonts, UI art, board/status/HUD textures, and the attempted legal-popup background path through final bootstrap (5, 618, 633, 1664, 80728321). | `imageRootPath` | resolved | High: literal and direct asset-path consumers. | 0117 | Core/Constants | None. |
| `ut` / chunk | 6 | Path initializer; no batch-01 read. | `soundRootPath` | working | High: literal ends in `sounds\` (6). | 0101 | Core/Audio | Confirm path casing/contracts. |
| `xe` / chunk | 7 | Starts as `BEJEWELED2`; migration may change it to `BEJ2a` (3563), and network factory registers it alongside literal `BEJ2a` (49724973). | `addonMessagePrefix` | resolved | High. | 0110 | Core/Init, Persistence/Migration, Network | Preserve dual registration. |
| `ft` / chunk | 8 | Seven colored gem-name strings indexed by maximum `stats.gemMatch` entry for favorite-color display (70267035). | `coloredGemDisplayNames` | resolved | High. | 0115 | UI/Stats | Tie logic is asymmetric. |
@@ -21,17 +21,17 @@ Each row identifies one declaration, not merely one spelling. `chunk` means the
| `e` / first atlas loop | 188 | Loop values 04; multiplies row offsets and indices (189203). | `row` | resolved | High: numeric-for and row arithmetic (188203). | 0101 | UI/Animations | None for this scope. |
| `e` / second atlas loop | 211 | Loop values 03; computes vertical quarters (212215). | `row` | resolved | High: loop and `/4` UV math (211215). | 0101 | UI/Animations | None for this scope. |
| `e` / third atlas loop | 218 | Loop values 02; computes 3×3 indices/UVs (219221). | `row` | resolved | High: loop and `*3`/`.33` math (218221). | 0101 | UI/Animations | Exact `.33` edge behavior later. |
| `K` / chunk | 227 | Starts at zero; accumulates every value in `BejeweledData.played` during achievement setup (13971399). | `totalGamesAcrossCharacters` | resolved | High: direct account-data sum. | 0103 | Core/SavedVariables | Not reset before summing; assess repeat calls. |
| `K` / chunk | 227 | Starts at zero, accumulates every `BejeweledData.played` value, and gates a splash-hide achievement above 1,000 games (13971399, 83238325). | `totalGamesAcrossCharacters` | resolved | High: direct account-data sum and threshold consumer. | 0117 | Core/SavedVariables, UI/HUD | Accumulator is not reset before repeat initialization. |
| `Ye` / chunk | 228 | Constant `24`; halved into `pt` (285). | unknown dimension | unresolved | Low: declaration/arithmetic only. | 0101 | UI/GemPool | Which axis/object? |
| `Ze` / chunk | 229 | Constant `24`; halved into `ct` (286), then shadowed by command function at 3619. | unknown dimension | unresolved | Low: declaration/arithmetic only. | 0108 | UI/GemPool | Which axis/object? |
| `b` / chunk | 230 | Constant `50`; halved into `ce`; multiplies horizontal match-length offset (283, 1013). | `gemWidth` | resolved | High: direct X-coordinate geometry. | 0103 | UI/GemPool | None. |
| `p` / chunk | 231 | Constant `50`; copied/halved; multiplies vertical match-length offset (272, 274, 284, 1014). | `gemHeight` | resolved | High: direct Y-coordinate geometry. | 0103 | UI/GemPool | None. |
| `b` / chunk | 230 | Constant `50`; halved into `ce`, drives horizontal match offsets, and spaces final gem-frame X positions (283, 1013, 8375). | `gemWidth` | resolved | High: direct X-coordinate geometry. | 0117 | UI/GemPool | None. |
| `p` / chunk | 231 | Constant `50`; copied/halved, drives vertical match offsets, and spaces final gem-frame Y positions (272, 274, 284, 1014, 8375). | `gemHeight` | resolved | High: direct Y-coordinate geometry. | 0117 | UI/GemPool | None. |
| `lt` / chunk | 232 | Constant expression `70 + 20`; no batch-01 read. | unknown 90-pixel dimension | unresolved | Low: declaration only. | 0101 | UI | Locate consumers. |
| `Ue` / chunk | 233 | Constant expression `70 + 20`; no batch-01 read. | unknown 90-pixel dimension | unresolved | Low: declaration only. | 0101 | UI | Paired with `lt`? |
| `Qe` / chunk | 234 | Constant expression `100 + 50`; halved by dead `t` at 287. | unknown 150-pixel dimension | unresolved | Low: declaration and dead derivation. | 0101 | UI | Locate live consumer. |
| `qe` / chunk | 235 | Constant expression `100 + 50`; halved by dead `t` at 288. | unknown 150-pixel dimension | unresolved | Low: declaration and dead derivation. | 0101 | UI | Locate live consumer. |
| `s` / chunk | 236 | Constant `400`; used in `q = s + 32 + 16` (238). | board width | working | Medium: 8 × likely 50-pixel cells. | 0101 | Engine/Grid, UI/GemPool | Confirm coordinate ownership. |
| `w` / chunk | 237 | Constant `400`; used in `me = w + 110` (239). | board height | working | Medium: paired with `s`. | 0101 | Engine/Grid, UI/GemPool | Confirm coordinate ownership. |
| `s` / chunk | 236 | Constant `400`; derives main-window width and directly sizes the final game surface/tiles (`s / 4`) and board (`s + 14`) (238, 8041, 8054, 8064, 8068). | `boardWidth` | resolved | High: final construction confirms 8 × 50-pixel board geometry. | 0117 | Engine/Grid, UI/GemPool | None. |
| `w` / chunk | 237 | Constant `400`; derives main-window height and directly sizes the final game surface/tiles (`w / 4`) and board (`w + 12`) (239, 8039, 8042, 8055, 8065, 8069). | `boardHeight` | resolved | High: final construction confirms paired board geometry. | 0117 | Engine/Grid, UI/GemPool | None. |
| `q` / chunk | 238 | Derived `448`; assigned main-window width by legal display (1651). | `mainWindowWidth` | resolved | High: direct frame geometry. | 0104 | UI/HUD | Padding derivation rationale remains. |
| `me` / chunk | 239 | Derived `510`; assigned main-window height by legal display (1652). | `mainWindowHeight` | resolved | High: direct frame geometry. | 0104 | UI/HUD | Padding derivation rationale remains. |
| `f` / chunk | 240 | Constant `160`; legal popup width is `f×2` and text width `f×1.8` (1658, 1676). | `legalPopupHalfWidth` | resolved | High: direct geometry use. | 0104 | UI/HUD | Name reflects legacy arithmetic. |
@@ -96,14 +96,14 @@ Each row identifies one declaration, not merely one spelling. `chunk` means the
| `Fe` / chunk | 299 | Constant `6`; no batch-01 read. | unknown enum six | unresolved | Low. | 0101 | Engine | Locate consumers. |
| `nt` / chunk | 300 | Constant `1`; no batch-01 read. | unknown enum one | unresolved | Low. | 0101 | Engine | Locate consumers. |
| `Ne` / chunk | 301 | Constant `2`; no batch-01 read. | unknown enum two | unresolved | Low. | 0101 | Engine | Locate consumers. |
| `Ie` / chunk | 302 | Receives `string.byte`, copied to `j` (312), nilled (328). | temporary `string.byte` alias | dead | High: direct alias chain. | 0101 | Core | None after `j` capture. |
| `Be` / chunk | 303 | Receives `string.char`, copied to `P` (313), nilled (329). | temporary `string.char` alias | dead | High. | 0101 | Core | None after `P` capture. |
| `Ge` / chunk | 304 | Receives `string.sub`, copied to `G` (318), nilled (330). | temporary `string.sub` alias | dead | High. | 0101 | Core | None after `G` capture. |
| `Ae` / chunk | 305 | Receives `math.floor`, copied to `d` (314), nilled (331). | temporary `math.floor` alias | dead | High. | 0101 | Core | None after `d` capture. |
| `Ie` / chunk | 302 | Supplies `string.byte` to `j`, is nilled, then receives game-surface frame level `+4` at 8371 without an in-file read. | temporary byte alias / unused frame tier | resolved | High: both temporal roles and dead final value are explicit. | 0117 | Core, UI/GemPool | None. |
| `Be` / chunk | 303 | Supplies `string.char` to `P`, is nilled, then receives game-surface frame level `+2` and positions every final gem frame at that tier (313, 329, 8369, 8381). | `gemFrameLevel` after temporary char alias | resolved | High: final assignment and 64 direct consumers. | 0117 | Core, UI/GemPool | Split temporal roles in rewrite. |
| `Ge` / chunk | 304 | Supplies `string.sub` to `G`, is nilled, then receives game-surface frame level `+5` at 8372 without an in-file read. | temporary substring alias / unused frame tier | resolved | High: both temporal roles and dead final value are explicit. | 0117 | Core, UI/GemPool | None. |
| `Ae` / chunk | 305 | Supplies `math.floor` to `d`, is nilled, then receives game-surface frame level `+6` at 8373 without an in-file read. | temporary floor alias / unused frame tier | resolved | High: both temporal roles and dead final value are explicit. | 0117 | Core, UI/GemPool | None. |
| `t` / chunk (line 306) | 306 | Receives `tostring`, copied to `Y` (317), nilled (332). | temporary `tostring` alias | dead | High. | 0101 | Core | None after `Y` capture. |
| `m` / chunk | 307 | Copies `math.random`; drives gem velocities/spawn gaps, special placement/shards, and skill-gain probability through line 6667, then is shadowed by About factory at 7413. Earlier closures retain it. | `random` | resolved | High. | 0115 | Engine/Grid, UI/Animator, Engine/Skills | None. |
| `c` / chunk | 309 | Constant `1`; keys `Ce`; controls classic score/bar/results and pause alpha behavior (467, 500, 536, 611, 881, 12781352). | `GAME_MODE_CLASSIC` | resolved | High: repeated explicit classic behavior. | 0103 | Core/Constants | None for identity. |
| `ae` / chunk | 310 | Constant `2`; keys `Ce`; pause handling shows/hides `pausedText` specifically for this mode (12991304). | `GAME_MODE_TIMED` | resolved | High: paired PPS evidence plus explicit pause UI. | 0103 | Core/Constants | None for identity. |
| `c` / chunk | 309 | Constant `1`; keys `Ce`; controls classic score/bar/results/pause behavior and final New Game/splash classic launches (467, 500, 536, 611, 881, 12781352, 82458248, 83448348). | `GAME_MODE_CLASSIC` | resolved | High: complete-file explicit classic behavior. | 0117 | Core/Constants | None. |
| `ae` / chunk | 310 | Constant `2`; keys `Ce`; pause handling shows/hides `pausedText` and final New Game routing opens the timed menu for this mode (12991304, 82438244). | `GAME_MODE_TIMED` | resolved | High: paired PPS, pause UI, and final routing evidence. | 0117 | Core/Constants | None. |
| `k` / chunk | 311 | Game-mode constant `3`; controls flight-learning timer/pause/animator/start/end behavior through line 7917, then is shadowed by compatibility function at 7995. Earlier closures retain it. | `GAME_MODE_FLIGHT_LEARNING` | resolved | High. | 0116 | Core/Constants, UI/Flight | Preserve numeric mode value. |
| `T` / chunk (score-table binding) | 312 | Nine-number array indexed by `n.combo`, capped at final entry (977980); shadowed at 1266, while earlier `M` retains it lexically. | `comboBaseScores` | resolved | High: direct scoring use and capture. | 0103 | Engine/Scoring | Confirm whether combo resets per move/cascade. |
| `Ce` / chunk | 312 | Mode-keyed values scale non-classic bar maximum and final match points (626, 1007). | `modeScoreMultiplier` | resolved | High: two direct arithmetic consumers. | 0103 | Core/Constants | Same factor serves range and score scaling. |
@@ -118,19 +118,19 @@ Each row identifies one declaration, not merely one spelling. `chunk` means the
| `R` / chunk | 320 | Copies `type`; rejects non-string scores and identifies numeric gem fields during reset (742, 1955). | `valueType` | resolved | High: direct alias and calls. | 0104 | Core/SavedVariables, UI/GemPool | None. |
| `re` / chunk (numeric overwrite) | 321 | Overwrites earlier binding with `40`; no batch-01 read. | unknown constant 40 | unresolved | Low. | 0101 | Unassigned | Locate consumers. |
| `z` / chunk (numeric overwrite) | 322 | Overwrites earlier binding with `7`; no batch-01 read. | unknown enum seven | unresolved | Low. | 0101 | Engine | Locate consumers. |
| `o` / chunk | 323 | Eight row tables initialized, exported as `debugArray`, and traversed as `o[row][column]` gem frames (324326, 442, 12751293). | `gemGrid` | resolved | High: explicit 8×8 traversal. | 0103 | Engine/Grid, UI/GemPool | Debug export naming is incidental. |
| `o` / chunk | 323 | Eight row tables initialized/exported as `debugArray`, traversed as gem frames, and populated with all 64 final one-based gem objects (324326, 442, 12751293, 83828384). | `gemGrid` | resolved | High: explicit 8×8 construction and traversal. | 0117 | Engine/Grid, UI/GemPool | Debug export naming is incidental. |
| `e` / debug-array loop | 324 | Loop 18; indexes `o` for writes (325). | `index` | resolved | High: direct loop role. | 0101 | Core/Init | None. |
| `v` / chunk | 327 | Key for authenticated personal-best payloads in current-game/profile classic/timed stats (887, 900, 34903491, 36013613). | `statEncodedScoreKey` | working | High for role; concrete selected key pending. | 0108 | Core/SavedVariables | Find mode-specific assignments. |
| `v` / chunk | 327 | Key for authenticated personal-best payloads; final bootstrap assigns `x(1378301, 4)`, which deterministically encodes to literal `data` (887, 900, 34903491, 36013613, 8004). | `statDataKey` | resolved | High: complete consumers plus exact base-70 derivation `d-a-t-a`. | 0117 | Core/SavedVariables | Preserve `data` in profile wire format. |
| `I` / chunk | 327 | Key for decoded current/profile numeric bests (885886, 898899, 36033612); summary construction assigns lowercase suffix of `Final Score`, definitively `score` (6288). | `statScoreKey` | resolved | High. | 0113 | Core/SavedVariables, UI/Summary | None. |
| `ge` / chunk | 327 | Populated by `ze` with faction-selected four-region coordinate adjacency graphs (10401249); disabled taxi estimator compares its candidate timing table with this graph (6213). | `flightGraph` | resolved | High. | 0113 | Core/SavedVariables, UI/Flight | Disabled estimator conflates graph/timing-table shapes. |
| `we` / chunk | 327 | Set when max-score level-up begins (529); during level spawning it counts/removes carried hyper and big-star state for later restoration (38903906). | `levelSpawnSpecialRecovery` | working | Medium-high. | 0108 | Engine/Scoring, Engine/BoardSpawn | Find reset and full restoration completion. |
| `r` / chunk | 333 | Six-entry array of four-number direction/offset tuples. | neighbor/offset patterns | working | Medium: signed coordinate-like tuples. | 0101 | Engine/Matches | Establish tuple field semantics. |
| `n` / chunk | 334 | Exported current-game state; drives scoring/pause/events/save metadata and receives erroneous `bgFile` write (443, 464529, 8741008, 12741407, 1664, 19241933). | `currentGame` | resolved | High: explicit debug export and repeated state transitions. | 0104 | Engine/Grid, Engine/Scoring | Full dynamic table shape still grows later. |
| `C` / chunk function | 444 | Returns a fresh backdrop descriptor; consumers mutate/apply it to legal and score-migration popups (445452, 16631668, 35013508). | `createBackdropInfo` | resolved | High. | 0108 | UI/Backdrops | None. |
| `n` / chunk | 334 | Exported current-game state drives scoring, pause, events, save metadata, New Game routing, and splash resume logic; it also receives the erroneous `bgFile` write (443, 464529, 8741008, 12741407, 1664, 19241933, 82428250, 83468357). | `currentGame` | resolved | High: complete-file state transitions and final consumers. | 0117 | Engine/Grid, Engine/Scoring, UI/HUD | Dynamic shape is documented across batch reports. |
| `C` / chunk function | 444 | Returns a fresh backdrop descriptor; consumers mutate/apply it from popups through final board/HUD construction (445452, 16631668, 35013508, 80438301). | `createBackdropInfo` | resolved | High. | 0117 | UI/Backdrops | None. |
| `st` / chunk function | 455 | Reads `e.animated`; appends `e` to `t.animationStack`; writes flag true (456459). | `queueAnimationOnce` | working | High: full function body. | 0101 | UI/Animations | Identify owner and element types at call sites. |
| `t` / `st` parameter | 455 | Table-key read `t.animationStack` passed to `table.insert` (457). | `animationOwner` | working | Medium: body only. | 0101 | UI/Animations | Concrete frame/controller type. |
| `e` / `st` parameter | 455 | Reads/writes key `animated`; inserted into stack (456458). | `animation` | working | Medium: body only. | 0101 | UI/Animations | Concrete table/frame type. |
| `ht` / chunk function | 462 | Writes score/game state, checks thresholds, emits level/multiplier UI/audio, marks level-up, then updates bar (463533). | `setScore` | resolved | High: complete body. | 0102 | Engine/Scoring, UI/HUD | Method attachment still pending. |
| `ht` / chunk function | 462 | Writes score/game state, checks thresholds, emits level/multiplier UI/audio, marks level-up, then updates bar; attached as `levelBar.SetScore` at 8198. | `setScore` | resolved | High: complete body and final method attachment. | 0117 | Engine/Scoring, UI/HUD | None. |
| `i` / `ht` parameter | 462 | Score/level-bar controller: reads range, writes score, and calls `UpdateBar`; nested local shadows it only inside level-up branch (463531). | `levelBar` | resolved | High: complete receiver contract. | 0102 | UI/HUD | Method attachment still pending. |
| `t` / `ht` parameter | 462 | Assigned to both score fields; compared against thresholds/max (465498). | `score` | resolved | High: direct data flow and comparisons. | 0101 | Engine/Scoring | None for observed prefix. |
| `o` / `ht` local | 464 | Aliases `n`; score write, mode/leveledUp reads (466500). | `gameState` | resolved | High: direct alias. | 0101 | Engine/Scoring | Function continuation pending. |
@@ -148,24 +148,24 @@ Only direct standard-library aliases, loop counters with complete local bodies,
| `t` / `ht` multiplier branch | 510 | Receives each floating-text object; fields/methods set before animator insertion (512520). | `floatingText` | resolved | High: complete loop use. | 0202 | UI/Animations | None. |
| `n` / `ht` multiplier branch (pre-loop) | 510 | Nil declaration immediately shadowed by numeric-for variable at 511. | — | dead | High: lexical shadow before read. | 0202 | Unassigned | Minifier artifact. |
| `n` / `ht` floating-text loop | 511 | Numeric-for values 25325 step 100; used as X coordinate (512, 516). | `x` | resolved | High: direct call argument. | 0202 | UI/Animations | None. |
| `Tt` / chunk function | 535 | Complete classic score/non-classic timer bar rendering body (536595). | `updateLevelBar` | resolved | High: complete body and UI effects. | 0202 | UI/HUD | Method attachment pending. |
| `Tt` / chunk function | 535 | Complete classic score/non-classic timer bar rendering body; attached as `levelBar.UpdateBar` at 8202. | `updateLevelBar` | resolved | High: complete body, UI effects, and attachment. | 0217 | UI/HUD | None. |
| `t` / `Tt` parameter | 535 | Reads mode/score/range/timer and updates bar/text (536593). | `levelBar` | resolved | High: complete receiver shape. | 0202 | UI/HUD | None. |
| `n`,`e`,`o` / `Tt` timed-display branch | 553 | Minute, second, and optional minimum-width `.01`; all assigned/consumed within 554574. | `minutes`, `seconds`, `minimumWidth` | resolved | High: complete branch flow. | 0202 | UI/HUD | None. |
| `n`,`e` / `Tt` learning-display branch | 577 | Minute and second format elapsed time (578592). | `minutes`, `seconds` | resolved | High: complete branch flow. | 0202 | UI/HUD | None. |
| `o` / `Tt` learning-display branch | 577 | Declared but never read or written. | — | dead | High: complete branch body. | 0202 | Unassigned | Minifier artifact. |
| `Bt` / chunk function | 597 | Assigns score range fields (598599). | `setMinMaxScore` | resolved | High: complete body. | 0202 | UI/HUD | Method attachment pending. |
| `Bt` / chunk function | 597 | Assigns score range fields and is attached as `levelBar.SetMinMaxScore` at 8199. | `setMinMaxScore` | resolved | High: complete body and final attachment. | 0217 | UI/HUD | None. |
| `e`,`n`,`t` / `Bt` parameters | 597 | Receiver plus values written to `minScore` and `maxScore`. | `levelBar`, `minScore`, `maxScore` | resolved | High: direct assignments. | 0202 | UI/HUD | None. |
| `xt` / chunk function | 602 | Adds delta to receiver score and delegates to `SetScore` (603). | `addScore` | resolved | High: complete body. | 0202 | Engine/Scoring, UI/HUD | Method attachment pending. |
| `xt` / chunk function | 602 | Adds delta to receiver score, delegates to `SetScore`, and is attached as `levelBar.AddScore` at 8200. | `addScore` | resolved | High: complete body and final attachment. | 0217 | Engine/Scoring, UI/HUD | None. |
| `e`,`t` / `xt` parameters | 602 | Receiver and score delta are read at 603. | `levelBar`, `delta` | resolved | High. | 0202 | Engine/Scoring, UI/HUD | None. |
| `n` / `xt` parameter | 602 | Never read in the complete body. | — | dead | High. | 0202 | Unassigned | Why third argument existed. |
| `rt` / chunk function | 606 | Initializes mode-specific level/timer bar and related HUD layout (607644). | `initializeModeBar` | resolved | High: complete body. | 0202 | UI/HUD | Method attachment pending. |
| `rt` / chunk function | 606 | Initializes mode-specific level/timer bar/HUD layout and is attached as `levelBar.SetMode` at 8201. | `initializeModeBar` | resolved | High: complete body and final attachment. | 0217 | UI/HUD | None. |
| `t`,`o`,`i` / `rt` parameters | 606 | Receiver, mode value, and timer/duration seed drive all branches (608642). | `levelBar`, `gameMode`, `timerValue` | resolved | High: direct branch and call flow. | 0202 | UI/HUD | Exact units of `i` by caller. |
| `n` / `rt` local | 607 | Self-initializer captures outer current-game `n`, but the new alias is never read. | — | dead | High: no read in complete body. | 0202 | Unassigned | Minifier artifact. |
| `kt` / chunk function | 646 | Sets timer start/remaining/elapsed and starts it (647651). | `setTimer` | resolved | High: complete body. | 0202 | UI/HUD | Method attachment pending. |
| `kt` / chunk function | 646 | Sets timer start/remaining/elapsed, starts it, and is attached as `levelBar.SetTimer` at 8203. | `setTimer` | resolved | High: complete body and final attachment. | 0217 | UI/HUD | None. |
| `e`,`t` / `kt` parameters | 646 | Receiver and optional initial seconds populate timer fields. | `levelBar`, `duration` | resolved | High. | 0202 | UI/HUD | None. |
| `Ft` / chunk function | 653 | Resets update accumulator and shows timer (654656). | `startTimer` | resolved | High: complete body. | 0202 | UI/HUD | Frame update handler pending. |
| `Ft` / chunk function | 653 | Resets update accumulator, shows timer, and is attached as `levelBar.StartTimer` at 8204. | `startTimer` | resolved | High: final method and update-frame wiring are visible. | 0217 | UI/HUD | None. |
| `e` / `Ft` parameter | 653 | Receiver whose `timer` is reset/shown. | `levelBar` | resolved | High. | 0202 | UI/HUD | None. |
| `Pt` / chunk function | 658 | Hides timer (659). | `stopTimer` | resolved | High: complete body. | 0202 | UI/HUD | Whether hide pauses all update behavior. |
| `Pt` / chunk function | 658 | Hides timer and is attached as `levelBar.StopTimer` at 8205; hiding the update frame pauses its updates. | `stopTimer` | resolved | High: complete body and final attachment. | 0217 | UI/HUD | None. |
| `e` / `Pt` parameter | 658 | Receiver whose timer is hidden. | `levelBar` | resolved | High. | 0202 | UI/HUD | None. |
| `X` / chunk function | 662 | Converts legacy base-70 text to number with optional centered signed offset; migration consumes it through 3610 before gravity function shadows it at 4041. | `decodeBase70` | resolved | High. | 0209 | Core/SavedVariables | Preserve malformed-input behavior. |
| `n`,`l` / `X` parameters | 662 | Encoded string and boolean signed-mode flag (665679). | `encoded`, `signed` | resolved | High. | 0202 | Core/SavedVariables | None. |
@@ -174,7 +174,7 @@ Only direct standard-library aliases, loop counters with complete local bodies,
| `e` / `X` local | 664 | Receives each byte/digit and is normalized before arithmetic (667673). | `digit` | resolved | High. | 0202 | Core/SavedVariables | None. |
| `o` / `X` second declaration | 665 | Starts at `#encoded-1`, supplies exponent, decrements each loop (673674). | `exponent` | resolved | High. | 0202 | Core/SavedVariables | None. |
| `i` / `X` loop | 666 | Iterates encoded character positions 1..length (667). | `index` | resolved | High. | 0202 | Core/SavedVariables | None. |
| `x` / chunk function | 682 | Converts numbers to fixed-width base-70 text; used by score/network/save authentication (683711, 818853, 887911, 1933). | `encodeBase70` | resolved | High: complete body and consumers. | 0204 | Core/SavedVariables | Preserve overflow recursion behavior. |
| `x` / chunk function | 682 | Converts numbers to fixed-width base-70 text; score/network/save authentication consumes it, and final `x(1378301, 4)` proves stat key `data` (683711, 818853, 887911, 1933, 8004). | `encodeBase70` | resolved | High: complete body, consumers, and exact final constant derivation. | 0217 | Core/SavedVariables | Preserve overflow recursion behavior. |
| `t`,`n`,`l` / `x` parameters | 682 | Numeric value is transformed/divided; width limits/pads; boolean enables centered signed offset. | `value`, `width`, `signed` | resolved | High. | 0202 | Core/SavedVariables | None. |
| `o`,`e`,`i` / `x` locals | 683, 684, 685 | Base-70 digit, accumulated encoded string, and division counter (689710). | `digit`, `encoded`, `digitIndex` | resolved | High: complete body. | 0202 | Core/SavedVariables | Counter permits `i < n`, an apparent width+1 edge to preserve. |
| `H` / first chunk function | 713 | Produces five decimal checksum digits from alternating byte sums (714733); shadowed at 761 but captured by `P`/`fe`. | `checksumDigits` | resolved | High: complete body and consumers. | 0202 | Core/SavedVariables | None. |
@@ -266,7 +266,7 @@ Complete helper bodies are resolved when their transformation and side effects a
| `i`,`l`,`e`,`o`,`n` / `jt` parameters | 1257 | Trig-table owner, texture, angle index, center X, and center Y (12581263). | `trig`, `texture`, `angle`, `centerX`, `centerY` | resolved | High: direct lookup/geometry. | 0303 | UI/Animations | None. |
| `t` / `jt` local | 1261 | Sine lookup for normalized angle; used in texture corners (1263). | `sin` | resolved | High. | 0303 | UI/Animations | None. |
| `e` / `jt` local | 1262 | Shadows angle after initializer; cosine lookup used in corners (1263). | `cos` | resolved | High. | 0303 | UI/Animations | None. |
| `T` / chunk function | 1266 | Shadows combo-score table for later declarations; applies pause/resume UI across grid, animator, and timer (12671361). Earlier `M` retains the table binding. | `setPaused` | resolved | High: complete body and lexical capture. | 0303 | Engine/Grid, UI/Animations, UI/HUD | Method/callback attachment pending. |
| `T` / chunk function | 1266 | Shadows combo-score table for later declarations; applies pause/resume UI across grid, animator, timer, and final splash saved-state restoration (12671361, 83498351). Earlier `M` retains the table binding. | `setPaused` | resolved | High: complete body and call sites. | 0317 | Engine/Grid, UI/Animations, UI/HUD | None. |
| `r` / `T` parameter | 1266 | Boolean-like pause request; controls action, alpha/visibility, and timer (12681359). | `paused` | resolved | High. | 0303 | Engine/Grid | None. |
| `i` / `T` duplicate declarations 12 | 1267 | Both nil bindings are shadowed by initialized `i` at 1274 before read. | — | dead | High. | 0303 | Unassigned | Minifier artifact. |
| `l` / `T` local | 1267 | Dynamic method name `Hide` or `Show`, used on gems/animator (12681304). | `visibilityMethod` | resolved | High. | 0303 | UI/GemPool, UI/Animations | None. |
@@ -418,7 +418,7 @@ Completed event callbacks and helpers are resolved by full local data flow. Lega
| `t` / `de` gem local | 2049 | Shadows column after indexing and receives rendered gem. | `gem` | resolved | High. | 0505 | UI/GemPool | None. |
| `R` / chunk renderer | 2059 | Shadows type alias; renders normal/hyper/empty gems and is used by restore/spawn/gravity/animator paths through line 4872, then is shadowed by timed-menu factory at 6019. Earlier closures retain it. | `renderGem` | resolved | High. | 0513 | UI/GemPool, UI/Animator | Earlier reset closure retains old type alias. |
| `t` / renderer parameter | 2059 | Gem/content receiver. | `gem` | resolved | High. | 0505 | UI/GemPool | None. |
| `j` / chunk game function | 2077 | Shadows leaderboard merger; initializes/restores game (20782245). | `startGame` | resolved | High. | 0505 | Engine/Grid | Attachment pending. |
| `j` / chunk game function | 2077 | Shadows leaderboard merger; initializes/restores games and is the final New Game/splash launch target (20782245, 8246, 8344, 8348). | `startGame` | resolved | High: complete body and final call sites. | 0517 | Engine/Grid, UI/HUD | None. |
| `l`,`s`,`r` / game parameters | 2077 | Mode, duration, resume flag. | `mode`,`duration`,`resume` | resolved | High. | 0505 | Engine/Grid | None. |
| `d`,`i`,`t` / game locals | 20782079 | Player name (after dead duplicate), object temporary, game-state alias. | `playerName`,`object`,`gameState` | resolved | High. | 0505 | Engine/Grid | None. |
| `t`,`e` / game loops | 2099, 21292130, 21842192, 22022203 | Animation/grid indices. | `index/row/column` | resolved | High. | 0505 | Engine/Grid, UI/Animations | None. |
@@ -434,7 +434,7 @@ Completed event callbacks and helpers are resolved by full local data flow. Lega
| `e` / `TotalTime` local | 2350 | Accumulates duration text. | `text` | resolved | High. | 0505 | UI/HUD | None. |
| `Se` / chunk function | 2384 | Clears current/next selection and selector UI; gravity transfer uses it at 4070 before animator update shadows it at 4235. | `clearSelection` | resolved | High. | 0509 | Engine/Grid | None. |
| `t`,`e` / `Se` bindings | 23842385 | Next flag and selected gem. | `next`,`gem` | resolved | High. | 0505 | Engine/Grid | None. |
| `Me` / chunk function | 2403 | Finalizes game and starts board wipe (24042456). | `endGame` | resolved | High. | 0505 | Engine/Scoring | Summary follows later. |
| `Me` / chunk function | 2403 | Finalizes game and starts board wipe; flight completion also calls it before cleanup (24042456, 7920). | `endGame` | resolved | High. | 0516 | Engine/Scoring, UI/Flight | None. |
| `o`,`t` / `Me` locals | 24042405 | Animator and status text. | `animator`,`statusText` | resolved | High. | 0505 | UI/HUD | None. |
| `e` / `Me` duplicate/loop bindings | 24232429 | Dead duplicate locals; live loops clear saved state. | `column/index` | resolved | High. | 0505 | Core/SavedVariables | None. |
| `At` / chunk function | 2458 | Creates positioned layered BackdropTemplate frame (24592482). | `createImageFrame` | resolved | High. | 0505 | UI/GemPool | First parameter unused. |
@@ -455,7 +455,7 @@ Complete helpers are resolved from full bodies. Same-spelling functions are sepa
| Legacy identifier / scope | Decl. | Evidence | Proposed name | Status | Confidence | Firstlast | Target | Question |
| --- | ---: | --- | --- | --- | --- | --- | --- | --- |
| `tt` / chunk | 2484 | Completes layered gem frame at 2506. | `createGemFrame` | resolved | High. | 0506 | UI/GemPool | None. |
| `tt` / chunk | 2484 | Completes layered gem-frame construction; final bootstrap calls it 64 times and then nils the factory (24842506, 83738388). | `createGemFrame` | resolved | High. | 0517 | UI/GemPool | None. |
| `It` / chunk; `t`,`e` params | 2508 | Configures `e` as hyper gem; `t` unused. | `configureHyperGem`; —,`gem` | resolved | High. | 0606 | UI/GemPool | None. |
| `Ht` / chunk; `t`,`o`,`i`,`n`,`e` bindings | 25192520 | Pooled big-star factory: animator,x,y,parent,object. | `createBigStar` | resolved | High. | 0606 | UI/Animations | None. |
| `Ot` / chunk; `n`,`i`,`a`,`o`,`t` bindings | 25452546 | Pooled explosion factory: animator,x,y,source,object. | `createExplosion` | resolved | High. | 0606 | UI/Animations | None. |
@@ -470,7 +470,7 @@ Complete helpers are resolved from full bodies. Same-spelling functions are sepa
| `h`,`o`,`t` / `Qe` locals | 2646 | Unused `h`, shard object, sign/speed temporary. | —,`shard`,`sign` | working | High except unused. | 0606 | UI/Animations | Split dead `h`. |
| `Je` / shadow function | 2700 | Pooled floating-text factory (27012729). | `createFloatingText` | resolved | High. | 0606 | UI/Animations | None. |
| `d`,`i`,`n`,`o`,`a`,`l`,`t`,`r` / `Je` bindings | 27002702 | Animator,x,y,text,color,non-score,object,parent. | resolved by position | resolved | High. | 0606 | UI/Animations | None. |
| `Ye` / chunk; `t` param | 2749 | Defers or applies mouse-over gem. | `handleGemMouseEnter`; `gem` | resolved | High. | 0606 | UI/GemPool | None. |
| `Ye` / chunk; `t` param | 2749 | Defers or applies mouse-over gem; installed on every final gem frame at 8377. | `handleGemMouseEnter`; `gem` | resolved | High. | 0617 | UI/GemPool | None. |
| `Ue` / shadow function; `t` local | 27702771 | Advances current-game level/multiplier/threshold. | `advanceLevel`; `gameState` | resolved | High. | 0606 | Engine/Scoring | None. |
| `Ce` / shadow function; `t`,`n` bindings | 28002801 | Processes hyper chain using gem and animator. | `triggerHyperChain` | resolved | High. | 0606 | Engine/Matches | None. |
| `S`,`s`,`i`,`r`,`l`,`d`,`e` / `Ce` locals/loops | 28142821 | Source/target centers, coordinates, row/column, matching gem. | coordinate/search roles | resolved | High. | 0606 | Engine/Matches | None. |
@@ -487,8 +487,8 @@ Completed factories are resolved by pool/field contracts. The open match scanner
| Legacy identifier / scope | Decl. | Evidence | Proposed name | Status | Confidence | Firstlast | Target | Question |
| --- | ---: | --- | --- | --- | --- | --- | --- | --- |
| `ce` / shadow function; `e` param | 3041 | Mouse-leave handler clears deferred hover or ends eligible effects. Shadows earlier half-gem-width constant only for later declarations. | `handleGemMouseLeave`; `gem` | resolved | High. | 0707 | UI/GemPool | None. |
| `Z` / shadow function; `t` param | 3057 | Main click/swap controller. `he` retains the earlier `createHyperGem` binding. | `handleGemClick`; `gem` | resolved | High. | 0707 | Engine/Input | None. |
| `ce` / shadow function; `e` param | 3041 | Mouse-leave handler clears deferred hover or ends eligible effects; installed on every final gem frame at 8378. Shadows earlier half-gem-width constant only for later declarations. | `handleGemMouseLeave`; `gem` | resolved | High. | 0717 | UI/GemPool | None. |
| `Z` / shadow function; `t` param | 3057 | Main click/swap controller, installed on every final gem frame at 8379. `he` retains the earlier `createHyperGem` binding. | `handleGemClick`; `gem` | resolved | High. | 0717 | Engine/Input | None. |
| `r` / `Z` adjacency scope | 3082 | False until clicked gem is one orthogonal neighbor of current selection. | `isAdjacent` | resolved | High. | 0707 | Engine/Input | None. |
| `a` / `Z` swap scope | 3083 | Holds hyper activation/target state used with match result. | `hyperTriggered` | resolved | Medium-high. | 0707 | Engine/Input, Engine/Matches | Preserve exact truthy values. |
| `l` / `Z` swap scope | 3084 | Animator used for hints and moving-gem scheduling. | `animator` | resolved | High. | 0707 | UI/Animations | None. |
@@ -502,7 +502,7 @@ Completed factories are resolved by pool/field contracts. The open match scanner
| `l` / `Z` result scope | 3174 | Boolean indicating both swapping gems are hyper gems. | `bothHyper` | resolved | High. | 0707 | Engine/Matches | None. |
| `a` / `Z` result scope | 3182 | Receives `he` return and participates in valid-move decision. | `matchFound` | resolved | High. | 0707 | Engine/Matches | None. |
| `t`,`e` / `Z` invalid-result scope | 3208 | Snapshot `o.fxType` and `o.fxFrame`, then are never read. | — | dead | High. | 0707 | Engine/Input | Remove after behavioral capture. |
| `ee` / shadow function; `t` param | 3234 | Drag-release handler maps cursor displacement to a neighboring gem and calls new `Z`. `he` retains earlier `createPowerGem`. | `handleGemDragRelease`; `gem` | resolved | High. | 0707 | Engine/Input | None. |
| `ee` / shadow function; `t` param | 3234 | Drag-release handler maps cursor displacement to a neighboring gem, calls new `Z`, and is installed as every gem's drag-start callback at 8380. `he` retains earlier `createPowerGem`. | `handleGemDragRelease`; `gem` | resolved | High. | 0717 | Engine/Input | Preserve legacy callback choice. |
| `e`,`l` / `ee` locals | 3239 | Cursor coordinates from `GetCursorPosition`, later reused for target column/row. | `cursorXOrColumn`,`cursorYOrRow` | resolved | High. | 0707 | Engine/Input | Verify Retail coordinate scaling. |
| `r`,`i` / `ee` locals | 32403241 | Horizontal and vertical displacement from pressed gem, normalized on the selected axis. | `deltaX`,`deltaY` | resolved | High. | 0707 | Engine/Input | None. |
| `d` / `ee` local | 3242 | Neighbor chosen from dominant drag direction. | `targetGem` | resolved | High. | 0707 | Engine/Input | None. |
@@ -545,7 +545,7 @@ Bindings are resolved only where complete control/data flow closes within this b
| `a` / repair-helper local | 3567 | Byte-sum checksum seed for PopCap fallback name. | `fallbackSeed` | resolved | High. | 0808 | Persistence/Migration | None. |
| `t` / repair outer and shift loops | 3568, 3577 | Descending record index and nested upward shift index in distinct scopes. | `recordIndex`,`shiftIndex` | resolved | High. | 0808 | Persistence/Migration | None. |
| `e` / personal-best local | 3601 | Verified payload reused for classic and timed profile scores. | `decodedPayload` | resolved | High. | 0808 | Persistence/Migration | None. |
| `Ze` / shadow function; `t` param | 3619 | Command-text handler parses reset token or toggles window; shadows earlier dimension constant. | `handleCommand`; `message` | resolved | High. | 0808 | Commands | Registration site pending. |
| `Ze` / shadow function; `t` param | 3619 | Command-text handler parses reset token or toggles window; registered for `/bejeweled` and `/bej` at 80298031 after shadowing the earlier dimension constant. | `handleCommand`; `message` | resolved | High: body and registration are complete. | 0817 | Commands | None. |
| `n` / `Ze` local | 3620 | Copy/remainder of command text; transformations have no observable consumer. | — | dead | High. | 0808 | Commands | None. |
| `t` / `Ze` command local | 3621 | First token lowercased and compared with `reset`. | `command` | resolved | High. | 0808 | Commands | None. |
| `o` / `Ze` local | 3622 | Index of first space used to split command. | `separatorIndex` | resolved | High. | 0808 | Commands | None. |
@@ -556,7 +556,7 @@ Bindings are resolved only where complete control/data flow closes within this b
| `t` / `CreateSlider` result local | 3759 | Slider frame; shadows parent parameter only after RHS initializer. | `slider` | resolved | High. | 0808 | UI/Settings | Lua 5.1 initializer scope is required. |
| `d`,`r`,`a`,`o`,`l`,`t`,`n`,`i` / `CreateCheckbox` params | 3798 | X,Y,label,setting key,checked value,parent,callback,radio flag. | positional roles as observed | resolved | High. | 0808 | UI/Settings | None. |
| `t` / `CreateCheckbox` result local | 3799 | Check-button frame; shadows parent parameter only after RHS initializer. | `checkbox` | resolved | High. | 0808 | UI/Settings | Lua 5.1 initializer scope is required. |
| `fe` / shadow function; `t`,`o` params | 3829 | Throttled gameplay timer updater for timer frame and elapsed delta; shadows signed-score verifier. | `updateGameTimer`; `timer`,`delta` | resolved | High. | 0808 | Engine/Timer | None. |
| `fe` / shadow function; `t`,`o` params | 3829 | Throttled gameplay timer updater for timer frame and elapsed delta; final level-bar timer installs it as `OnUpdate` at 8211 after it shadows the signed-score verifier. | `updateGameTimer`; `timer`,`delta` | resolved | High: body and attachment are complete. | 0817 | Engine/Timer, UI/HUD | None. |
| `e` / `fe` flight-sync local | 3854 | Flight timer used to reconcile elapsed/remaining values. | `flightTimer` | resolved | High. | 0808 | Engine/Timer | None. |
| `Le` / shadow function; `i` param | 3874 | Spawns/refills empty cells, rerolls for a legal board, restores special gems, advances levels, and checks achievement; attached as animator `HandleJewelDropping` at 4965. | `handleJewelDropping` | resolved | High. | 0810 | Engine/BoardSpawn, UI/Animator | None. |
| `s` / first two `Le` declarations | 3878 | First and second duplicate bindings are hidden by later same-statement `s` declarations. | — | shadowed | High. | 0808 | Engine/BoardSpawn | None. |
@@ -625,10 +625,10 @@ Complete spawn, gravity, countdown, and state-transition bodies support resolved
| `e` / big-star-glow local | 4678 | Gem receiving weighted glow around star parent. | `glowGem` | resolved | High. | 1010 | UI/Animator | None. |
| `i`,`n` / big-star-glow loops | 4679, 4681 | Relative row/column offsets -2..2. | `rowOffset`,`columnOffset` | resolved | High. | 1010 | UI/Animator | None. |
| `e` / swap completion local | 4810 | Boolean set when either axis reaches its target, driving reversal/finalization. | `axisComplete` | resolved | High. | 1010 | Engine/Swaps | Preserve single-axis trigger behavior. |
| `A` / shadow function | 4922 | Constructs/wires invisible animator frame and all effect queues/helpers; shadows clear-work effect enum. | `createAnimator` | resolved | High. | 1010 | UI/Animator | None. |
| `A` / shadow function | 4922 | Constructs/wires invisible animator frame and all effect queues/helpers; final bootstrap stores its return and releases the constructor (80058007, 8389) after it shadows the clear-work effect enum. | `createAnimator` | resolved | High. | 1017 | UI/Animator | None. |
| `e` / `A` local | 4923 | Animator frame configured and returned. | `animator` | resolved | High. | 1010 | UI/Animator | `movingGems`/`movingJewels` mismatch. |
| `t` / `A` rotation loop | 4938 | Degree 0360 used to precompute sine/cosine tables. | `degrees` | resolved | High. | 1010 | UI/Animator | None. |
| `V` / shadow function | 4971 | Constructs and installs the network frame, send queue, one-second throttle, and receive dispatcher; closes at 5047 after shadowing idle animator state captured by earlier closures. | `createNetwork` | resolved | High. | 1011 | Network/Transport | Factory installs globally rather than returning. |
| `V` / shadow function | 4971 | Constructs and installs the network frame, send queue, one-second throttle, and receive dispatcher; invoked by final bootstrap at 8015 after shadowing idle animator state captured by earlier closures. | `createNetwork` | resolved | High. | 1017 | Network/Transport | Factory installs globally rather than returning. |
| `o` / `V` local | 4974 | Network frame with queue, send method, throttling, receive callback, and final `Bejeweled.network` installation. | `network` | resolved | High. | 1011 | Network/Transport | None. |
| `l`,`i`,`o`,`n`,`t` / network `Send` params | 4981 | Unused self, message type, two required payload fields, optional final field. | `self`,`messageType`,`field1`,`field2`,`field3` | resolved | High. | 1010 | Network/Transport | Determine semantic fields from callers. |
| `t`,`o` / network `OnUpdate` params | 4988 | Network frame and elapsed delta; after a one-second accumulation the callback drains eligible queue entries until 20 sends succeed. | `network`,`delta` | resolved | High. | 1011 | Network/Transport | Preserve successful-send rather than dequeue throttling. |
@@ -652,14 +652,14 @@ Complete spawn, gravity, countdown, and state-transition bodies support resolved
| `i` / friend pre-loop local | 5029 | Hidden by the numeric-for variable at 5030 without a read. | — | dead | High. | 1111 | Network/Transport | None. |
| `o` / friend-check local | 5029 | Holds each `C_FriendList.GetFriendInfo` result for exact comparison with sender. | `friendName` | resolved | High. | 1111 | Network/Transport | Verify modern return contract before runtime. |
| `i` / friend loop | 5030 | Iterates friend indices from 1 through `GetNumFriends()`. | `friendIndex` | resolved | High. | 1111 | Network/Transport | None. |
| `O` / shadow function | 5049 | Constructs and installs the sound frame, deferred flag player, click limiter, and mouse-away updater; shadows the hyper atlas captured by earlier closures. | `createSoundManager` | resolved | High. | 1111 | UI/Sound | Factory installs globally rather than returning. |
| `O` / shadow function | 5049 | Constructs and installs the sound frame, deferred flag player, click limiter, and mouse-away updater; invoked by final bootstrap at 8016 after shadowing the hyper atlas captured by earlier closures. | `createSoundManager` | resolved | High. | 1117 | UI/Sound | Factory installs globally rather than returning. |
| `n` / `O` local | 5050 | Sound frame configured with flags/timers/scripts and installed as `Bejeweled.sound`. | `soundManager` | resolved | High. | 1111 | UI/Sound | None. |
| `t`,`n`,`o` / sound `Play` params | 5060 | Sound manager, named sound flag, and combo index capped at six. | `soundManager`,`soundName`,`comboIndex` | resolved | High. | 1111 | UI/Sound | Non-combo callers may omit index. |
| `t`,`n` / sound `OnUpdate` params | 5079 | Sound manager and delta used for hover/click timing and flag playback. | `soundManager`,`delta` | resolved | High. | 1111 | UI/Sound | Disabled sounds freeze both timers. |
| `e` / sound-root local | 5112 | Starts at `ut`, optionally appends `q_`, and prefixes every bundled sound filename in the pass. | `soundPath` | resolved | High. | 1111 | UI/Sound | None. |
| `n` / combo pre-loop local | 5173 | Immediately hidden by the numeric-for variable at 5174. | — | dead | High. | 1111 | UI/Sound | None. |
| `n` / combo loop | 5174 | Scans combo flags 16 and derives the selected filename. | `comboIndex` | resolved | High. | 1111 | UI/Sound | None. |
| `E` / shadow function | 5194 | Constructs and installs minimap icon visuals, toggle/tooltip callbacks, and attached/detached drag persistence; shadows the earlier nil/reset binding. | `createMinimapButton` | resolved | High. | 1111 | UI/Minimap | Factory installs globally rather than returning. |
| `E` / shadow function | 5194 | Constructs and installs minimap icon visuals, toggle/tooltip callbacks, and attached/detached drag persistence; invoked by final bootstrap at 8018 after shadowing the earlier nil/reset binding. | `createMinimapButton` | resolved | High. | 1117 | UI/Minimap | Factory installs globally rather than returning. |
| `t` / `E` local | 5195 | Minimap frame configured through all callbacks and installed as `Bejeweled.minimap`. | `minimapButton` | resolved | High. | 1111 | UI/Minimap | None. |
| `e`,`t` / minimap `OnMouseDown` params | 5220 | Minimap frame and mouse-button name; right press starts moving. | `minimapButton`,`mouseButton` | resolved | High. | 1111 | UI/Minimap | None. |
| `t`,`n` / minimap `OnMouseUp` params | 5226 | Minimap frame and mouse-button name; left release toggles the main window. | `minimapButton`,`mouseButton` | resolved | High. | 1111 | UI/Minimap | None. |
@@ -672,7 +672,7 @@ Complete spawn, gravity, countdown, and state-transition bodies support resolved
| `a`,`l` / minimap-drag locals | 52685269 | Minimap center X/Y derived from its left/bottom and half dimensions. | `minimapCenterX`,`minimapCenterY` | resolved | High. | 1111 | UI/Minimap | None. |
| `e`,`t` / minimap offset locals | 52705271 | UI-scaled cursor offsets from minimap center, then absolute cursor coordinates in the detached branch. | `x`,`y` | resolved | High. | 1111 | UI/Minimap | Split offset/absolute roles in rewrite. |
| `e` / attached-angle local | 5280 | Shadows X offset inside the attached branch and stores degrees derived by `atan2`. | `angleDegrees` | resolved | High. | 1111 | UI/Minimap | Preserve argument order/sign convention. |
| `g` / shadow function | 5290 | Constructs and returns the main window, backdrop, drag/show/hide/resize controls, and mouse-over overlay; closes at 5517 after shadowing the hyper-gem enum captured by animator code. | `createMainWindow` | resolved | High. | 1112 | UI/MainWindow | None. |
| `g` / shadow function | 5290 | Constructs and returns the main window, backdrop, drag/show/hide/resize controls, and mouse-over overlay; final bootstrap stores its return and releases the constructor (80068009, 8390) after shadowing the hyper-gem enum captured by animator code. | `createMainWindow` | resolved | High. | 1117 | UI/MainWindow | None. |
| `t` / `g` local | 5291 | Main window receiving all controls/children, stored overlay, and final return at 5516. | `window` | resolved | High. | 1112 | UI/MainWindow | None. |
| `a` / main-window local | 5302 | Captured frame level used to place the resize handle three levels above it. | `frameLevel` | resolved | High. | 1111 | UI/MainWindow | None. |
| `o` / backdrop local | 5303 | Descriptor from `C()` populated with window textures/dimensions and passed to `SetBackdrop`. | `backdropInfo` | resolved | High. | 1111 | UI/MainWindow | None. |
@@ -705,7 +705,7 @@ Factories `V`, `O`, and `E` close and install their frames in this batch, so the
| Legacy identifier / scope | Decl. | Evidence | Proposed name | Status | Confidence | Firstlast | Target | Question |
| --- | ---: | --- | --- | --- | --- | --- | --- | --- |
| `P` / shadow function | 5519 | Constructs and installs the pause/menu frame and its Resume, New Game, Feats, Options, and About controls; shadows authenticated-score encoder retained by earlier closures. | `createMenuWindow` | resolved | High. | 1212 | UI/Menu | Factory installs globally rather than returning. |
| `P` / shadow function | 5519 | Constructs and installs the pause/menu frame and its Resume, New Game, Feats, Options, and About controls; invoked and later released by final bootstrap (8010, 8391) after shadowing the authenticated-score encoder retained by earlier closures. | `createMenuWindow` | resolved | High. | 1217 | UI/Menu | Factory installs globally rather than returning. |
| `t` / `P` local | 5520 | Menu frame configured through show/hide behavior and installed as `Bejeweled.menuWindow`. | `menuWindow` | resolved | High. | 1212 | UI/Menu | None. |
| `o` / menu backdrop local | 5530 | Backdrop descriptor populated and passed to the menu frame. | `backdropInfo` | resolved | High. | 1212 | UI/Menu | None. |
| `o` / menu close-button local | 5540 | Inherited close button configured before the spelling is shadowed. | `closeButton` | resolved | High. | 1212 | UI/Menu | Template owns click behavior. |
@@ -715,7 +715,7 @@ Factories `V`, `O`, and `E` close and install their frames in this batch, so the
| `n` / menu button locals | 5577, 5588, 5600, 5617, 5634 | Successive Resume, New Game, Feats, Options, and About buttons. Each initializer uses the prior `n` as temporary parent before reparenting to the menu, then shadows it. | role-specific button names | resolved | High. | 1212 | UI/Menu | Preserve Lua 5.1 initializer scope. |
| `t` / Resume/New/Feats/Options callback params | 5582, 5594, 5606, 5623 | Four declaration-specific clicked-button parameters are never read. | — | dead | High. | 1212 | UI/Menu | None. |
| `t` / About callback param | 5640 | Clicked About button supplies its attached `tabClick` method before the About screen is shown. | `aboutButton` | resolved | High. | 1212 | UI/Menu | None. |
| `N` / shadow function | 5656 | Constructs and installs the tutorial/action popup; shadows shine-atlas binding captured by earlier effect closures. | `createPopup` | resolved | High. | 1212 | UI/Popup | Factory installs globally rather than returning. |
| `N` / shadow function | 5656 | Constructs and installs the tutorial/action popup; invoked by final bootstrap at 8017 after shadowing the shine-atlas binding captured by earlier effect closures. | `createPopup` | resolved | High. | 1217 | UI/Popup | Factory installs globally rather than returning. |
| `t` / `N` local | 5657 | Popup frame configured with message/caption/buttons/scripts and installed as `Bejeweled.popup`. | `popup` | resolved | High. | 1212 | UI/Popup | None. |
| `n` / popup backdrop local | 5665 | Backdrop descriptor populated and applied to the popup. | `backdropInfo` | resolved | High. | 1212 | UI/Popup | None. |
| `n` / popup top-right-button local | 5675 | Button created with only `BackdropTemplate` because Lua `and` returns its second string; configured but never retained or scripted before shadow. | `unwiredTopRightButton` | resolved | High. | 1212 | UI/Popup | Preserved defect candidate. |
@@ -727,7 +727,7 @@ Factories `V`, `O`, and `E` close and install their frames in this batch, so the
| `n` / popup-button locals | 5726, 5735, 5745 | Successive OK, Feats of Skill, and Options buttons stored as `button1``button3`; third is parented to the second. | `okButton`,`skillsButton`,`optionsButton` | resolved | High. | 1212 | UI/Popup | None. |
| `t` / popup OK callback param | 5731 | Clicked-button parameter is never read. | — | dead | High. | 1212 | UI/Popup | None. |
| `t` / popup navigation callbacks | 5740, 5750 | Clicked buttons are forwarded to the corresponding menu button's `OnClick`; those target callbacks do not consume them. | `button` | resolved | High. | 1212 | UI/Popup, UI/Menu | Preserve direct script invocation. |
| `W` / shadow function | 5757 | Constructs and installs the Classic/Timed game-type selector; shadows spawn-effect enum captured by earlier animator closures. | `createGameModeWindow` | resolved | High. | 1212 | UI/Menu | Factory installs globally rather than returning. |
| `W` / shadow function | 5757 | Constructs and installs the Classic/Timed game-type selector; invoked by final bootstrap at 8012 after shadowing the spawn-effect enum captured by earlier animator closures. | `createGameModeWindow` | resolved | High. | 1217 | UI/Menu | Factory installs globally rather than returning. |
| `t` / `W` local | 5758 | Game-type frame configured and installed as `Bejeweled.gameModeWindow`. | `gameModeWindow` | resolved | High. | 1212 | UI/Menu | None. |
| `n` / game-mode backdrop local | 5765 | Backdrop descriptor applied to game-type frame. | `backdropInfo` | resolved | High. | 1212 | UI/Menu | None. |
| `n` / game-mode close-button local | 5775 | Inherited close button configured before shadow. | `closeButton` | resolved | High. | 1212 | UI/Menu | None. |
@@ -735,7 +735,7 @@ Factories `V`, `O`, and `E` close and install their frames in this batch, so the
| `t` / game-mode `OnHide` param | 5789 | Selector frame whose transient `gameMode` flag distinguishes forward transition from back navigation. | `gameModeWindow` | resolved | High. | 1212 | UI/Menu | Field name is not gameplay-mode identity. |
| `n` / game-mode button locals | 5797, 5808 | Classic and Timed buttons; second initializer temporarily parents to the first before reparenting. | `classicButton`,`timedButton` | resolved | High. | 1212 | UI/Menu | Preserve Lua 5.1 initializer scope. |
| `t` / game-mode button callbacks | 5802, 5814 | Distinct clicked-button parameters are never read. | — | dead | High. | 1212 | UI/Menu | None. |
| `F` / shadow function | 5823 | Constructs and installs classic Continue/New Game selector; shadows gem atlas captured by earlier rendering/animator closures. | `createClassicModeWindow` | resolved | High. | 1212 | UI/Menu | Factory installs globally rather than returning. |
| `F` / shadow function | 5823 | Constructs and installs classic Continue/New Game selector; invoked and released by final bootstrap (8013, 8396) after shadowing the gem atlas captured by earlier rendering/animator closures. | `createClassicModeWindow` | resolved | High. | 1217 | UI/Menu | Factory installs globally rather than returning. |
| `t` / `F` local | 5824 | Classic selector configured and installed as `Bejeweled.classicModeWindow`. | `classicModeWindow` | resolved | High. | 1212 | UI/Menu | None. |
| `n` / classic backdrop local | 5831 | Backdrop descriptor applied to classic selector. | `backdropInfo` | resolved | High. | 1212 | UI/Menu | None. |
| `n` / classic close-button local | 5841 | Inherited close button configured before shadow. | `closeButton` | resolved | High. | 1212 | UI/Menu | None. |
@@ -744,7 +744,7 @@ Factories `V`, `O`, and `E` close and install their frames in this batch, so the
| `t` / classic `OnHide` param | 5861 | Selector frame whose transient `gameMode` flag distinguishes game start from back navigation. | `classicModeWindow` | resolved | High. | 1212 | UI/Menu | None. |
| `n` / classic button locals | 5869, 5880 | Continue-action and new-game-action buttons; global frame names are opposite their text/actions. | `continueButton`,`newGameButton` | resolved | High. | 1212 | UI/Menu | Preserve frame-name compatibility. |
| `t` / classic button callbacks | 5874, 5886 | Distinct clicked-button parameters are never read. | — | dead | High. | 1212 | UI/Menu | None. |
| `D` / shadow function | 5895 | Constructs and installs Flight Path option frame, Start action, and `Ne`-driven timer; closes at 6017 after shadowing `tonumber` retained by earlier closures. | `createFlightOptionWindow` | resolved | High. | 1213 | UI/Flight | None. |
| `D` / shadow function | 5895 | Constructs and installs Flight Path option frame, Start action, and `Ne`-driven timer; invoked by final bootstrap at 8014 after shadowing `tonumber` retained by earlier closures. | `createFlightOptionWindow` | resolved | High. | 1217 | UI/Flight | None. |
| `n` / `D` local | 5896 | Top-level flight-option frame receives button/timer and is installed as `Bejeweled.flightOptionWindow`. | `flightOptionWindow` | resolved | High. | 1213 | UI/Flight | None. |
| `t` / flight backdrop local | 5905 | Backdrop descriptor populated and applied to flight-option frame. | `backdropInfo` | resolved | High. | 1212 | UI/Flight | None. |
| `t` / flight close-button local | 5915 | Inherited close button configured before shadow. | `closeButton` | resolved | High. | 1212 | UI/Flight | None. |
@@ -762,7 +762,7 @@ Factories `g`, `P`, `N`, `W`, and `F` close in this batch, so their constructed-
| Legacy identifier / scope | Decl. | Evidence | Proposed name | Status | Confidence | Firstlast | Target | Question |
| --- | ---: | --- | --- | --- | --- | --- | --- | --- |
| `t` / flight-timer local | 6008 | Hidden one-pixel frame driven by `Ne`, stored as `n.timer`. | `flightTimer` | resolved | High. | 1313 | UI/Flight | None. |
| `R` / shadow function | 6019 | Constructs and installs timed-mode menu; shadows gem renderer retained by earlier closures. | `createTimedModeWindow` | resolved | High. | 1313 | UI/Flight, UI/Menu | Factory installs globally rather than returning. |
| `R` / shadow function | 6019 | Constructs and installs timed-mode menu; invoked by final bootstrap at 8011 after shadowing the gem renderer retained by earlier closures. | `createTimedModeWindow` | resolved | High. | 1317 | UI/Flight, UI/Menu | Factory installs globally rather than returning. |
| `o` / `R` local | 6020 | Timed-mode menu configured and installed as `Bejeweled.timedWindow`. | `timedWindow` | resolved | High. | 1313 | UI/Flight, UI/Menu | None. |
| `t` / timed backdrop local | 6027 | Backdrop descriptor populated and applied to timed menu. | `backdropInfo` | resolved | High. | 1313 | UI/Menu | None. |
| `t` / timed close-button local | 6036 | Inherited close button configured before shadow. | `closeButton` | resolved | High. | 1313 | UI/Menu | None. |
@@ -775,9 +775,9 @@ Factories `g`, `P`, `N`, `W`, and `F` close in this batch, so their constructed-
| `n` / flight-checkbox local | 6107 | Checkbox returned by `CreateCheckbox`, styled and stored as `o.flightCheckbox`. | `flightCheckbox` | resolved | High. | 1313 | UI/Flight | Empty click callback is intentional legacy behavior. |
| `t` / timed-Go local | 6133 | Go button that delegates to flight Start or starts fixed-duration timed play. | `goButton` | resolved | High. | 1313 | UI/Flight | None. |
| `t` / timed-Go callback param | 6137 | Clicked-button parameter is never read. | — | dead | High. | 1313 | UI/Flight | None. |
| `M` / shadow function | 6149 | Registers `UNIT_FLAGS` on the main window and shadows score presenter retained by earlier closures. | `registerUnitFlagsEvent` | resolved | High. | 1313 | Core/Events | Callback/call site remains to locate. |
| `M` / shadow function | 6149 | Registers `UNIT_FLAGS` on the main window and is secure-hooked after `TakeTaxiNode` at 8003; shadows the score presenter retained by earlier closures. | `registerUnitFlagsEvent` | resolved | High: final hook site confirms post-taxi registration. | 1317 | Core/Events | None. |
| `t` / `M` param | 6149 | Function parameter is never read. | — | dead | High. | 1313 | Core/Events | None. |
| `y` / shadow function; `t` param | 6153 | Taxi-node handler derives node ID from passed UI object, clears path state, reads taxi metadata, and contains disabled estimation logic; shadows gem-animation enum captured earlier. | `handleTaxiNode`; `taxiNodeButton` | resolved | High. | 1313 | UI/Flight | Callback attachment remains to locate. |
| `y` / shadow function; `t` param | 6153 | Taxi-node handler derives node ID from passed UI object, clears path state, reads taxi metadata, and contains disabled estimation logic; secure-hooked to `TaxiNodeOnButtonEnter` at 8004 after shadowing the gem-animation enum captured earlier. | `handleTaxiNode`; `taxiNodeButton` | resolved | High: body and final hook site. | 1317 | UI/Flight | None. |
| `i`,`h` / taxi locals | 61546155 | Taxi node ID and route count from callback object/APIs. | `nodeId`,`routeCount` | resolved | High. | 1313 | UI/Flight | APIs require replacement/verification. |
| `C`,`w`,`p`,`f` / taxi coordinate locals | 6156 | Disabled route branch assigns source X/Y and destination X/Y in route-map pixels. | `sourceX`,`sourceY`,`destinationX`,`destinationY` | resolved | High for intended arithmetic. | 1313 | UI/Flight | Branch is forced unreachable. |
| `g`,`c` / taxi map-size locals | 61576158 | Live reads of `TaxiRouteMap` width/height scale normalized route coordinates in disabled branch. | `mapWidth`,`mapHeight` | resolved | High. | 1313 | UI/Flight | Reads occur before forced-false guard. |
@@ -789,7 +789,7 @@ Factories `g`, `P`, `N`, `W`, and `F` close in this batch, so their constructed-
| `m` / taxi-node-type local | 6177 | Live `TaxiNodeGetType` result selects forced-disabled reachable or empty current branch. | `nodeType` | resolved | High. | 1313 | UI/Flight | API requires verification. |
| `l` / disabled route loop | 6185 | Route index 1 through global `NUM_TAXI_ROUTES`; loop is unreachable. | `routeIndex` | resolved | High. | 1313 | UI/Flight | None. |
| `e` / disabled fallback local | 6214 | Candidate saved flight-time table checked for source/destination keys. | `savedFlightTimes` | resolved | High. | 1313 | UI/Flight | Branch is forced unreachable. |
| `B` / shadow function | 6252 | Constructs summary metrics, publishing/high-score/brag actions, dropdown/channel filtering, and nested brag screen; closes at 6519 after shadowing `table.remove` retained by earlier closures. | `createSummaryScreen` | resolved | High. | 1314 | UI/Summary | None. |
| `B` / shadow function | 6252 | Constructs summary metrics, publishing/high-score/brag actions, dropdown/channel filtering, and nested brag screen; invoked and released by final bootstrap (8050, 8392) after shadowing `table.remove` retained by earlier closures. | `createSummaryScreen` | resolved | High. | 1317 | UI/Summary | None. |
| `n` / summary-window local | 6253 | Main window used only to derive summary/inner-panel frame levels before line-6281 shadow. | `window` | resolved | High. | 1313 | UI/Summary | None. |
| `o` / summary-frame local | 6254 | Summary screen receives metrics/actions/brag child and is installed globally; shadowed by dropdown local at 6485 after all needed closures capture it. | `summaryScreen` | resolved | High. | 1314 | UI/Summary | None. |
| `a` / summary backdrop local | 6257 | Backdrop descriptor applied to summary, inner panel, and brag screen. | `backdropInfo` | resolved | High. | 1313 | UI/Summary | None. |
@@ -842,7 +842,7 @@ Factories `D` and `R`, helper `M`, and taxi handler `y` close in this batch, sup
| --- | ---: | --- | --- | --- | --- | --- | --- | --- | --- |
| `t` / brag-Back callback param | 6512 | Back button hides its parent brag screen. | `backButton` | resolved | High. | 1414 | UI/Summary | None. |
| `e` / brag-Back local | 6514 | Summary alias used to re-enable three action buttons. | `summaryScreen` | resolved | High. | 1414 | UI/Summary | None. |
| `u` / shadow function | 6521 | Constructs/installs four-tab Feats screen, skill award engine/bar/list, statistics, leaderboards, and achievements; closes at 7411 after shadowing `table.insert` retained by earlier closures. | `createFeatsOfSkillScreen` | resolved | High. | 1415 | UI/Skills | None. |
| `u` / shadow function | 6521 | Constructs/installs four-tab Feats screen, skill award engine/bar/list, statistics, leaderboards, and achievements; invoked and released by final bootstrap (8051, 8393) after shadowing `table.insert` retained by earlier closures. | `createFeatsOfSkillScreen` | resolved | High. | 1417 | UI/Skills | None. |
| `o` / `u` window local | 6522 | Main window used to derive Feats frame levels. | `window` | resolved | High. | 1414 | UI/Skills | None. |
| first `t` / `u` locals | 6523 | Nil declaration immediately shadowed by line-6524 `t`. | — | shadowed | High. | 1414 | UI/Skills | Minifier artifact. |
| second `t` / `u` local | 6524 | Game-board frame used as parent for Feats screen before line-6555 shadow. | `gameBoard` | resolved | High. | 1414 | UI/Skills | None. |
@@ -939,7 +939,7 @@ Summary factory `B` closes, so its open action/frame bindings are resolved. `Che
| `h`,`s`,`S` / achievement counters | 73357337 | Unlocked, total-record, and completed counts passed to title format. | `unlockedCount`,`totalCount`,`completedCount` | resolved | High. | 1515 | UI/Skills | None. |
| `e`,`n` / achievement reset loops | 73387339 | Reverse type and entry indices clearing all preallocated plates. | `skillType`,`achievementIndex` | resolved | High. | 1515 | UI/Skills | None. |
| `e`,`o` / achievement population loops | 73497350 | Forward type and entry indices selecting unlocked/completed plates. | `skillType`,`achievementIndex` | resolved | High. | 1515 | UI/Skills | None. |
| `m` / shadow function | 7413 | Constructs/installs About screen and Tutorial, PopCap story/version, and Credits tabs; closes at 7631 after shadowing random alias retained by earlier closures. | `createAboutScreen` | resolved | High. | 1516 | UI/About | None. |
| `m` / shadow function | 7413 | Constructs/installs About screen and Tutorial, PopCap story/version, and Credits tabs; invoked and released by final bootstrap (8052, 8394) after shadowing the random alias retained by earlier closures. | `createAboutScreen` | resolved | High. | 1517 | UI/About | None. |
| `n` / About-window local | 7414 | Main window supplies frame levels through tab creation, then is shadowed by line-7500 child frame. | `window` | resolved | High. | 1515 | UI/About | None. |
| first `t` / About locals | 7415 | Nil declaration immediately shadowed at line 7416. | — | shadowed | High. | 1515 | UI/About | Minifier artifact. |
| second `t` / About local | 7416 | Game-board frame used as About parent before line-7447 shadow. | `gameBoard` | resolved | High. | 1515 | UI/About | None. |
@@ -979,7 +979,7 @@ Feats factory `u` and both refresh callbacks close, resolving stats, leaderboard
| `e`,`t` / key-up callback params | 7798 | Main window and released key; modifier-key releases trigger modifier recomputation. | `window`,`key` | resolved | High. | 1616 | UI/Options | None. |
| `t` / key-up separator local | 7800 | Empty/`-` separator used while rebuilding ALT-CTRL-SHIFT string; shadows consumed key parameter. | `separator` | resolved | High. | 1616 | UI/Options | None. |
| `n` / key-down separator local | 7846 | Empty/`-` separator used while composing modifier string and final keybind. | `separator` | resolved | High. | 1616 | UI/Options | None. |
| `S` / shadow function | 7874 | Central window event dispatcher handles taxi/network/startup/death/ready/combat events and shadows inactive-hint enum retained by earlier closures. | `handleWindowEvent` | resolved | High. | 1616 | Core/Events | Attachment appears in final batch or earlier factory. |
| `S` / shadow function | 7874 | Central window event dispatcher handles taxi/network/startup/death/ready/combat events; final bootstrap installs it on the main window at 8028 before a game-surface local shadows its spelling. | `handleWindowEvent` | resolved | High: body and attachment are complete. | 1617 | Core/Events | None. |
| `i`,`t`,`l` / event-dispatch params | 7874 | Window/frame, event name, and first event argument/unit select and service all branches. | `window`,`event`,`arg1` | resolved | High. | 1616 | Core/Events | None. |
| `o` / event-dispatch fourth param | 7874 | Parameter is shadowed by local `o` at 7875 without a read. | — | shadowed | High. | 1616 | Core/Events | None. |
| `o` / event flight-window local | 7875 | Flight-option window supplies timer/learning state across flight-end and login branches before narrower shadowing. | `flightOptionWindow` | resolved | High. | 1616 | Core/Events, UI/Flight | None. |
@@ -993,8 +993,55 @@ Feats factory `u` and both refresh callbacks close, resolving stats, leaderboard
| `o` / login friend pre-loop local | 7956 | Hidden by numeric-for variable at 7957 without a read. | — | dead | High. | 1616 | Network/Publishing | None. |
| `t` / login friend local | 7956 | Friend name used as LogSync/HSPub whisper target when implicit `online` is truthy. | `friendName` | resolved | High. | 1616 | Network/Publishing | Verify current friend API tuple. |
| `o` / login friend loop | 7957 | Iterates friend indices and shadows pre-loop binding. | `friendIndex` | resolved | High. | 1616 | Network/Publishing | None. |
| `k` / shadow function | 7995 | Begins compatibility/limit initialization by forcing `skillLimit`; shadows flight-learning mode retained by earlier closures and remains open after line 8000. | `initializeSkillLimitCompatibility` | working | Medium until completed. | 1616 | Core/Compatibility | Continue in batch 17. |
| `k` / shadow function | 7995 | One-shot addon bootstrap forces the post-map-API skill limit, hooks taxi handlers, constructs services/UI/HUD/grid, releases selected constructors including itself, closes at 8398, and is invoked at 8400. It shadows flight-learning mode retained by earlier closures. | `initializeAddon` | resolved | High: complete body, constructor order, cleanup, and call site. | 1617 | Core/Init | None. |
## Batch 16 resolution policy
About factory `m`, Options initializer, and event dispatcher `S` close, resolving their UI, binding, event, and publishing scopes. Login payload duplication and dead checksum/numeric intermediates are recorded as wire/data-flow evidence. Open compatibility function `k` remains working until the final batch determines its complete fallback behavior.
## Batch 17 declarations and scopes
| Legacy identifier / scope | Decl. | Evidence | Proposed name | Status | Confidence | Firstlast | Target | Question |
| --- | ---: | --- | --- | --- | --- | --- | --- | --- | --- |
| `x` / bootstrap local | 8005 | Animator returned by factory `A`, installed as `Bejeweled.animator`, used to create the hint, then constructor `A` is released. Shadows base-70 encoder after the `data` key assignment. | `animator` | resolved | High. | 1717 | UI/Animator, Core/Init | None. |
| `r` / bootstrap local | 8006 | Main window returned by factory `g`; owns keyboard/event scripts, game/status children, splash, and relative frame levels. Shadows direction-pattern table for the bootstrap body. | `window` | resolved | High. | 1717 | UI/MainWindow, Core/Init | None. |
| first `t` / bootstrap scratch | 8032 | Nil binding hidden by line-8033 `t` without a read. | — | shadowed | High. | 1717 | Core/Init | Minifier artifact. |
| `h` / bootstrap scratch | 8032 | Survives repeated `t` shadowing, receives each created gem frame, and supplies handler/frame/grid fields in the final 8×8 loop. | `gem` | resolved | High. | 1717 | UI/GemPool | None. |
| `t` / bootstrap dead bindings | 8033, 8034 | Two zero-valued same-scope locals are successively shadowed without reads. | — | shadowed | High. | 1717 | Core/Init | Minifier artifact. |
| two `t` bindings / duplicate declaration | 8035 | First is hidden by the second in the same declaration; second is hidden by line-8036 before a read. | — | shadowed | High. | 1717 | Core/Init | Minifier artifact. |
| `t` / board-anchor local | 8036 | Frame anchors the exported board and is consumed as `gameBoard` parent before line-8043 shadows it. | `gameBoardAnchor` | resolved | High. | 1717 | UI/HUD | None. |
| `gameBoard` / implicit chunk global | external; write 8040, reads 80418317 | Undeclared framed board alias is configured, exported as `Bejeweled.gameBoard`, and reused as foreground/status/splash parent/anchor. | `gameBoard` | resolved | High for role; accidental global alias. | 1717 | UI/HUD | Rewrite as a local while preserving namespace export. |
| `t` / bootstrap backdrop scratch | 8043 | Reassigned fresh `C()` descriptors for board, status borders, level bars, overlay, and state icon through line 8301. Nested loops/callbacks shadow it only in narrower scopes. | `backdropInfo` | resolved | High. | 1717 | UI/Backdrops, UI/HUD | Split descriptors in rewrite. |
| `S` / game-surface local | 8053 | 400×400 interactive game surface parents background tiles and all gem frames and supplies frame-level base; shadows event dispatcher after its attachment. | `gameSurface` | resolved | High. | 1717 | UI/GemPool | Duplicate global frame name matches foreground at 8078. |
| two `a` bindings / bootstrap duplicate declaration | 8059 | First is hidden by the second in the same declaration; surviving second is hidden at 8082 without a read. | — | shadowed | High. | 1717 | Core/Init | Minifier artifact. |
| `i` / bootstrap UI scratch | 8059 | Receives each board-art tile, then paused-text and splash frames; all constructed frames are retained by parents or `Bejeweled` fields. | `uiFrame` | resolved | High. | 1717 | UI/GemPool, UI/HUD | Split temporal roles in rewrite. |
| `t`,`e` / board-tile loops | 80608061 | Row/column values 03 place sixteen 100×100 repeated texture crops at `(column×100, -row×100)`. | `tileRow`,`tileColumn` | resolved | High. | 1717 | UI/GemPool | None. |
| `a` / status-banner local | 8082 | Hidden one-pixel parent owns status texture/background and custom `SetText`; exported as `Bejeweled.gameStatusText` before line-8127 shadows it. | `gameStatusText` | resolved | High. | 1717 | UI/HUD | None. |
| `d` / status-art local | 8083 | `largeText["Strip"]` metadata supplies background UVs, then line-8121 shadows it. | `stripMetadata` | resolved | High. | 1717 | UI/HUD | None. |
| `n`,`t` / status `SetText` params | 8105 | Receiver and metadata key; parameter `t` is consumed by the initializer at 8106 before the new local shadows it. | `statusFrame`,`textKey` | resolved | High; Lua 5.1 initializer scope is behavior-critical. | 1717 | UI/HUD | None. |
| `t` / status `SetText` metadata local | 8106 | Selected `largeText` array drives dimensions, rectangular/rotated UVs, and RGB tint. | `textMetadata` | resolved | High. | 1717 | UI/HUD | Preserve length-based 9-versus-13 entry shape. |
| `d` / status-bar local | 8121 | Bottom status-bar frame parents level/data/bar layout and supplies frame levels before line-8287 shadows it. | `statusBar` | resolved | High. | 1717 | UI/HUD | None. |
| `a` / level-border local | 8127 | Left status segment owns level number/caption and final width 86 before line-8161 shadows it. | `levelBorder` | resolved | High. | 1717 | UI/HUD | Initial width 122 is overwritten. |
| `s` / data-border local | 8150 | Middle status segment owns data text and final width 128 before line-8189 shadows it. | `dataBorder` | resolved | High. | 1717 | UI/HUD | Initial width 72 is overwritten. |
| `a` / level-bar local | 8161 | Right status segment owns fill/text/mode/score/timer methods and hidden update timer before line-8212 shadows it. | `levelBar` | resolved | High. | 1717 | UI/HUD, Engine/Scoring | None. |
| first `f` / level-bar backing local | 8175 | Dark frame behind the blue level-bar fill; hidden by line-8264 after setup. | `levelBarBackground` | resolved | High. | 1717 | UI/HUD | None. |
| `s` / bar-fill scratch | 8189 | Starts as blue level-bar texture, then is reassigned at 8278 to the red New Game overlay texture; owners retain both. | `barFillTexture` | resolved | High. | 1717 | UI/HUD | Split temporal roles in rewrite. |
| `a` / level-bar-button local | 8212 | Hidden mouse overlay coordinates menu/sub-screen handoff and mode-specific New Game behavior, then owns its red bar/text/icon. | `newGameOverlay` | resolved | High. | 1717 | UI/HUD, UI/Menu | ID 1 and ID 2 are transient states. |
| `t` / overlay show/hide params | 8219, 8222 | Distinct callback parameters are never read; callbacks set status-bar alpha to 0 or 1. | — | dead | High. | 1717 | UI/HUD | None. |
| `e` / overlay enter/leave params | 8225, 8228 | Overlay receiver supplies `.bar`, tinted bright red on enter and dark red on leave. | `newGameOverlay` | resolved | High. | 1717 | UI/HUD | None. |
| `t` / overlay click param | 8231 | Overlay receiver supplies ID/state and is hidden/reset or routes current game mode. | `newGameOverlay` | resolved | High. | 1717 | UI/HUD, UI/Menu | None. |
| `n` / overlay mode local | 8242 | Self-initializer reads outer current-game `n.lastGameMode`; new local selects timed, classic, or generic mode flow. | `lastGameMode` | resolved | High; Lua 5.1 initializer scope is required. | 1717 | UI/Menu | None. |
| second `f` / overlay backing local | 8264 | Dark backing frame behind overlay's red bar; shadows consumed level-bar background local. | `newGameBackground` | resolved | High. | 1717 | UI/HUD | None. |
| `d` / state-icon local | 8287 | Bordered frame immediately left of overlay owns the cropped `UI-StateIcon` texture; shadows consumed status-bar local. | `stateIconFrame` | resolved | High. | 1717 | UI/HUD | None. |
| `t` / splash-hide param | 8322 | Splash callback parameter is unused while account totals/profile fields drive achievement check. | — | dead | High. | 1717 | UI/HUD, Engine/Skills | None. |
| `t`,`o` / splash-update params | 8327 | Splash frame and elapsed delta drive accumulation/fade; `o` is clamped to 0.1 and later shadowed only in nested completion callback. | `splash`,`delta` | resolved | High. | 1717 | UI/HUD | None. |
| `e` / splash fade local | 8335 | Fade descriptor table contains OUT mode, one-second endpoints, and completion callback passed to `UIFrameFade`. | `fadeInfo` | resolved | High. | 1717 | UI/HUD | Replace only after authoritative API verification. |
| `o` / splash-finished local | 8341 | Snapshot of `Bejeweled.paused` restored after saved classic state is loaded. | `wasPaused` | resolved | High. | 1717 | UI/HUD, Engine/Grid | None. |
| `FRAME_LEVEL_JEWEL_SWAP` / implicit chunk global | external; write 8370 | Receives `gameSurface:GetFrameLevel() + 3`; no in-file read follows. | `jewelSwapFrameLevel` | resolved | High for assigned role; external consumer absent. | 1717 | UI/GemPool | Decide whether modernization needs an exported tier. |
| `t`,`e` / gem-grid loops | 83738374 | Zero-based row/column values create 64 gem frames at 50-pixel offsets and store them one-based in grid/fields. | `row`,`column` | resolved | High. | 1717 | UI/GemPool, Engine/Grid | None. |
| `Initialize_OptionsScreen` / implicit chunk global | external; write 8395 | Unqualified nil assignment has no matching declaration/read and does not affect `Bejeweled.Initialize_OptionsScreen`. | — | dead | High. | 1717 | Core/Init | Remove as dead write in rewrite. |
| `e` / final chunk local | 8401 | Declared after bootstrap invocation and never read. | — | dead | High. | 1717 | Unassigned | Minifier artifact. |
## Batch 17 resolution policy
Complete function `k` proves bootstrap ownership and constructor order, so it is resolved as `initializeAddon`, not the narrower compatibility hypothesis from Batch 16. Final attachments resolve score/timer methods, taxi hooks, events, slash commands, gem handlers, board dimensions, and stat key `data`. Unqualified globals and unused frame tiers remain explicit evidence rather than being silently corrected. Sequential coverage is complete; remaining earlier `working`/`unresolved` rows require a cross-batch behavior-critical closure audit before runtime work.
+51
View File
@@ -0,0 +1,51 @@
# Batch 17: lines 80018401
Source: `Legacy/Bejeweled_Mainline.lua` at commit `6faec1c`
Coverage: lines 80018401 inclusive
Blank: 8002, 8399
Status: complete; one-shot bootstrap function `k` closes and is invoked, completing sequential coverage of all 8,401 lines
## Line-indexed coverage audit
| Lines | Evidence represented |
| ---: | --- |
| 8001 | Commented `end` closes only the removed continent check text; executable bootstrap function `k` remains open. |
| 8002 | Blank. |
| 80038004 | Secure-hooks taxi selection and hover handlers, then assigns `v = x(1378301, 4)`. The base-70 encoder produces the four-character key `data`, resolving the authenticated-score field name. |
| 80058031 | Creates animator and main window, installs menu/timed/mode/classic/flight/network/sound/popup/minimap factories, enables keyboard propagation, registers eight window events with dispatcher `S`, and installs `/bejeweled` plus `/bej` on command handler `Ze`. |
| 80328049 | Declares several dead/shadowed minifier locals, creates the board anchor, then assigns an undeclared `gameBoard` global. The exported `Bejeweled.gameBoard` is 414×412 from `s + 14` and `w + 12`, framed two levels above the window. |
| 80508052 | Installs Summary, Feats of Skill, and About screens through factories `B`, `u`, and `m`. |
| 80538077 | Creates the 400×400 mouse-enabled game surface. Nested 03 loops build sixteen 100×100 background tiles at 100-pixel offsets; every tile uses the same `board` texture crop `(0.046875, 0.828125, 0.046875, 0.828125)`, alpha `0.8`, and game-surface frame level. |
| 80788120 | Creates board foreground and hidden large status-banner frame. `SetText` reads `largeText` metadata: widths/heights are entries 12; arrays longer than nine use eight UV coordinates at 310 plus RGB at 1113, otherwise rectangular UVs at 36 plus RGB at 79. It always restores banner/background alpha. |
| 81218160 | Creates bottom status bar, level border, level number/caption, and data border. Width writes `122→86` and `72→128` are intentional last-write-wins evidence; the data border reuses the level-border backdrop. |
| 81618211 | Builds the level/timer bar and darker backing frame, installs the blue `barArt` fill at width `0.01`, attaches score/range/mode/timer methods `ht`, `Bt`, `xt`, `rt`, `Tt`, `kt`, `Ft`, and `Pt`, and wires hidden timer frame `OnUpdate` to `fe`. |
| 82128263 | Builds an initially hidden mouse overlay for New Game/menu handoff. Show/hide toggles status-bar alpha; hover changes the red bar; click ID 1 closes sub-screens, while ID 2 resumes mode-specific flow: timed menu, immediate classic restart, or game-mode menu. |
| 82648302 | Adds the overlay backing/red fill, New Game caption, and a 70×32 state-icon border. The icon uses the top-left quadrant `(0, .49, 0, .49)` of `UI-StateIcon`. |
| 83038326 | Creates/scales hidden Paused text and full-board splash art/copyright. Splash hide checks account-wide `K > 1000` and absent `gainAchieve7`, then requests `SKILL_ACHIEVE4B`; the exact guard/award pairing is preserved evidence. |
| 83278364 | Splash `OnUpdate` clamps a single delta to `0.1`, accumulates only while `elapsed` is set, and fades out after `splashDisplayTime`. Completion hides splash, enables Menu, starts the first classic game, restores a saved classic state while preserving pause, or clears stale progress and shows Menu. |
| 83658386 | Places splash above the window and derives five game-surface-relative frame tiers: gem `+2`, implicit global swap `+3`, then unused local tiers `+4`, `+5`, `+6`. Nested 07 loops create the 8×8 gem grid at 50-pixel offsets, attach enter/leave/click/drag handlers, store one-based `gridX/gridY`, and write each frame to `o[row][column]`. |
| 83878398 | Creates the animator hint, then releases gem-frame, animator, window, menu, summary, Feats, About, Classic-menu, and bootstrap factory references. The unqualified `Initialize_OptionsScreen = nil` is a dead implicit-global write, not the `Bejeweled` method. Function `k` closes. |
| 8399 | Blank. |
| 8400 | Invokes `k` once; it can nil its own binding safely because the call target is evaluated before the function body runs. |
| 8401 | Declares final chunk local `e`, which is never read and is dead. |
## Findings
- `k` is not merely a compatibility helper. Its complete body is the addon's one-shot bootstrap: it forces the post-map-API skill cap, constructs services and UI, hooks taxi APIs, registers events/commands, creates the HUD and 64 gem frames, releases selected constructors, and invokes itself once.
- Base-70 constant decoding proves `v` is the literal key `data`; this pairs with `I = "score"` from Batch 13 and closes the two mode-stat key roles used by the preserved profile wire format.
- The board has three layers: exported framed `gameBoard`, 400×400 interactive game surface, and slightly oversized foreground. The repeated 4×4 background tiles are visual texture repetition, while the separately created 8×8 objects are the authoritative interactive gem grid.
- Frame-level derivation is explicit but asymmetric. Only `Be` (`surface + 2`) is consumed internally; `FRAME_LEVEL_JEWEL_SWAP` is an implicit global, and local `Ie`, `Ge`, and `Ae` receive higher tiers without any in-file reads.
- Constructor cleanup is selective. `A`, `g`, `P`, `B`, `u`, `m`, `F`, `tt`, and `k` are nilled, while several already-invoked constructors remain bound. This is legacy lifetime behavior, not proof that retained factories form a public API.
- The final unqualified `Initialize_OptionsScreen` assignment does not clear `Bejeweled.Initialize_OptionsScreen`; that method is invoked and cleared through the namespace during `VARIABLES_LOADED` at lines 16151618.
## API and architecture mapping
- `Core/Init.lua`: one-shot bootstrap, secure taxi hooks, event registration, slash-command registration, constructor ordering, and temporary-constructor release.
- `UI/HUD.lua`: game-board layers, status banner, status bar, level/timer bar, New Game overlay, paused label, splash flow, and relative frame tiers.
- `UI/GemPool.lua`: sixteen board-art tiles and final 8×8 gem-frame creation/handler wiring.
- `Core/SavedVariables.lua`: authenticated stat field key `data`; preserve it alongside decoded `score` until a documented migration exists.
- `hooksecurefunc`, taxi hooks, keyboard propagation, frame templates/backdrops, slash registration, event names, `UIFrameFade`, and legacy texture paths require authoritative Retail contract verification before runtime implementation.
## Forward dependencies
Sequential source coverage is complete. Before the runtime phase gate can open, perform a cross-batch closure audit of all remaining `working`/`unresolved` ledger rows, distinguish behavior-critical dependencies from dead or externally injected legacy defects, verify every retained WoW API contract against the authoritative Retail snapshot, and turn the completed evidence into an implementation sequence that preserves `BejeweledData` and `BejeweledProfile` wire formats.
+2 -1
View File
@@ -145,9 +145,10 @@ Assert-ReportCoverage 'docs/analysis/lines-6001-6500.md' 6001 6500
Assert-ReportCoverage 'docs/analysis/lines-6501-7000.md' 6501 7000
Assert-ReportCoverage 'docs/analysis/lines-7001-7500.md' 7001 7500
Assert-ReportCoverage 'docs/analysis/lines-7501-8000.md' 7501 8000
Assert-ReportCoverage 'docs/analysis/lines-8001-8401.md' 8001 8401
$lineCount = (Get-Content -LiteralPath 'Legacy/Bejeweled_Mainline.lua').Count
Assert-True ($lineCount -eq 8401) "Legacy source has $lineCount lines, expected 8401"
Write-Output "Verified: forbidden files absent; legacy and $($assetPaths.Count) asset hashes match $SourceCommit."
Write-Output "Verified: strict UTF-8 text, exact 8,401-line schedule, and complete batch-01/02/03/04/05/06/07/08/09/10/11/12/13/14/15/16 line coverage."
Write-Output "Verified: strict UTF-8 text, exact 8,401-line schedule, and complete batch-01/02/03/04/05/06/07/08/09/10/11/12/13/14/15/16/17 line coverage."