A glue Lua state with the reference glue surface, events and ModelFFX (#963)

The first piece of running the stock GlueXML: benilla had no glue Lua state, and no reference data for its surface.

In 1.12.1 the glue state holds the base set (`0x7039e0`) and seven registrars (`0x46abb0`): 119 functions, 105 of them glue-only, with 26 glue events (`0xb41e70`, `0x46a88f`). `RegisterEvent` matches names case-insensitively and drops an unknown one (`0x702140`). The glue builds the 13 base frame types plus `ModelFFX` (`0x46a4fe`), a Model with its own show and paint (`0x46fa00`); the in-game types come only at world entry (`0x495940`).

`reference/` gains the glue event and surface tables, generated and checked against the shapes table. `UiScript::new_glue()` builds that state; a gate holds its globals to the table, with the 108 unbuilt names listed. Nothing in the app changes yet.

Part of #856

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Sam Sung
2026-10-12 07:38:02 +07:00
committed by GitHub
co-authored by Claude Opus 5.5
parent 985dabff44
commit a9dd325bb7
20 changed files with 1449 additions and 214 deletions
+42
View File
@@ -0,0 +1,42 @@
# The glue screens' FrameScript event table of the 1.12.1 client (WoW.exe build 5875): eventId -> name.
# Source: the 26 `mov dword [0xb41e70 + 4*id], imm32` writes of 0x46cc60 (0x46cc60-0x46cd5a, called
# once at startup from 0x402af8), each imm32 the address of the event's name string. The glue
# builder 0x46a7b0 hands the array to 0x703d90 (`mov edx,0x1a; mov ecx,0xb41e70; call 0x703d90`
# at 0x46a885-0x46a88f), which rebuilds the runtime dispatch table [0xceef68] from it wholesale,
# as UI_Init does with the in-game array 0xbe1198 (`1.12-event-catalog.tsv`). So while the glue
# state runs, these 26 are the only events, the id fired by FrameScript_SignalEvent 0x703e50 /
# 0x703f50 indexes this table, and the same integer names a different event in-game.
# Registration: `RegisterEvent` 0x774a40 -> 0x702140 walks the table and compares names with
# 0x64a4c0 (-> 0x414310, case-insensitive); a name off the table matches nothing and is dropped
# without an error. `UnregisterEvent` 0x774b30 -> 0x702280 matches the same way.
# Vendored from the client's bytes; no generator for it lives in this repo.
#
# name_va the name string's address (the imm32).
# write_va the instruction in 0x46cc60 that stores it.
id name name_va write_va
0 SET_GLUE_SCREEN 0x837bec 0x46cc60
1 START_GLUE_MUSIC 0x837bd8 0x46cc6a
2 DISCONNECTED_FROM_SERVER 0x837bbc 0x46cc74
3 OPEN_STATUS_DIALOG 0x837ba8 0x46cc7e
4 UPDATE_STATUS_DIALOG 0x837b90 0x46cc88
5 CLOSE_STATUS_DIALOG 0x837b7c 0x46cc92
6 ADDON_LIST_UPDATE 0x837b68 0x46cc9c
7 CHARACTER_LIST_UPDATE 0x837b50 0x46cca6
8 UPDATE_SELECTED_CHARACTER 0x837b34 0x46ccb0
9 OPEN_REALM_LIST 0x837b24 0x46ccba
10 GET_PREFERRED_REALM_INFO 0x837b08 0x46ccc4
11 UPDATE_SELECTED_RACE 0x837af0 0x46ccce
12 SELECT_LAST_CHARACTER 0x837ad8 0x46ccd8
13 SELECT_FIRST_CHARACTER 0x837ac0 0x46cce2
14 GLUE_SCREENSHOT_SUCCEEDED 0x837aa4 0x46ccec
15 GLUE_SCREENSHOT_FAILED 0x837a8c 0x46ccf6
16 PATCH_UPDATE_PROGRESS 0x837a74 0x46cd00
17 PATCH_DOWNLOADED 0x837a60 0x46cd0a
18 SUGGEST_REALM 0x837a50 0x46cd14
19 SUGGEST_REALM_WRONG_PVP 0x837a38 0x46cd1e
20 SUGGEST_REALM_WRONG_CATEGORY 0x837a18 0x46cd28
21 SHOW_SERVER_ALERT 0x837a04 0x46cd32
22 FRAMES_LOADED 0x8379f4 0x46cd3c
23 FORCE_RENAME_CHARACTER 0x8379dc 0x46cd46
24 SHOW_SURVEY_NOTIFICATION 0x8379c0 0x46cd50
25 PLAYER_ENTER_PIN 0x8379ac 0x46cd5a
1 # The glue screens' FrameScript event table of the 1.12.1 client (WoW.exe build 5875): eventId -> name.
2 # Source: the 26 `mov dword [0xb41e70 + 4*id], imm32` writes of 0x46cc60 (0x46cc60-0x46cd5a, called
3 # once at startup from 0x402af8), each imm32 the address of the event's name string. The glue
4 # builder 0x46a7b0 hands the array to 0x703d90 (`mov edx,0x1a; mov ecx,0xb41e70; call 0x703d90`
5 # at 0x46a885-0x46a88f), which rebuilds the runtime dispatch table [0xceef68] from it wholesale,
6 # as UI_Init does with the in-game array 0xbe1198 (`1.12-event-catalog.tsv`). So while the glue
7 # state runs, these 26 are the only events, the id fired by FrameScript_SignalEvent 0x703e50 /
8 # 0x703f50 indexes this table, and the same integer names a different event in-game.
9 # Registration: `RegisterEvent` 0x774a40 -> 0x702140 walks the table and compares names with
10 # 0x64a4c0 (-> 0x414310, case-insensitive); a name off the table matches nothing and is dropped
11 # without an error. `UnregisterEvent` 0x774b30 -> 0x702280 matches the same way.
12 # Vendored from the client's bytes; no generator for it lives in this repo.
13 #
14 # name_va the name string's address (the imm32).
15 # write_va the instruction in 0x46cc60 that stores it.
16 id name name_va write_va
17 0 SET_GLUE_SCREEN 0x837bec 0x46cc60
18 1 START_GLUE_MUSIC 0x837bd8 0x46cc6a
19 2 DISCONNECTED_FROM_SERVER 0x837bbc 0x46cc74
20 3 OPEN_STATUS_DIALOG 0x837ba8 0x46cc7e
21 4 UPDATE_STATUS_DIALOG 0x837b90 0x46cc88
22 5 CLOSE_STATUS_DIALOG 0x837b7c 0x46cc92
23 6 ADDON_LIST_UPDATE 0x837b68 0x46cc9c
24 7 CHARACTER_LIST_UPDATE 0x837b50 0x46cca6
25 8 UPDATE_SELECTED_CHARACTER 0x837b34 0x46ccb0
26 9 OPEN_REALM_LIST 0x837b24 0x46ccba
27 10 GET_PREFERRED_REALM_INFO 0x837b08 0x46ccc4
28 11 UPDATE_SELECTED_RACE 0x837af0 0x46ccce
29 12 SELECT_LAST_CHARACTER 0x837ad8 0x46ccd8
30 13 SELECT_FIRST_CHARACTER 0x837ac0 0x46cce2
31 14 GLUE_SCREENSHOT_SUCCEEDED 0x837aa4 0x46ccec
32 15 GLUE_SCREENSHOT_FAILED 0x837a8c 0x46ccf6
33 16 PATCH_UPDATE_PROGRESS 0x837a74 0x46cd00
34 17 PATCH_DOWNLOADED 0x837a60 0x46cd0a
35 18 SUGGEST_REALM 0x837a50 0x46cd14
36 19 SUGGEST_REALM_WRONG_PVP 0x837a38 0x46cd1e
37 20 SUGGEST_REALM_WRONG_CATEGORY 0x837a18 0x46cd28
38 21 SHOW_SERVER_ALERT 0x837a04 0x46cd32
39 22 FRAMES_LOADED 0x8379f4 0x46cd3c
40 23 FORCE_RENAME_CHARACTER 0x8379dc 0x46cd46
41 24 SHOW_SURVEY_NOTIFICATION 0x8379c0 0x46cd50
42 25 PLAYER_ENTER_PIN 0x8379ac 0x46cd5a
+212
View File
@@ -0,0 +1,212 @@
# The glue screens' Lua surface in the 1.12.1 client (build 5875): every function in `_G`
# once the glue builder 0x46a7b0 has installed its registrars, before GlueXML loads.
# Generated by scripts/gen-reference-glue-surface.py from reference/1.12-shapes.tsv and
# reference/1.12-globals.tsv; the generator's header carries the registrars and the method.
#
# scope base = FrameScript's Lua init 0x7039e0, which both states run; shared = a
# registrar the in-game state calls too (0x51bb20, 0x706350, 0x4587f0); glue =
# a glue-only registrar table (0x46ddf0, 0x4736c0, 0x471a20, 0x46f480).
# fn, table_va, arity as 1.12-shapes.tsv has them. A base alias the compat chunk
# 0x8722e8 defines carries the library binding it names (`tinsert` is table
# 0x822d40's `insert`), or fn `lua` for a degree-converting closure; math's
# global `__pow` (0x7fb050) has no table.
# world_fn a glue row's in-game namesake, a different binding; `-` if none.
# note shape-differs = both shapes exact, and the glue binding takes or returns a
# different count than its in-game namesake.
# 195 functions: 76 base, 14 shared, 105 glue; 6 glue rows differ in shape from their in-game namesake.
scope registrar name fn table_va arity world_fn note
base 0x7039e0 assert 0x7031a0 0x811e28 1 -
base 0x7039e0 collectgarbage 0x703250 0x811e28 0 -
base 0x7039e0 date 0x7033a0 0x811e28 1 -
base 0x7039e0 debugbreak 0x702820 0x811e28 0 -
base 0x7039e0 debugdump 0x702810 0x811e28 0 -
base 0x7039e0 debuginfo 0x7027f0 0x811e28 0 -
base 0x7039e0 debugload 0x7027e0 0x811e28 0 -
base 0x7039e0 debugprint 0x702800 0x811e28 0 -
base 0x7039e0 debugprofilestart 0x702840 0x811e28 0 -
base 0x7039e0 debugprofilestop 0x702860 0x811e28 1 -
base 0x7039e0 debugstack 0x703760 0x811e28 1 -
base 0x7039e0 debugtimestamp 0x702830 0x811e28 0 -
base 0x7039e0 error 0x702970 0x811e28 ? -
base 0x7039e0 gcinfo 0x703200 0x811e28 2 -
base 0x7039e0 geterrorhandler 0x702950 0x811e28 1 -
base 0x7039e0 getfenv 0x702ac0 0x811e28 1 -
base 0x7039e0 getglobal 0x7027b0 0x811e28 1 -
base 0x7039e0 getmetatable 0x7029f0 0x811e28 1 -
base 0x7039e0 ipairs 0x702cd0 0x811e28 ? -
base 0x7039e0 loadstring 0x703280 0x811e28 1|2 -
base 0x7039e0 next 0x702c90 0x811e28 1|2 -
base 0x7039e0 pairs 0x702da0 0x811e28 3 -
base 0x7039e0 pcall 0x7032f0 0x811e28 ? -
base 0x7039e0 rawequal 0x7030f0 0x811e28 1 -
base 0x7039e0 rawget 0x703130 0x811e28 1 -
base 0x7039e0 rawset 0x703160 0x811e28 1 -
base 0x7039e0 seterrorhandler 0x702900 0x811e28 0 -
base 0x7039e0 setfenv 0x702be0 0x811e28 0 -
base 0x7039e0 setglobal 0x702770 0x811e28 0 -
base 0x7039e0 setmetatable 0x702a40 0x811e28 1 -
base 0x7039e0 time 0x7035a0 0x811e28 1 -
base 0x7039e0 tonumber 0x702e30 0x811e28 1 -
base 0x7039e0 tostring 0x702f40 0x811e28 1 -
base 0x7039e0 type 0x702df0 0x811e28 1 -
base 0x7039e0 unpack 0x7030a0 0x811e28 ? -
base 0x7039e0 xpcall 0x703340 0x811e28 ? -
shared 0x51bb20 AppendToFile 0x515f90 0x8503f4 ? -
shared 0x51bb20 ConsoleExec 0x515f10 0x8503f4 0 -
shared 0x51bb20 DeleteFile 0x515f70 0x8503f4 ? -
shared 0x51bb20 GetGameTime 0x515ee0 0x8503f4 2 -
shared 0x51bb20 GetTime 0x515ea0 0x8503f4 1 -
shared 0x51bb20 ReadFile 0x515f50 0x8503f4 ? -
shared 0x706350 CreateFont 0x706040 0x872e74 1 -
shared 0x706350 CreateFrame 0x7060b0 0x872e74 1 -
shared 0x706350 EnumerateFrames 0x705f60 0x872e74 1 -
shared 0x706350 GetNumFrames 0x705f00 0x872e74 1 -
glue 0x46ddf0 AcceptContest 0x46d150 0x8373b8 0 -
glue 0x46ddf0 AcceptEULA 0x46d070 0x8373b8 0 -
glue 0x46ddf0 AcceptScanning 0x46d0e0 0x8373b8 0 -
glue 0x46ddf0 AcceptTOS 0x46d000 0x8373b8 0 -
glue 0x46ddf0 ContestAccepted 0x46d120 0x8373b8 1 -
glue 0x46ddf0 DefaultServerLogin 0x46d160 0x8373b8 0 -
glue 0x46ddf0 DisableAddOn 0x46d8a0 0x8373b8 0 0x48e760 shape-differs: argc 2 here, 1 in-game (0x48e760)
glue 0x46ddf0 DisableAllAddOns 0x46d940 0x8373b8 0 0x48e7f0 shape-differs: argc 1 here, 0 in-game (0x48e7f0)
glue 0x46ddf0 DisconnectFromServer 0x46d340 0x8373b8 0 -
glue 0x46ddf0 EULAAccepted 0x46d040 0x8373b8 1 -
glue 0x46ddf0 EnableAddOn 0x46d7b0 0x8373b8 0 0x48e690 shape-differs: argc 2 here, 1 in-game (0x48e690)
glue 0x46ddf0 EnableAllAddOns 0x46d850 0x8373b8 0 0x48e720 shape-differs: argc 1 here, 0 in-game (0x48e720)
glue 0x46ddf0 EnterWorld 0x46d3c0 0x8373b8 0 -
glue 0x46ddf0 GetAddOnDependencies 0x46d650 0x8373b8 ? 0x48e5e0
glue 0x46ddf0 GetAddOnEnableState 0x46d6f0 0x8373b8 1 -
glue 0x46ddf0 GetAddOnInfo 0x46d460 0x8373b8 8 0x48e390 shape-differs: arity 8 here, 7 in-game (0x48e390)
glue 0x46ddf0 GetBillingPlan 0x46dc40 0x8373b8 3 -
glue 0x46ddf0 GetBillingTimeRemaining 0x46dbf0 0x8373b8 1 -
glue 0x46ddf0 GetBillingTimeRested 0x46dcf0 0x8373b8 1 0x48ec50
glue 0x46ddf0 GetBuildInfo 0x46cd70 0x8373b8 5 0x4884a0 shape-differs: arity 5 here, 3 in-game (0x4884a0)
glue 0x46ddf0 GetCursorPosition 0x46dad0 0x8373b8 2 0x48b820
glue 0x46ddf0 GetLocale 0x46ce40 0x8373b8 1 0x48d8b0
glue 0x46ddf0 GetMovieResolution 0x46cf10 0x8373b8 1 -
glue 0x46ddf0 GetMovieSubtitles 0x46dbc0 0x8373b8 1 -
glue 0x46ddf0 GetNumAddOns 0x46d420 0x8373b8 1 0x48e350
glue 0x46ddf0 GetSavedAccountName 0x46cdd0 0x8373b8 1 -
glue 0x46ddf0 GetScreenHeight 0x46dd80 0x8373b8 1 0x48b4d0
glue 0x46ddf0 GetScreenWidth 0x46dd30 0x8373b8 1 0x48b480
glue 0x46ddf0 GetScriptMemory 0x46da10 0x8373b8 1 -
glue 0x46ddf0 GetServerName 0x46d280 0x8373b8 3 -
glue 0x46ddf0 HideCursor 0x46db70 0x8373b8 0 -
glue 0x46ddf0 IsAddonVersionCheckEnabled 0x46d9b0 0x8373b8 1 -
glue 0x46ddf0 IsConnectedToServer 0x46d380 0x8373b8 1 -
glue 0x46ddf0 LaunchAddOnURL 0x46d5e0 0x8373b8 0 -
glue 0x46ddf0 LaunchURL 0x46cf60 0x8373b8 0 -
glue 0x46ddf0 PINEntered 0x46d1c0 0x8373b8 0 -
glue 0x46ddf0 PatchDownloadApply 0x46d410 0x8373b8 0 -
glue 0x46ddf0 PatchDownloadCancel 0x46d400 0x8373b8 0 -
glue 0x46ddf0 PatchDownloadProgress 0x46d3e0 0x8373b8 1 -
glue 0x46ddf0 PlayCreditsMusic 0x46cef0 0x8373b8 0 -
glue 0x46ddf0 PlayGlueMusic 0x46ceb0 0x8373b8 0 -
glue 0x46ddf0 QuitGame 0x46cea0 0x8373b8 0 -
glue 0x46ddf0 ResetAddOns 0x46d9a0 0x8373b8 0 -
glue 0x46ddf0 SaveAddOns 0x46d990 0x8373b8 0 -
glue 0x46ddf0 ScanningAccepted 0x46d0b0 0x8373b8 1 -
glue 0x46ddf0 Screenshot 0x46d3d0 0x8373b8 0 0x4893d0
glue 0x46ddf0 SetAddonVersionCheck 0x46d9e0 0x8373b8 0 -
glue 0x46ddf0 SetCurrentScreen 0x46ce60 0x8373b8 0 -
glue 0x46ddf0 SetMovieSubtitles 0x46db80 0x8373b8 0 -
glue 0x46ddf0 SetSavedAccountName 0x46cdf0 0x8373b8 0 -
glue 0x46ddf0 SetScriptMemory 0x46da50 0x8373b8 0 -
glue 0x46ddf0 ShowContestNotice 0x46d0f0 0x8373b8 1 -
glue 0x46ddf0 ShowCursor 0x46db60 0x8373b8 0 -
glue 0x46ddf0 ShowEULANotice 0x46d010 0x8373b8 1 -
glue 0x46ddf0 ShowScanningNotice 0x46d080 0x8373b8 1 -
glue 0x46ddf0 ShowTOSNotice 0x46cfa0 0x8373b8 1 -
glue 0x46ddf0 StatusDialogClick 0x46d270 0x8373b8 0 -
glue 0x46ddf0 StopGlueMusic 0x46cf00 0x8373b8 0 -
glue 0x46ddf0 SurveyNotificationDone 0x46ddd0 0x8373b8 1 -
glue 0x46ddf0 TOSAccepted 0x46cfd0 0x8373b8 1 -
glue 0x4736c0 DeleteCharacter 0x4734c0 0x838578 0 -
glue 0x4736c0 GetCharacterInfo 0x4732a0 0x838578 8 -
glue 0x4736c0 GetCharacterListUpdate 0x473270 0x838578 0 -
glue 0x4736c0 GetCharacterSelectFacing 0x473650 0x838578 1 -
glue 0x4736c0 GetNumCharacters 0x473280 0x838578 1 -
glue 0x4736c0 RenameCharacter 0x473520 0x838578 0|1 -
glue 0x4736c0 SelectCharacter 0x473470 0x838578 0 -
glue 0x4736c0 SetCharSelectBackground 0x473230 0x838578 0 -
glue 0x4736c0 SetCharSelectModelFrame 0x4731c0 0x838578 0 -
glue 0x4736c0 SetCharacterSelectFacing 0x473670 0x838578 1 -
glue 0x4736c0 UpdateSelectionCustomizationScene 0x473640 0x838578 0 -
glue 0x471a20 CreateCharacter 0x4719e0 0x8380f8 0 -
glue 0x471a20 CycleCharCustomization 0x471890 0x8380f8 0 -
glue 0x471a20 GetAvailableRaces 0x471520 0x8380f8 ? -
glue 0x471a20 GetCharacterCreateFacing 0x471910 0x8380f8 1 -
glue 0x471a20 GetClassesForRace 0x471560 0x8380f8 ? -
glue 0x471a20 GetFacialHairCustomization 0x471620 0x8380f8 1 -
glue 0x471a20 GetFactionForRace 0x471450 0x8380f8 2 -
glue 0x471a20 GetHairCustomization 0x4715d0 0x8380f8 1 -
glue 0x471a20 GetNameForRace 0x4713f0 0x8380f8 2 -
glue 0x471a20 GetRandomName 0x471980 0x8380f8 1 -
glue 0x471a20 GetSelectedClass 0x4716e0 0x8380f8 2 -
glue 0x471a20 GetSelectedRace 0x471680 0x8380f8 1 -
glue 0x471a20 GetSelectedSex 0x4716b0 0x8380f8 1 -
glue 0x471a20 HasCharCustomization 0x471820 0x8380f8 1 -
glue 0x471a20 RandomizeCharCustomization 0x471900 0x8380f8 0 -
glue 0x471a20 ResetCharCustomize 0x4713e0 0x8380f8 0 -
glue 0x471a20 SetCharCustomizeBackground 0x4713a0 0x8380f8 0 -
glue 0x471a20 SetCharCustomizeFrame 0x471330 0x8380f8 0 -
glue 0x471a20 SetCharacterCreateFacing 0x471930 0x8380f8 1 -
glue 0x471a20 SetSelectedClass 0x4717c0 0x8380f8 0 -
glue 0x471a20 SetSelectedRace 0x471740 0x8380f8 0 -
glue 0x471a20 SetSelectedSex 0x471780 0x8380f8 0 -
glue 0x471a20 UpdateCustomizationBackground 0x471800 0x8380f8 0 -
glue 0x471a20 UpdateCustomizationScene 0x471810 0x8380f8 0 -
glue 0x46f480 CancelRealmListQuery 0x46ed10 0x837ea0 0 -
glue 0x46f480 ChangeRealm 0x46f0e0 0x837ea0 0 -
glue 0x46f480 GetNumRealms 0x46ed30 0x837ea0 1 -
glue 0x46f480 GetRealmCategories 0x46f1f0 0x837ea0 ? -
glue 0x46f480 GetRealmInfo 0x46ee40 0x837ea0 8 -
glue 0x46f480 GetSelectedCategory 0x46f400 0x837ea0 1 -
glue 0x46f480 RealmListDialogCancelled 0x46ed20 0x837ea0 0 -
glue 0x46f480 RequestRealmList 0x46ecf0 0x837ea0 0 -
glue 0x46f480 SetPreferredInfo 0x46f2c0 0x837ea0 0 -
glue 0x46f480 SortRealms 0x46f330 0x837ea0 0 -
shared 0x4587f0 PlayMusic 0x458720 0x835a50 0 -
shared 0x4587f0 PlaySound 0x4586d0 0x835a50 0 -
shared 0x4587f0 PlaySoundFile 0x458780 0x835a50 1 -
shared 0x4587f0 StopMusic 0x458770 0x835a50 0 -
base 0x7039e0 foreach 0x7fb590 0x822d40 0|1 -
base 0x7039e0 foreachi 0x7fb4e0 0x822d40 0|1 -
base 0x7039e0 getn 0x7fb630 0x822d40 1 -
base 0x7039e0 tinsert 0x7fb6b0 0x822d40 0 -
base 0x7039e0 tremove 0x7fb770 0x822d40 0|1 -
base 0x7039e0 sort 0x7fb920 0x822d40 0 -
base 0x7039e0 abs 0x7fade0 0x822c60 1 -
base 0x7039e0 acos lua - ? -
base 0x7039e0 asin lua - ? -
base 0x7039e0 atan lua - ? -
base 0x7039e0 atan2 lua - ? -
base 0x7039e0 ceil 0x7faf70 0x822c60 1 -
base 0x7039e0 cos lua - ? -
base 0x7039e0 deg 0x7fb140 0x822c60 1 -
base 0x7039e0 exp 0x7fb100 0x822c60 1 -
base 0x7039e0 floor 0x7fafa0 0x822c60 1 -
base 0x7039e0 frexp 0x7fb1a0 0x822c60 2 -
base 0x7039e0 ldexp 0x7fb1f0 0x822c60 1 -
base 0x7039e0 log 0x7fb0a0 0x822c60 1 -
base 0x7039e0 log10 0x7fb0d0 0x822c60 1 -
base 0x7039e0 max 0x7fb2a0 0x822c60 1 -
base 0x7039e0 min 0x7fb230 0x822c60 1 -
base 0x7039e0 mod 0x7fafd0 0x822c60 1 -
base 0x7039e0 rad 0x7fb170 0x822c60 1 -
base 0x7039e0 random 0x7fb310 0x822c60 1 -
base 0x7039e0 randomseed 0x7fb450 0x822c60 0 -
base 0x7039e0 sin lua - ? -
base 0x7039e0 sqrt 0x7fb020 0x822c60 1 -
base 0x7039e0 tan lua - ? -
base 0x7039e0 strbyte 0x7fc210 0x822d88 0|1 -
base 0x7039e0 strchar 0x7fc280 0x822d88 1 -
base 0x7039e0 strfind 0x7fc3b0 0x822d88 ? -
base 0x7039e0 format 0x7fd3d0 0x822d88 1 -
base 0x7039e0 gsub 0x7fd0e0 0x822d88 2 -
base 0x7039e0 strlen 0x7fbcf0 0x822d88 1 -
base 0x7039e0 strlower 0x7fbdf0 0x822d88 1 -
base 0x7039e0 strrep 0x7fc1a0 0x822d88 1 -
base 0x7039e0 strsub 0x7fbd30 0x822d88 1 -
base 0x7039e0 strupper 0x7fc0c0 0x822d88 1 -
base 0x7039e0 __pow 0x7fb050 - 1 -
1 # The glue screens' Lua surface in the 1.12.1 client (build 5875): every function in `_G`
2 # once the glue builder 0x46a7b0 has installed its registrars, before GlueXML loads.
3 # Generated by scripts/gen-reference-glue-surface.py from reference/1.12-shapes.tsv and
4 # reference/1.12-globals.tsv; the generator's header carries the registrars and the method.
5 #
6 # scope base = FrameScript's Lua init 0x7039e0, which both states run; shared = a
7 # registrar the in-game state calls too (0x51bb20, 0x706350, 0x4587f0); glue =
8 # a glue-only registrar table (0x46ddf0, 0x4736c0, 0x471a20, 0x46f480).
9 # fn, table_va, arity as 1.12-shapes.tsv has them. A base alias the compat chunk
10 # 0x8722e8 defines carries the library binding it names (`tinsert` is table
11 # 0x822d40's `insert`), or fn `lua` for a degree-converting closure; math's
12 # global `__pow` (0x7fb050) has no table.
13 # world_fn a glue row's in-game namesake, a different binding; `-` if none.
14 # note shape-differs = both shapes exact, and the glue binding takes or returns a
15 # different count than its in-game namesake.
16 # 195 functions: 76 base, 14 shared, 105 glue; 6 glue rows differ in shape from their in-game namesake.
17 scope registrar name fn table_va arity world_fn note
18 base 0x7039e0 assert 0x7031a0 0x811e28 1 -
19 base 0x7039e0 collectgarbage 0x703250 0x811e28 0 -
20 base 0x7039e0 date 0x7033a0 0x811e28 1 -
21 base 0x7039e0 debugbreak 0x702820 0x811e28 0 -
22 base 0x7039e0 debugdump 0x702810 0x811e28 0 -
23 base 0x7039e0 debuginfo 0x7027f0 0x811e28 0 -
24 base 0x7039e0 debugload 0x7027e0 0x811e28 0 -
25 base 0x7039e0 debugprint 0x702800 0x811e28 0 -
26 base 0x7039e0 debugprofilestart 0x702840 0x811e28 0 -
27 base 0x7039e0 debugprofilestop 0x702860 0x811e28 1 -
28 base 0x7039e0 debugstack 0x703760 0x811e28 1 -
29 base 0x7039e0 debugtimestamp 0x702830 0x811e28 0 -
30 base 0x7039e0 error 0x702970 0x811e28 ? -
31 base 0x7039e0 gcinfo 0x703200 0x811e28 2 -
32 base 0x7039e0 geterrorhandler 0x702950 0x811e28 1 -
33 base 0x7039e0 getfenv 0x702ac0 0x811e28 1 -
34 base 0x7039e0 getglobal 0x7027b0 0x811e28 1 -
35 base 0x7039e0 getmetatable 0x7029f0 0x811e28 1 -
36 base 0x7039e0 ipairs 0x702cd0 0x811e28 ? -
37 base 0x7039e0 loadstring 0x703280 0x811e28 1|2 -
38 base 0x7039e0 next 0x702c90 0x811e28 1|2 -
39 base 0x7039e0 pairs 0x702da0 0x811e28 3 -
40 base 0x7039e0 pcall 0x7032f0 0x811e28 ? -
41 base 0x7039e0 rawequal 0x7030f0 0x811e28 1 -
42 base 0x7039e0 rawget 0x703130 0x811e28 1 -
43 base 0x7039e0 rawset 0x703160 0x811e28 1 -
44 base 0x7039e0 seterrorhandler 0x702900 0x811e28 0 -
45 base 0x7039e0 setfenv 0x702be0 0x811e28 0 -
46 base 0x7039e0 setglobal 0x702770 0x811e28 0 -
47 base 0x7039e0 setmetatable 0x702a40 0x811e28 1 -
48 base 0x7039e0 time 0x7035a0 0x811e28 1 -
49 base 0x7039e0 tonumber 0x702e30 0x811e28 1 -
50 base 0x7039e0 tostring 0x702f40 0x811e28 1 -
51 base 0x7039e0 type 0x702df0 0x811e28 1 -
52 base 0x7039e0 unpack 0x7030a0 0x811e28 ? -
53 base 0x7039e0 xpcall 0x703340 0x811e28 ? -
54 shared 0x51bb20 AppendToFile 0x515f90 0x8503f4 ? -
55 shared 0x51bb20 ConsoleExec 0x515f10 0x8503f4 0 -
56 shared 0x51bb20 DeleteFile 0x515f70 0x8503f4 ? -
57 shared 0x51bb20 GetGameTime 0x515ee0 0x8503f4 2 -
58 shared 0x51bb20 GetTime 0x515ea0 0x8503f4 1 -
59 shared 0x51bb20 ReadFile 0x515f50 0x8503f4 ? -
60 shared 0x706350 CreateFont 0x706040 0x872e74 1 -
61 shared 0x706350 CreateFrame 0x7060b0 0x872e74 1 -
62 shared 0x706350 EnumerateFrames 0x705f60 0x872e74 1 -
63 shared 0x706350 GetNumFrames 0x705f00 0x872e74 1 -
64 glue 0x46ddf0 AcceptContest 0x46d150 0x8373b8 0 -
65 glue 0x46ddf0 AcceptEULA 0x46d070 0x8373b8 0 -
66 glue 0x46ddf0 AcceptScanning 0x46d0e0 0x8373b8 0 -
67 glue 0x46ddf0 AcceptTOS 0x46d000 0x8373b8 0 -
68 glue 0x46ddf0 ContestAccepted 0x46d120 0x8373b8 1 -
69 glue 0x46ddf0 DefaultServerLogin 0x46d160 0x8373b8 0 -
70 glue 0x46ddf0 DisableAddOn 0x46d8a0 0x8373b8 0 0x48e760 shape-differs: argc 2 here, 1 in-game (0x48e760)
71 glue 0x46ddf0 DisableAllAddOns 0x46d940 0x8373b8 0 0x48e7f0 shape-differs: argc 1 here, 0 in-game (0x48e7f0)
72 glue 0x46ddf0 DisconnectFromServer 0x46d340 0x8373b8 0 -
73 glue 0x46ddf0 EULAAccepted 0x46d040 0x8373b8 1 -
74 glue 0x46ddf0 EnableAddOn 0x46d7b0 0x8373b8 0 0x48e690 shape-differs: argc 2 here, 1 in-game (0x48e690)
75 glue 0x46ddf0 EnableAllAddOns 0x46d850 0x8373b8 0 0x48e720 shape-differs: argc 1 here, 0 in-game (0x48e720)
76 glue 0x46ddf0 EnterWorld 0x46d3c0 0x8373b8 0 -
77 glue 0x46ddf0 GetAddOnDependencies 0x46d650 0x8373b8 ? 0x48e5e0
78 glue 0x46ddf0 GetAddOnEnableState 0x46d6f0 0x8373b8 1 -
79 glue 0x46ddf0 GetAddOnInfo 0x46d460 0x8373b8 8 0x48e390 shape-differs: arity 8 here, 7 in-game (0x48e390)
80 glue 0x46ddf0 GetBillingPlan 0x46dc40 0x8373b8 3 -
81 glue 0x46ddf0 GetBillingTimeRemaining 0x46dbf0 0x8373b8 1 -
82 glue 0x46ddf0 GetBillingTimeRested 0x46dcf0 0x8373b8 1 0x48ec50
83 glue 0x46ddf0 GetBuildInfo 0x46cd70 0x8373b8 5 0x4884a0 shape-differs: arity 5 here, 3 in-game (0x4884a0)
84 glue 0x46ddf0 GetCursorPosition 0x46dad0 0x8373b8 2 0x48b820
85 glue 0x46ddf0 GetLocale 0x46ce40 0x8373b8 1 0x48d8b0
86 glue 0x46ddf0 GetMovieResolution 0x46cf10 0x8373b8 1 -
87 glue 0x46ddf0 GetMovieSubtitles 0x46dbc0 0x8373b8 1 -
88 glue 0x46ddf0 GetNumAddOns 0x46d420 0x8373b8 1 0x48e350
89 glue 0x46ddf0 GetSavedAccountName 0x46cdd0 0x8373b8 1 -
90 glue 0x46ddf0 GetScreenHeight 0x46dd80 0x8373b8 1 0x48b4d0
91 glue 0x46ddf0 GetScreenWidth 0x46dd30 0x8373b8 1 0x48b480
92 glue 0x46ddf0 GetScriptMemory 0x46da10 0x8373b8 1 -
93 glue 0x46ddf0 GetServerName 0x46d280 0x8373b8 3 -
94 glue 0x46ddf0 HideCursor 0x46db70 0x8373b8 0 -
95 glue 0x46ddf0 IsAddonVersionCheckEnabled 0x46d9b0 0x8373b8 1 -
96 glue 0x46ddf0 IsConnectedToServer 0x46d380 0x8373b8 1 -
97 glue 0x46ddf0 LaunchAddOnURL 0x46d5e0 0x8373b8 0 -
98 glue 0x46ddf0 LaunchURL 0x46cf60 0x8373b8 0 -
99 glue 0x46ddf0 PINEntered 0x46d1c0 0x8373b8 0 -
100 glue 0x46ddf0 PatchDownloadApply 0x46d410 0x8373b8 0 -
101 glue 0x46ddf0 PatchDownloadCancel 0x46d400 0x8373b8 0 -
102 glue 0x46ddf0 PatchDownloadProgress 0x46d3e0 0x8373b8 1 -
103 glue 0x46ddf0 PlayCreditsMusic 0x46cef0 0x8373b8 0 -
104 glue 0x46ddf0 PlayGlueMusic 0x46ceb0 0x8373b8 0 -
105 glue 0x46ddf0 QuitGame 0x46cea0 0x8373b8 0 -
106 glue 0x46ddf0 ResetAddOns 0x46d9a0 0x8373b8 0 -
107 glue 0x46ddf0 SaveAddOns 0x46d990 0x8373b8 0 -
108 glue 0x46ddf0 ScanningAccepted 0x46d0b0 0x8373b8 1 -
109 glue 0x46ddf0 Screenshot 0x46d3d0 0x8373b8 0 0x4893d0
110 glue 0x46ddf0 SetAddonVersionCheck 0x46d9e0 0x8373b8 0 -
111 glue 0x46ddf0 SetCurrentScreen 0x46ce60 0x8373b8 0 -
112 glue 0x46ddf0 SetMovieSubtitles 0x46db80 0x8373b8 0 -
113 glue 0x46ddf0 SetSavedAccountName 0x46cdf0 0x8373b8 0 -
114 glue 0x46ddf0 SetScriptMemory 0x46da50 0x8373b8 0 -
115 glue 0x46ddf0 ShowContestNotice 0x46d0f0 0x8373b8 1 -
116 glue 0x46ddf0 ShowCursor 0x46db60 0x8373b8 0 -
117 glue 0x46ddf0 ShowEULANotice 0x46d010 0x8373b8 1 -
118 glue 0x46ddf0 ShowScanningNotice 0x46d080 0x8373b8 1 -
119 glue 0x46ddf0 ShowTOSNotice 0x46cfa0 0x8373b8 1 -
120 glue 0x46ddf0 StatusDialogClick 0x46d270 0x8373b8 0 -
121 glue 0x46ddf0 StopGlueMusic 0x46cf00 0x8373b8 0 -
122 glue 0x46ddf0 SurveyNotificationDone 0x46ddd0 0x8373b8 1 -
123 glue 0x46ddf0 TOSAccepted 0x46cfd0 0x8373b8 1 -
124 glue 0x4736c0 DeleteCharacter 0x4734c0 0x838578 0 -
125 glue 0x4736c0 GetCharacterInfo 0x4732a0 0x838578 8 -
126 glue 0x4736c0 GetCharacterListUpdate 0x473270 0x838578 0 -
127 glue 0x4736c0 GetCharacterSelectFacing 0x473650 0x838578 1 -
128 glue 0x4736c0 GetNumCharacters 0x473280 0x838578 1 -
129 glue 0x4736c0 RenameCharacter 0x473520 0x838578 0|1 -
130 glue 0x4736c0 SelectCharacter 0x473470 0x838578 0 -
131 glue 0x4736c0 SetCharSelectBackground 0x473230 0x838578 0 -
132 glue 0x4736c0 SetCharSelectModelFrame 0x4731c0 0x838578 0 -
133 glue 0x4736c0 SetCharacterSelectFacing 0x473670 0x838578 1 -
134 glue 0x4736c0 UpdateSelectionCustomizationScene 0x473640 0x838578 0 -
135 glue 0x471a20 CreateCharacter 0x4719e0 0x8380f8 0 -
136 glue 0x471a20 CycleCharCustomization 0x471890 0x8380f8 0 -
137 glue 0x471a20 GetAvailableRaces 0x471520 0x8380f8 ? -
138 glue 0x471a20 GetCharacterCreateFacing 0x471910 0x8380f8 1 -
139 glue 0x471a20 GetClassesForRace 0x471560 0x8380f8 ? -
140 glue 0x471a20 GetFacialHairCustomization 0x471620 0x8380f8 1 -
141 glue 0x471a20 GetFactionForRace 0x471450 0x8380f8 2 -
142 glue 0x471a20 GetHairCustomization 0x4715d0 0x8380f8 1 -
143 glue 0x471a20 GetNameForRace 0x4713f0 0x8380f8 2 -
144 glue 0x471a20 GetRandomName 0x471980 0x8380f8 1 -
145 glue 0x471a20 GetSelectedClass 0x4716e0 0x8380f8 2 -
146 glue 0x471a20 GetSelectedRace 0x471680 0x8380f8 1 -
147 glue 0x471a20 GetSelectedSex 0x4716b0 0x8380f8 1 -
148 glue 0x471a20 HasCharCustomization 0x471820 0x8380f8 1 -
149 glue 0x471a20 RandomizeCharCustomization 0x471900 0x8380f8 0 -
150 glue 0x471a20 ResetCharCustomize 0x4713e0 0x8380f8 0 -
151 glue 0x471a20 SetCharCustomizeBackground 0x4713a0 0x8380f8 0 -
152 glue 0x471a20 SetCharCustomizeFrame 0x471330 0x8380f8 0 -
153 glue 0x471a20 SetCharacterCreateFacing 0x471930 0x8380f8 1 -
154 glue 0x471a20 SetSelectedClass 0x4717c0 0x8380f8 0 -
155 glue 0x471a20 SetSelectedRace 0x471740 0x8380f8 0 -
156 glue 0x471a20 SetSelectedSex 0x471780 0x8380f8 0 -
157 glue 0x471a20 UpdateCustomizationBackground 0x471800 0x8380f8 0 -
158 glue 0x471a20 UpdateCustomizationScene 0x471810 0x8380f8 0 -
159 glue 0x46f480 CancelRealmListQuery 0x46ed10 0x837ea0 0 -
160 glue 0x46f480 ChangeRealm 0x46f0e0 0x837ea0 0 -
161 glue 0x46f480 GetNumRealms 0x46ed30 0x837ea0 1 -
162 glue 0x46f480 GetRealmCategories 0x46f1f0 0x837ea0 ? -
163 glue 0x46f480 GetRealmInfo 0x46ee40 0x837ea0 8 -
164 glue 0x46f480 GetSelectedCategory 0x46f400 0x837ea0 1 -
165 glue 0x46f480 RealmListDialogCancelled 0x46ed20 0x837ea0 0 -
166 glue 0x46f480 RequestRealmList 0x46ecf0 0x837ea0 0 -
167 glue 0x46f480 SetPreferredInfo 0x46f2c0 0x837ea0 0 -
168 glue 0x46f480 SortRealms 0x46f330 0x837ea0 0 -
169 shared 0x4587f0 PlayMusic 0x458720 0x835a50 0 -
170 shared 0x4587f0 PlaySound 0x4586d0 0x835a50 0 -
171 shared 0x4587f0 PlaySoundFile 0x458780 0x835a50 1 -
172 shared 0x4587f0 StopMusic 0x458770 0x835a50 0 -
173 base 0x7039e0 foreach 0x7fb590 0x822d40 0|1 -
174 base 0x7039e0 foreachi 0x7fb4e0 0x822d40 0|1 -
175 base 0x7039e0 getn 0x7fb630 0x822d40 1 -
176 base 0x7039e0 tinsert 0x7fb6b0 0x822d40 0 -
177 base 0x7039e0 tremove 0x7fb770 0x822d40 0|1 -
178 base 0x7039e0 sort 0x7fb920 0x822d40 0 -
179 base 0x7039e0 abs 0x7fade0 0x822c60 1 -
180 base 0x7039e0 acos lua - ? -
181 base 0x7039e0 asin lua - ? -
182 base 0x7039e0 atan lua - ? -
183 base 0x7039e0 atan2 lua - ? -
184 base 0x7039e0 ceil 0x7faf70 0x822c60 1 -
185 base 0x7039e0 cos lua - ? -
186 base 0x7039e0 deg 0x7fb140 0x822c60 1 -
187 base 0x7039e0 exp 0x7fb100 0x822c60 1 -
188 base 0x7039e0 floor 0x7fafa0 0x822c60 1 -
189 base 0x7039e0 frexp 0x7fb1a0 0x822c60 2 -
190 base 0x7039e0 ldexp 0x7fb1f0 0x822c60 1 -
191 base 0x7039e0 log 0x7fb0a0 0x822c60 1 -
192 base 0x7039e0 log10 0x7fb0d0 0x822c60 1 -
193 base 0x7039e0 max 0x7fb2a0 0x822c60 1 -
194 base 0x7039e0 min 0x7fb230 0x822c60 1 -
195 base 0x7039e0 mod 0x7fafd0 0x822c60 1 -
196 base 0x7039e0 rad 0x7fb170 0x822c60 1 -
197 base 0x7039e0 random 0x7fb310 0x822c60 1 -
198 base 0x7039e0 randomseed 0x7fb450 0x822c60 0 -
199 base 0x7039e0 sin lua - ? -
200 base 0x7039e0 sqrt 0x7fb020 0x822c60 1 -
201 base 0x7039e0 tan lua - ? -
202 base 0x7039e0 strbyte 0x7fc210 0x822d88 0|1 -
203 base 0x7039e0 strchar 0x7fc280 0x822d88 1 -
204 base 0x7039e0 strfind 0x7fc3b0 0x822d88 ? -
205 base 0x7039e0 format 0x7fd3d0 0x822d88 1 -
206 base 0x7039e0 gsub 0x7fd0e0 0x822d88 2 -
207 base 0x7039e0 strlen 0x7fbcf0 0x822d88 1 -
208 base 0x7039e0 strlower 0x7fbdf0 0x822d88 1 -
209 base 0x7039e0 strrep 0x7fc1a0 0x822d88 1 -
210 base 0x7039e0 strsub 0x7fbd30 0x822d88 1 -
211 base 0x7039e0 strupper 0x7fc0c0 0x822d88 1 -
212 base 0x7039e0 __pow 0x7fb050 - 1 -
+21
View File
@@ -81,3 +81,24 @@ Reading it: `crates/benilla-app/src/ui_script/verb_event_gate.rs` is the gate. F
verb benilla registers, the module that registers the verb fires the event, or the pair is declared
there: `ELSEWHERE` (a feed fires it on the state the verb changes, and the named file is checked
too) or `GAP` (nothing does, with the reason).
## `1.12-glue-events.tsv` and `1.12-glue-surface.tsv`
The glue screens' own FrameScript state. The glue builder (`0x46a7b0`) gives Lua a different
surface and a different event table from the in-game state's, and GlueXML runs against those.
`1.12-glue-events.tsv` is the 26-entry event table (`0xb41e70`) the builder loads in place of the
in-game one (`0x703d90` at `0x46a88f`), so a glue event's id names a different event in-game. It is
vendored from the client's bytes, as `1.12-event-catalog.tsv` is.
`1.12-glue-surface.tsv` is every function in the glue state's `_G` before GlueXML loads: the base
set both states share (`0x7039e0`), the three registrars the in-game state calls too, and the four
glue-only tables, with each glue verb's in-game namesake and the six whose shape differs from it.
Regenerating: `scripts/gen-reference-glue-surface.py`, from the shapes and globals tables, so it
reproduces the committed file from any clone.
Reading them: `crates/benilla-ui/src/script/tests/glue_surface.rs` holds the surface table to the
shapes table, row for row by `table_va`, and the glue VM (`UiScript::new_glue`) to the surface table:
every function it exposes is a glue-state one, and every glue-state function it lacks is on the
file's `NOT_YET` list, which only shrinks. The same file holds the VM's event table to
`1.12-glue-events.tsv`.