Files
benilla-octo/crates/benilla-app/assets/ui/Cooldown.xml
T
SamandClaude Fable 5 67315143f9 the bag windows are the real 1.12 files, and /walk actually walks
- the bag windows are the reference's own `ContainerFrame.xml` running off the player's patch chain — decision 1751 makes the stock 1.12 UI off the install the end state and `assets/ui` scaffolding that retires file-by-file (86 files against the 99-file stock corpus, 72% of the 1128-function global surface already built) — via one ordered manifest, `benilla.toc`, where a bare name is a file we ship and an `Interface\FrameXML\` path is the player's own file; the windows on screen are `ContainerFrame1..12`, the bank's six copy-pasted popouts fold into them at ids 5..10, net −750 lines, and the swap forced real engine verbs into being rather than stubs (`SetBagPortaitTexture` with its id-0 no-texture arm, `GameTooltip:AppendText`, `SetButtonPulse`, and a `<Model>` whose file is the cooldown indicator materializing as the native sweep, which three corpus addons inherit)
- the 1.12 walk toggle lands: `TOGGLERUN` latches one bit with `ToggleRun`'s own silent refusal chain (dead, rooted, on a live server spline), and the walk animation was never missing at all — the flag reaches it through exactly one channel, the speed (`0x5fd100` picks Walk over Run on `speed > 2 × walkSpeed`); pinning it caught our remote extrapolator with the two min rungs backwards — `min(walk, run)` runs BEFORE the backward min, so a walking backpedaller moves at 2.5 yd/s where we would have played them the Run clip at 4.5 — and one shared `current_speed` now keeps the local controller and the extrapolator from ever disagreeing about it
- the instance and raid lockout messages exist — six packets that were dropped as unknown opcodes now land, four of them as the CHAT_MSG_SYSTEM lines the client composes itself, which is why no Lua handler ever surfaced them — plus `IsInInstance`, `ResetInstances`, and the unit popup's "Reset all instances" row behind the reference's own predicate; where the binary contradicts vmangos: the ownership flag means "any instance bind" but vmangos only ever names raid binds, so the row was dead for every character without a raid lockout — term 1 is now also satisfied by our own eyes, walking out of a party dungeon the server itself bound us to
- opening the world map showed 3D world at the sheet's margins: `BlackoutWorld` was parented to the very `UIParent` a fullscreen panel hides, and three more frames had crossed the same boundary — the shared dropdown lists (so the map's continent and zone pickers answered a click with nothing at all), the master-looter menu, and the screenshot confirmation, which could never appear during a cinematic; `frame_flag_gate` now checks the parent seat against the reference both ways a frame acquires one (the attribute, template-inherited included, and `<Frames>` nesting), and its first harvest took 30 divergences down to three accepted ones

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-31 20:17:25 +07:00

68 lines
4.2 KiB
XML

<Ui>
<!--
The shared cooldown-frame machine — the ref's own file split (Cooldown.lua/Cooldown.xml,
loaded before every consumer): CooldownFrame_SetTimer drives BOTH the action buttons
(ActionBar.xml) and the bag slots (BagFrame.xml), exactly as the reference shares it.
The ref's OnUpdateModel scrub/finish-flash machine lives inside our native <Cooldown>
widget instead (decision 0263), armed by SetCooldown.
`CooldownFrameTemplate` below is the reference's own declaration, and it is here because
it was MISSING: three corpus addons name it in an XML `inherits=` (Bagnon_Core,
Bongos_ActionBar, BuffCheck2), and Bagnon hangs one off EVERY item button, so a single
session logged roughly sixty
WARN ui_script: unknown template 'CooldownFrameTemplate' referenced by inherits
lines while each of those children came out as a bare, attribute-less frame.
-->
<Script><![CDATA[
-- Ref Cooldown.lua's CooldownFrame_SetTimer, re-expressed: show-and-arm only when all three
-- are positive, else hide.
--
-- THE ONE FORK, and why it is two faithful branches rather than a guard. The reference's
-- body arms a Model (`this.start = start … this:SetSequence(0)`); ours arms our native
-- <Cooldown> widget, which is where 0263 put that machine.
--
-- **Since decision 1751 the fork is almost never taken, and that is the fix.** The loader
-- now materializes a `<Model>` whose file IS the cooldown indicator as a real `<Cooldown>`
-- (`loader::frame_kind_of`) — the file is the thing's identity, and this engine draws that
-- sweep natively. So `<Model … inherits="CooldownFrameTemplate"/>`, which is what every
-- real caller writes (the reference's own ContainerFrameItemButtonTemplate, its action
-- buttons, three corpus addons), arrives here as a Cooldown and sweeps.
--
-- The `if this.SetCooldown` guard stays for the case that remains: a Model built with
-- some OTHER file, or a plain frame handed in by an addon. Calling SetCooldown
-- unconditionally is what shipped, and it raised on exactly that: a Bagnon slot holding an
-- item with a live cooldown died on `attempt to call method 'SetCooldown' (a nil value)`
-- — and, because !OmniCC wraps this very function, it took OmniCC's countdown down with
-- it. That branch shows and hides the frame and nothing more, which is a missing visual,
-- not a broken window.
function CooldownFrame_SetTimer(this, start, duration, enable)
if ( start > 0 and duration > 0 and enable > 0 ) then
if ( this.SetCooldown ) then
this:SetCooldown(start, duration)
end
this:Show()
else
this:Hide()
end
end
]]></Script>
<!--
ref Cooldown.xml l.4-14. The reference's own attributes are kept verbatim (its .mdx file,
its 0.75 scale, setAllPoints, hidden) — and the `file=` is no longer decoration: since
decision 1751 it is what the loader reads to know that an inheriting `<Model>` is really
this engine's `<Cooldown>` widget (`loader::frame_kind_of`). The template's other job is
unchanged: to exist under the reference's name so an addon's `inherits=` resolves and its
cooldown child inherits the geometry the addon is counting on.
Its two `<Scripts>` — OnUpdateModel / OnAnimFinished — are deliberately NOT transcribed.
Both are real 1.12 script slots that this engine does not fire (see
`benilla-ui/src/script/object/events_regions.rs`, which raises on any name nothing fires,
and measured both at zero corpus call sites), so declaring them would trade sixty
`unknown template` warnings for sixty `SetScript unsupported` ones and change nothing else.
The scrub they drive is our <Cooldown> widget's, not this frame's.
-->
<Model name="CooldownFrameTemplate" file="Interface\Cooldown\UI-Cooldown-Indicator.mdx"
scale="0.75" setAllPoints="true" hidden="true" virtual="true"/>
</Ui>