feat(ui): port retail selected-item mana
Parse and route the complete 0x0264 guid/fraction/valid response, send exact 0x0263 item-mana queries, and reproduce retail meter visibility plus guid-zero cancellation for mana and health selection changes. Keep the behavior in Core state and the retained selected-object controller with wire/state/UI conformance coverage. Co-Authored-By: Codex <codex@openai.com>
This commit is contained in:
parent
df460f94c3
commit
fa1da02783
21 changed files with 402 additions and 38 deletions
|
|
@ -41,6 +41,7 @@ public sealed record ToolbarRuntimeBindings(
|
|||
Func<ItemType, uint, uint, uint, uint, uint> ResolveIcon,
|
||||
Action<uint> UseItem,
|
||||
CombatState Combat,
|
||||
ItemManaState ItemMana,
|
||||
Action ToggleCombat,
|
||||
ItemInteractionController ItemInteraction,
|
||||
Action<ShortcutEntry>? SendAddShortcut,
|
||||
|
|
@ -54,6 +55,7 @@ public sealed record ToolbarRuntimeBindings(
|
|||
Func<uint, bool> HasHealth,
|
||||
Func<uint, uint> StackSize,
|
||||
Action<uint> SendQueryHealth,
|
||||
Action<uint> SendQueryItemMana,
|
||||
Func<uint> PlayerGuid,
|
||||
Action<uint, uint, int>? SendPutItemInContainer);
|
||||
|
||||
|
|
@ -380,12 +382,17 @@ public sealed class RetailUiRuntime : IDisposable
|
|||
b.Selection,
|
||||
b.SubscribeHealthChanged,
|
||||
b.UnsubscribeHealthChanged,
|
||||
handler => b.ItemMana.ItemManaChanged += handler,
|
||||
handler => b.ItemMana.ItemManaChanged -= handler,
|
||||
b.IsHealthTarget,
|
||||
b.ItemInteraction.IsOwnedByPlayer,
|
||||
b.ResolveName,
|
||||
b.HealthPercent,
|
||||
b.HasHealth,
|
||||
b.StackSize,
|
||||
b.SendQueryHealth,
|
||||
b.ItemMana.GetManaPercent,
|
||||
b.SendQueryItemMana,
|
||||
_bindings.Assets.DefaultFont,
|
||||
StackSplitQuantity,
|
||||
handler => b.Objects.ObjectUpdated += handler,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue