From f0d1bacf0aa6e37257c30ff7c5171741111fc33a Mon Sep 17 00:00:00 2001 From: Sam Date: Fri, 4 Sep 2026 20:50:36 +0700 Subject: [PATCH] the help window is the reference's own, and a ding carries nine gains MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - the help window is the reference's own `HelpFrame.xml`, and ours was less than half its size, so this is mostly arrival: the category list, the per-category GM and harassment pages, the stuck page, the bug report, the PvP policy line; four things we had built go with the swap — one-click filing from Home, the Home unstick button, the downed-queue refusal message, and ticket abandonment, a capability loss rather than a look change, since `AbandonTicket` exists in neither the binding table nor the 1.12 FrameXML corpus and any return of it goes on top of the stock window; `GMSURVEY_DISPLAY` arrives with no producer, a real 1.12 event (`SignalEvent` `0x5e797b`) whose whole UI is a LoadOnDemand addon not on our chain; and the stock file needs two orderings ours did not, the micro-button row before its GM status ask and the buff frame before its repoll timer (1889, superseding 1687) - the cast bar, the action-button regions and the font registry are the reference's own files too: our `CastingBar.xml` was `CastingBarFrame.xml` under another name, with the literal "Failed" where the reference reads the `FAILED` GlobalString (1886); `ActionButtonTemplate.xml` seats above our `ActionBar.xml` because the later-registered template wins, and it declares zero scripts, so the regions migrate while the handlers stay ours until `ActionButton.lua`'s verbs do (1887); `Fonts.xml` is manifest entry 0, all 51 fonts match by name, and its one real difference, `ITEM_QUALITY_COLORS`, moves to UIParent where the reference declares it (1888); the harnesses were the real cost — those reading our files off disk could not name a chain file and now read through the manifest's own rule — and the event-producer gate, having cried wolf at the cast bar's `SPELLCAST_INTERRUPTED` fired through a variable, now matches the fired tuple's shape - of the 189 events benilla fires, three are not in the client — `BAG_UPDATE_DELAYED` (a Classic Era name), `LOOT_UPDATE` and `UPDATE_LOOT_ROLL` (invented here, no listener anywhere) — found against the reference binary's own string table, and a gate now fails any fire of a name the client cannot dispatch unless it wears a `BENILLA_` prefix (1883); two payloads the reference gives that we did not: `UNIT_HAPPINESS` carries its unit token, without which no `UNIT_*` consumer reads it, and `CHARACTER_POINTS_CHANGED` carries the point deltas `ChatFrame.lua` compares unguarded, so nil raised (1884); and `PLAYER_LEVEL_UP` carries all nine — level, health and mana gain, talent points (not on the wire: the client derives `(newLevel >= 10) ? 1 : 0` at `0x5e407c`) and the five stat gains — matched to the ding by level, a demotion's absent gains sent as zeros since a nil raises where a zero reads as no line - the chain gap report could not run — one of its six probes had no player seated where a stock addon formats `UnitName("player")` at load, the other five each carrying an identical copy-pasted seed — and the repaired instrument prices each window's cost: 13 stock files load clean with nothing missing (the action bars, the cast bar, the fonts, the help, friends, game-menu and sound-options windows among them) and the near ones name their missing verb, with "loads clean" still not "swapped" (1885); and `UpdateNameplates`, recorded as the missing engine verb blocking the UIParent keystone, is FrameXML — defined in `UIOptionsFrame.lua`, absent from the binding table, its whole body four nameplate verbs that are already ours — so it is twelve lines transcribed into our options frame, the reference's own Show-then-Hide no-op included (1890 corrects 1878) Co-Authored-By: Claude Fable 5.1 --- crates/benilla-app/assets/ui/ActionBar.xml | 69 +- crates/benilla-app/assets/ui/CastingBar.xml | 294 ----- crates/benilla-app/assets/ui/Fonts.xml | 397 ------- crates/benilla-app/assets/ui/HelpFrame.xml | 1017 ----------------- crates/benilla-app/assets/ui/OptionsFrame.xml | 33 + crates/benilla-app/assets/ui/UIParent.xml | 44 + crates/benilla-app/assets/ui/benilla.toc | 41 +- .../benilla-app/src/net/apply/combat_log.rs | 4 + .../benilla-app/src/ui_action/feed_tests.rs | 5 +- crates/benilla-app/src/ui_chat/feed.rs | 24 + crates/benilla-app/src/ui_chat/tests.rs | 37 +- crates/benilla-app/src/ui_items/drain.rs | 18 +- crates/benilla-app/src/ui_items/feed.rs | 1 - crates/benilla-app/src/ui_loot.rs | 9 +- crates/benilla-app/src/ui_loot_roll.rs | 109 +- crates/benilla-app/src/ui_pet_stats.rs | 7 +- .../src/ui_script/action_bar_tests.rs | 104 +- .../src/ui_script/basic_controls_tests.rs | 2 +- .../benilla-app/src/ui_script/binder_tests.rs | 2 +- .../benilla-app/src/ui_script/buff_tests.rs | 9 +- .../benilla-app/src/ui_script/cast_tests.rs | 12 +- .../src/ui_script/character_tests.rs | 2 +- .../src/ui_script/chat_options_tests.rs | 2 +- .../src/ui_script/chat_resize_tests.rs | 2 +- .../benilla-app/src/ui_script/chat_tests.rs | 6 +- .../src/ui_script/cinematic_tests.rs | 2 +- .../src/ui_script/color_picker_tests.rs | 2 +- .../src/ui_script/combat_text_tests.rs | 2 +- .../src/ui_script/combo_frame_tests.rs | 2 +- .../benilla-app/src/ui_script/death_tests.rs | 2 +- .../src/ui_script/delete_item_tests.rs | 2 +- .../src/ui_script/dressup_tests.rs | 2 +- .../src/ui_script/dropdown_tests.rs | 2 +- .../benilla-app/src/ui_script/duel_tests.rs | 2 +- .../src/ui_script/durability_tests.rs | 4 +- .../src/ui_script/enchant_confirm_tests.rs | 2 +- .../benilla-app/src/ui_script/errors_tests.rs | 4 +- .../benilla-app/src/ui_script/escape_tests.rs | 4 +- .../src/ui_script/exp_bar_tests.rs | 3 +- .../src/ui_script/faux_scroll_tests.rs | 4 +- .../src/ui_script/friends_tests.rs | 3 +- .../src/ui_script/game_menu_tests.rs | 8 +- .../src/ui_script/group_loot_tests.rs | 24 +- .../benilla-app/src/ui_script/guild_tests.rs | 3 +- .../src/ui_script/help_frame_tests.rs | 295 +---- .../src/ui_script/honor_frame_tests.rs | 2 +- .../src/ui_script/inspect_tests.rs | 4 +- .../src/ui_script/instance_tests.rs | 2 +- .../src/ui_script/keybindings_tests.rs | 2 +- .../benilla-app/src/ui_script/macro_tests.rs | 2 +- crates/benilla-app/src/ui_script/manifest.rs | 2 +- .../src/ui_script/micro_menu_tests.rs | 19 +- .../src/ui_script/minimap_tests.rs | 10 +- .../src/ui_script/mirror_timer_tests.rs | 2 +- .../src/ui_script/money_frame_tests.rs | 4 +- .../src/ui_script/multibar_stance_tests.rs | 8 +- .../src/ui_script/options_tests.rs | 10 +- .../src/ui_script/panel_template_tests.rs | 2 +- .../benilla-app/src/ui_script/panel_tests.rs | 2 +- .../src/ui_script/perf_bar_tests.rs | 3 +- .../src/ui_script/pet_bar_tests.rs | 13 +- .../src/ui_script/pet_frame_tests.rs | 2 +- .../src/ui_script/petition_tests.rs | 2 +- .../src/ui_script/quest_share_tests.rs | 2 +- .../benilla-app/src/ui_script/quest_tests.rs | 20 +- .../src/ui_script/quest_timer_tests.rs | 2 +- .../src/ui_script/questlog_tests.rs | 38 +- .../benilla-app/src/ui_script/raid_tests.rs | 2 +- .../benilla-app/src/ui_script/reference_ui.rs | 242 ++-- .../src/ui_script/screenshot_tests.rs | 2 +- .../src/ui_script/shipped_xml_tests.rs | 42 +- .../src/ui_script/spellbook_tests.rs | 16 +- .../src/ui_script/static_popup_tests.rs | 2 +- .../benilla-app/src/ui_script/summon_tests.rs | 2 +- .../src/ui_script/talent_wipe_tests.rs | 2 +- .../src/ui_script/target_aura_tests.rs | 7 +- .../benilla-app/src/ui_script/taxi_tests.rs | 2 +- crates/benilla-app/src/ui_script/test_ui.rs | 17 +- .../src/ui_script/tooltip_anchor_tests.rs | 23 +- .../src/ui_script/tooltip_template_tests.rs | 6 +- .../src/ui_script/tot_frame_tests.rs | 3 +- .../src/ui_script/trainer_tests.rs | 2 +- .../src/ui_script/uiparent_tests.rs | 32 +- .../src/ui_script/unit_frame_tests.rs | 8 +- .../src/ui_script/unit_popup_tests.rs | 5 +- .../src/ui_script/world_map_tests.rs | 2 +- .../src/ui_script/world_state_tests.rs | 2 +- .../src/ui_script/zone_text_tests.rs | 2 +- crates/benilla-app/src/ui_talent.rs | 25 +- crates/benilla-app/src/ui_unit.rs | 43 +- crates/benilla-app/tests/auction_frame.rs | 7 +- crates/benilla-app/tests/character_stats.rs | 2 +- .../tests/create_frame_template.rs | 2 +- crates/benilla-app/tests/item_text_frame.rs | 2 +- crates/benilla-app/tests/mail_frame.rs | 2 +- crates/benilla-app/tests/talent_frame.rs | 2 +- crates/benilla-app/tests/trade_frame.rs | 2 +- crates/benilla-app/tests/tradeskill_frame.rs | 2 +- 98 files changed, 755 insertions(+), 2530 deletions(-) delete mode 100644 crates/benilla-app/assets/ui/CastingBar.xml delete mode 100644 crates/benilla-app/assets/ui/Fonts.xml delete mode 100644 crates/benilla-app/assets/ui/HelpFrame.xml diff --git a/crates/benilla-app/assets/ui/ActionBar.xml b/crates/benilla-app/assets/ui/ActionBar.xml index d27416c2..bd210cb5 100644 --- a/crates/benilla-app/assets/ui/ActionBar.xml +++ b/crates/benilla-app/assets/ui/ActionBar.xml @@ -1482,9 +1482,12 @@ does (decision 1636). --> - - - - - - - - - - - - - - - - - - - - - - - - - - - ActionButton_OnEvent() diff --git a/crates/benilla-app/assets/ui/CastingBar.xml b/crates/benilla-app/assets/ui/CastingBar.xml deleted file mode 100644 index 954627a2..00000000 --- a/crates/benilla-app/assets/ui/CastingBar.xml +++ /dev/null @@ -1,294 +0,0 @@ - - - - - - diff --git a/crates/benilla-app/assets/ui/Fonts.xml b/crates/benilla-app/assets/ui/Fonts.xml deleted file mode 100644 index 1996af64..00000000 --- a/crates/benilla-app/assets/ui/Fonts.xml +++ /dev/null @@ -1,397 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/crates/benilla-app/assets/ui/HelpFrame.xml b/crates/benilla-app/assets/ui/HelpFrame.xml deleted file mode 100644 index 7bdb7415..00000000 --- a/crates/benilla-app/assets/ui/HelpFrame.xml +++ /dev/null @@ -1,1017 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - HelpFrameButton_FitToText(HelpFrameHomeIssues) - HelpFrameButton_FitToText(BenillaHelpFrameHomeUnstick) - - - - - - - - - - - - - - - - - - - - - - - - - - - ScrollFrame_OnLoad() - local trough = getglobal(self:GetName() .. "ScrollBarTrough") - BenillaScrollTrough_Seat(trough, getglobal(self:GetName() .. "ScrollBar")) - trough:Show() - - - - - - - - ScrollingEdit_OnTextChanged() - ScrollingEdit_OnCursorChanged(arg1, arg2, arg3, arg4) - HideUIPanel(HelpFrame) - - - - - - - - - - - - self:RegisterEvent("UPDATE_TICKET") - self:RegisterEvent("GMSURVEY_DISPLAY") - - HelpFrameOpenTicket_OnEvent(event) - - - - - - - HelpFrame_OnLoad(self) - HelpFrame_OnShow(self) - HelpFrame_OnEvent() - - PlaySound("igCharacterInfoClose") - if UpdateMicroButtons then UpdateMicroButtons() end - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - if TOOLTIP_DEFAULT_COLOR then - self:SetBackdropBorderColor(TOOLTIP_DEFAULT_COLOR.r, TOOLTIP_DEFAULT_COLOR.g, TOOLTIP_DEFAULT_COLOR.b) - end - if TOOLTIP_DEFAULT_BACKGROUND_COLOR then - self:SetBackdropColor(TOOLTIP_DEFAULT_BACKGROUND_COLOR.r, TOOLTIP_DEFAULT_BACKGROUND_COLOR.g, TOOLTIP_DEFAULT_BACKGROUND_COLOR.b) - end - self:RegisterEvent("UPDATE_TICKET") - self:RegisterEvent("PLAYER_ENTERING_WORLD") - - TicketStatusFrame_OnEvent(self) - TicketStatus_OnUpdate(arg1) - - TicketStatus_OnClick() - - - diff --git a/crates/benilla-app/assets/ui/OptionsFrame.xml b/crates/benilla-app/assets/ui/OptionsFrame.xml index 34096572..7aa4871e 100644 --- a/crates/benilla-app/assets/ui/OptionsFrame.xml +++ b/crates/benilla-app/assets/ui/OptionsFrame.xml @@ -240,6 +240,39 @@ -- reference at typical resolutions reads nearer two-thirds. ERA_WINDOW_SCALE = 0.78 + -- ── UpdateNameplates (ref UIOptionsFrame.lua l.768-780, verbatim) ──────────────────── + -- Its reference home is `UIOptionsFrame.lua` and this file is our stand-in for that window + -- (0950/0992), so the function belongs here rather than beside its caller. + -- + -- **Decision 1878 recorded this as "a missing ENGINE verb, and 1203 says build it or leave + -- it loudly absent", and named it the thing blocking the UIParent keystone. It is neither.** + -- It is FrameXML — `UIOptionsFrame.lua:768`, absent from wow-re's binding-shape table — and + -- every verb it calls is already ours: `ShowNameplates`/`HideNameplates`/ + -- `ShowFriendNameplates`/`HideFriendNameplates` are the four CVar-backed bindings in + -- `script/cvars.rs`, all argc=0 arity=0, matching the reference's shapes. + -- + -- `NAMEPLATES_ON`/`FRIENDNAMEPLATES_ON` are `RegisterForSave` globals the reference drives + -- from the keybinding alone (1.12's own options UI has no nameplate row). Nil is a normal + -- state for them and the else-branches are the reference's own answer to it, so this needs + -- no seeding — which is why the whole thing is twelve lines rather than a build. + -- + -- The reference's odd second arm is kept as it stands: on FRIENDNAMEPLATES_ON it calls + -- Show and then Hide, which is a no-op in the real client too. Transcribed, not corrected; + -- fixing a reference bug here would be inventing a difference. + function UpdateNameplates() + if ( NAMEPLATES_ON ) then + ShowNameplates() + else + HideNameplates() + end + if ( FRIENDNAMEPLATES_ON ) then + ShowFriendNameplates() + HideFriendNameplates() + else + HideFriendNameplates() + end + end + function OptionsFrame_UpdateScale() -- The era panel is registered `checkFit = 1`: the panel manager also shrinks it to -- fit a small screen (UIPanelUpdateScaleForFit: min over width/height ratios diff --git a/crates/benilla-app/assets/ui/UIParent.xml b/crates/benilla-app/assets/ui/UIParent.xml index 572a53de..7d9d9705 100644 --- a/crates/benilla-app/assets/ui/UIParent.xml +++ b/crates/benilla-app/assets/ui/UIParent.xml @@ -215,6 +215,40 @@ -- statements on the same event). `MultiActionBar_Update` is existence-guarded because the -- ~25 per-window harnesses that load this file load no bars; the binding itself is engine -- level and always installed. Decision 1500. + -- ── ITEM_QUALITY_COLORS (ref UIParent.lua l.65-72) ─────────────────────────────── + -- Its reference home is THIS file. It lived in our own `Fonts.xml` until 1888 put + -- that file on the chain — the reference's `Fonts.xml` does not declare it, so the + -- table had to come back here or vanish. Every reader is below UIParent.xml in the + -- manifest (GameTooltip 169, UnitPopup 203, AuctionFrame 928; UnitPopup's is a + -- FILE-SCOPE read inside a table literal, which is the one that makes the order + -- load-bearing rather than incidental). + -- The item-quality palette — **built from the engine verb, exactly as the reference + -- builds it** (ref UIParent.lua l.65-72, verbatim shape; decision 1199): + -- + -- ITEM_QUALITY_COLORS = { } + -- for i = -1, 6 do … = GetItemQualityColor(i) end + -- + -- It used to be seven hand-typed rows here. They were CLOSE and not exact — 0.62 where + -- the client's byte is 0x9d/255 = 0.6157, 0.64/0.21/0.93 where Epic is + -- 0xa3/0x35/0xee — and they carried no `.hex`, which the reference's table has and + -- which addons splice straight into a chat link. `GetItemQualityColor` is now a real + -- engine binding over wow-5875-re RF-0055's byte-verified table, so the rounding and + -- the second source both go. + -- + -- The loop starts at -1 like the reference's, and the -1 row is not a curiosity: it is the + -- colour a loot row wears while its item template is uncached, which is the value + -- `GetLootSlotInfo` answers there. `GetItemQualityColor`'s clamp is UNSIGNED, so -1 lands + -- on Common/white with 7-and-up (decision 1805, correcting 1199's "reads before the + -- array"). + ITEM_QUALITY_COLORS = { } + for i = -1, 6 do + ITEM_QUALITY_COLORS[i] = { } + ITEM_QUALITY_COLORS[i].r, + ITEM_QUALITY_COLORS[i].g, + ITEM_QUALITY_COLORS[i].b, + ITEM_QUALITY_COLORS[i].hex = GetItemQualityColor(i) + end + -- ── UIParentLoadAddOn (ref UIParent.lua l.638-647, and now our slot for it) ────── -- It lived in our own BasicControls.xml until 1881 migrated that file to the chain; -- the reference never put it there, so the move is back to where it belongs. @@ -285,6 +319,16 @@ end end + -- ref UIParent.lua l.194-196, verbatim — the fifth squatter, and the smallest. Stock + -- `HelpFrame.xml` calls it when a GM survey is waiting (its l.1487), and its whole body is + -- `UIParentLoadAddOn("Blizzard_GMSurveyUI")` — a verb 1881 already moved here and an addon + -- that really is on the player's chain (patch-2.MPQ). So this is the reference's own + -- function, not a stand-in: 1889 needed it because the stock help window is on the chain + -- now and ours is gone. + function GMSurveyFrame_LoadUI() + UIParentLoadAddOn("Blizzard_GMSurveyUI") + end + -- ref UIParent.lua's own `ShowMacroFrame`, moved here from our MacroFrame.xml when 1848 -- retired that file — the third such squatter after `InspectUnit` (1832) and -- `ToggleTalentFrame` (1833), and by now the expected shape. diff --git a/crates/benilla-app/assets/ui/benilla.toc b/crates/benilla-app/assets/ui/benilla.toc index b7edb5fc..4a59df41 100644 --- a/crates/benilla-app/assets/ui/benilla.toc +++ b/crates/benilla-app/assets/ui/benilla.toc @@ -38,7 +38,13 @@ # The named virtual Font objects (decision 0084) — must load first so any FontString's # `inherits="GameFontNormal"` resolves against a registered object. -Fonts.xml +# ══ THE FONT REGISTRY — the reference's own, off the player's chain (1751, 1888) ══ +# All 51 `` objects, name for name, plus the colour codes, `CHAT_FONT_HEIGHTS`, +# `MATERIAL_TEXT_COLOR_TABLE`, `MATERIAL_TITLETEXT_COLOR_TABLE` and `RAID_CLASS_COLORS`. +# Ours was a transcription differing only in formatting (it inlined ``), plus one +# addition: `ITEM_QUALITY_COLORS`, whose reference home is `UIParent.lua` and which 1888 moved +# to our UIParent.xml so it survives this swap. +Interface\FrameXML\Fonts.xml # ══ THE STRINGS — the reference's own first line, seated second here (1848) ══ # **Second, not first, and that is deliberate.** Manifest entry 0 is the FONT REGISTRY: @@ -337,6 +343,19 @@ TalentWipeConfirm.xml # The shared CooldownFrame_SetTimer (the ref's Cooldown.lua file split) — before its # consumers (ActionBar's buttons, the multibars, the stance bar, BagFrame's slots). Cooldown.xml +# ══ THE ACTION-BUTTON REGIONS — the reference's own, off the player's chain (1751) ══ +# `ActionButtonTemplate`: the REGIONS-ONLY half of the reference's two-level split — icon, count, +# hotkey, name, border, flash, cooldown and normal texture. It declares NO scripts and calls +# nothing, so it needs no `.lua` beside it. The handler half is `ActionBarButtonTemplate`, which +# ActionBar.xml still declares and which inherits this; those handlers stay ours until +# `ActionButton.lua`'s 21 verbs migrate (we have 10 of them, under the reference's own names). +# +# Ours was a transcription of this exact file — the eight `$parent*` child names match to the +# letter — so the swap is a deletion. +# +# **It must come BEFORE ActionBar.xml.** A template is registered by name and the later line +# wins, so seated below it our transcription would take the name straight back. +Interface\FrameXML\ActionButtonTemplate.xml ActionBar.xml # The four OPTIONAL extra bars (bottom left/right 61-72 / 49-60, vertical right/left # 25-36 / 37-48), all shipping hidden until the player ticks their row (decision 1500): @@ -493,9 +512,16 @@ Interface\FrameXML\ColorPickerFrame.xml # WorldMapRaid1..40 with inherits=, so the virtual Frames have to be registered before it. WorldMapFrameTemplates.xml WorldMapFrame.xml -# The cast bar (decision 0137 phase 1) — the extracted 1.12 CastingBarFrame, driven by -# the SPELLCAST_* events `crate::ui_cast` fires. Only needs Fonts before it. -CastingBar.xml +# ══ THE CAST BAR — the reference's own, off the player's chain (1751) ══ +# `CastingBarFrame` + its Border/Flash/Spark/Text children, driven by the SPELLCAST_* events +# `crate::ui_cast` fires (decision 0137 phase 1). Our `CastingBar.xml` was a transcription of this +# very file under a different name — all five frame names identical — so the swap is a deletion. +# +# The file SOURCES ITS OWN LUA (`