From 1c4cc147f59577e4d70190db6826b2fd56e979e4 Mon Sep 17 00:00:00 2001 From: Sam Date: Sat, 29 Aug 2026 17:20:24 +0700 Subject: [PATCH] GM tickets are in, and a login failure shows the string 1.12 shows MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - GM tickets, end to end: five request/answer pairs, the seven Help-window bindings, three events and `GMTicketCategory.dbc` — the ten categories `HelpFrame.lua` keys 1..10 live in a DBC nothing here had ever opened (the four `TICKET_TYPE` strings feed a dropdown 1.12 never gave a frame); the category is one byte on the wire (a u32 would shift the map id and position and file every ticket at a garbage spot), and `UPDATETEXT` carries it too, which vmangos stores and cmangos swallows as the first character of the text — faithful to the client, the divergence recorded - the engine re-asks for the ticket after a create or update succeeds and on a status push (the ask opcode has three callers in the reference, two of them engine legs with no idempotence guard) — which is why the shipped FrameXML registers no handler for the three response opcodes and still repaints; without that leg the form stays a form for ten minutes; `UPDATE_GM_STATUS` is a signed passthrough (`0xFFFFFFFF` → −1), the five ticket verbs drain through one ordered queue because call order is wire order, and the Help micro button — drawn, hovering and a no-op since the micro menu landed — is live - a typed wrong password reads the reference's long "check the spelling of the account name and password" (0x04 and 0x05 share one jump-table arm — the client cannot say "wrong password", and the lockout cmangos's header describes does not exist in the binary), unknown codes read "Disconnected from server" rather than "Authentication failed", and every realmd row of the old map was in the wrong one: the two login-status enums have two key tables and two dialog paths, and a server source can only ever verify the codes, never which string the client draws for them Co-Authored-By: Claude Fable 5 --- crates/benilla-app/assets/ui/HelpFrame.xml | 1669 +++++++++++++++++ crates/benilla-app/assets/ui/MicroMenu.xml | 33 +- crates/benilla-app/assets/ui/UiPanels.xml | 18 +- crates/benilla-app/assets/ui/benilla.toc | 16 + crates/benilla-app/src/capture/mod.rs | 2 + .../src/capture/probe_gm_ticket.rs | 779 ++++++++ crates/benilla-app/src/dev.rs | 8 + crates/benilla-app/src/lib.rs | 7 + crates/benilla-app/src/login/mod.rs | 169 +- crates/benilla-app/src/net.rs | 597 ++++-- crates/benilla-app/src/net/apply.rs | 36 + crates/benilla-app/src/net/apply/session.rs | 6 + crates/benilla-app/src/net/io.rs | 12 + crates/benilla-app/src/ui_gm_ticket.rs | 611 ++++++ .../src/ui_script/help_frame_tests.rs | 400 ++++ crates/benilla-app/src/ui_script/mod.rs | 6 + .../benilla-formats/src/gm_ticket_category.rs | 143 ++ crates/benilla-formats/src/lib.rs | 4 + crates/benilla-protocol/src/events.rs | 21 +- crates/benilla-protocol/src/events/decode.rs | 16 + .../src/messages/gm_ticket.rs | 282 +++ crates/benilla-protocol/src/messages/mod.rs | 14 + .../benilla-protocol/src/messages/opcode.rs | 41 + .../benilla-protocol/src/messages/packet.rs | 41 +- crates/benilla-protocol/src/messages/parse.rs | 28 +- .../src/world/writer/gm_ticket.rs | 79 + .../benilla-protocol/src/world/writer/mod.rs | 2 + crates/benilla-ui/src/script/gm_ticket.rs | 164 ++ crates/benilla-ui/src/script/mod.rs | 3 + crates/benilla-ui/src/script/model.rs | 16 + .../benilla-ui/src/script/tests/gm_ticket.rs | 163 ++ crates/benilla-ui/src/script/tests/mod.rs | 1 + 32 files changed, 5215 insertions(+), 172 deletions(-) create mode 100644 crates/benilla-app/assets/ui/HelpFrame.xml create mode 100644 crates/benilla-app/src/capture/probe_gm_ticket.rs create mode 100644 crates/benilla-app/src/ui_gm_ticket.rs create mode 100644 crates/benilla-app/src/ui_script/help_frame_tests.rs create mode 100644 crates/benilla-formats/src/gm_ticket_category.rs create mode 100644 crates/benilla-protocol/src/messages/gm_ticket.rs create mode 100644 crates/benilla-protocol/src/world/writer/gm_ticket.rs create mode 100644 crates/benilla-ui/src/script/gm_ticket.rs create mode 100644 crates/benilla-ui/src/script/tests/gm_ticket.rs diff --git a/crates/benilla-app/assets/ui/HelpFrame.xml b/crates/benilla-app/assets/ui/HelpFrame.xml new file mode 100644 index 00000000..691cdc98 --- /dev/null +++ b/crates/benilla-app/assets/ui/HelpFrame.xml @@ -0,0 +1,1669 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + HelpFrameButton_FitToText(HelpFrameHomeIssues) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ScrollFrame_OnLoad() + self.updateFunc = HelpFrameGM_Update + + + + + + + + + HelpFrameGM_Update() + + + + + + + + + + + + + + + + + + + + + + + + + + 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) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + HelpFrameHarassment_OnLoad() + + + + + + + + + + + + + + + + + + + + + + + + + + HelpFrameButton_FitToText(HelpFrameStuckStuck) + + + + + + + + + + + + + + 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/MicroMenu.xml b/crates/benilla-app/assets/ui/MicroMenu.xml index d68cbbd8..de6fc068 100644 --- a/crates/benilla-app/assets/ui/MicroMenu.xml +++ b/crates/benilla-app/assets/ui/MicroMenu.xml @@ -29,12 +29,13 @@ bar plate doesn't paint over them. Same shape the bag bar next door already uses. SCOPE / real-client divergences (noted, not bugs): - - ONE button has no panel to open yet: Help (no HelpFrame). It is drawn, hovers, and - highlights like the rest, but its click is a no-op — the same "art only, wired the day the - panel lands" call the page up/down arrows on this same bar already make. Deliberately NOT - greyed with the ref's `-Disabled` art: a dead grey button mid-row reads as a broken bar, - and the point of this slice is that the bar reads whole. It is one OnClick line from live. - (Socials went live with decision 0668, Main Menu with 0674.) + - EVERY button now opens something. Help was the last "art only, wired the day the panel + lands" one, and HelpFrame.xml is that panel — its click is `ToggleHelpFrame()` and its + pushed arm is in UpdateMicroButtons below, exactly as the ref writes both. (Socials went + live with decision 0668, Main Menu with 0674, Help with the HelpFrame transcription.) + The bar was deliberately never greyed with the ref's `-Disabled` art while the gap + lasted: a dead grey button mid-row reads as a broken bar, and it really was one OnClick + line from live. - The "(key)" suffix is LIVE since 0997: `button.binding` carries the binding ACTION name (TOGGLECHARACTER0, TOGGLESPELLBOOK, ...) and the tooltip looks the key up through GetBindingKey at hover time — the ref MicroButtonTooltipText's own contract, restored @@ -173,15 +174,23 @@ -- ref UpdateMicroButtons (l.20-84): each button reflects whether its panel is up. The -- MainMenu arm is the ref's own six-way test (l.47-58) minus the five frames that don't -- exist here — GameMenuFrame is the one that does (decision 0674), and it is the one the - -- reference lists first. Its keyring arm has no frame here; the still-unwired Help button - -- simply never pushes. + -- reference lists first. Its keyring arm (l.79-83) still has no frame here. + -- + -- The Help arm is the ref's l.72-76, live since HelpFrame.xml landed. It calls BACK into + -- this function from its own OnShow and OnHide, which is the ref's wiring too and is why + -- the reference's HelpFrame is the one panel that does not need an event to stay in sync. function UpdateMicroButtons() BenillaMicroButton_SetPushed(CharacterMicroButton, BenillaMicro_PanelShown("CharacterFrame")) BenillaMicroButton_SetPushed(SpellbookMicroButton, BenillaMicro_PanelShown("SpellBookFrame")) BenillaMicroButton_SetPushed(TalentMicroButton, BenillaMicro_PanelShown("BenillaTalentFrame")) BenillaMicroButton_SetPushed(QuestLogMicroButton, BenillaMicro_PanelShown("QuestLogFrame")) + -- ref l.60-64. Missing since the Socials button went live with decision 0668: the + -- window opened but its button never read pushed. Spotted while wiring Help, which is + -- the same arm one line down; fixed here rather than left for a bug report. + BenillaMicroButton_SetPushed(SocialsMicroButton, BenillaMicro_PanelShown("FriendsFrame")) BenillaMicroButton_SetPushed(WorldMapMicroButton, BenillaMicro_PanelShown("WorldMapFrame")) BenillaMicroButton_SetPushed(MainMenuMicroButton, BenillaMicro_PanelShown("GameMenuFrame")) + BenillaMicroButton_SetPushed(HelpMicroButton, BenillaMicro_PanelShown("HelpFrame")) end -- ref CharacterMicroButton_SetPushed/_SetNormal (l.109-117): the portrait shifts its window @@ -358,13 +367,19 @@ - + diff --git a/crates/benilla-app/assets/ui/UiPanels.xml b/crates/benilla-app/assets/ui/UiPanels.xml index c80f9fbb..69f82084 100644 --- a/crates/benilla-app/assets/ui/UiPanels.xml +++ b/crates/benilla-app/assets/ui/UiPanels.xml @@ -26,9 +26,10 @@