mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-22 23:30:14 +00:00
Add Tier 2 utility commands: helm/cloak toggles, follow, and assist
Display Toggle Commands: - Add /helm, /helmet, /showhelm to toggle helm visibility - Add /cloak, /showcloak to toggle cloak visibility - Track visibility state with helmVisible_ and cloakVisible_ flags - Show confirmation messages: "Helm/Cloak is now visible/hidden" - Use CMSG_SHOWING_HELM (0x2B9) and CMSG_SHOWING_CLOAK (0x2BA) Follow Command: - Add /follow and /f to follow current target - Works with both players and NPCs - Show "Now following [Name]" confirmation message - Track follow target with followTargetGuid_ for future movement logic Assist Command: - Add /assist to target what your current target is targeting - Read target's target from UNIT_FIELD_TARGET update fields (offset 6-7) - Reconstruct 64-bit target GUID from two 32-bit field values - Automatically switch your target to assist target - Show helpful messages: "[Name] has no target" when appropriate - Essential for combat coordination in groups Implementation: - Add ShowingHelmPacket and ShowingCloakPacket builders - Add toggleHelm() and toggleCloak() methods with state management - Add followTarget() for setting follow target - Add assistTarget() with smart target field reading - Use Entity::getFields() to access protected update fields - Handle missing targets and invalid states gracefully - All commands provide chat feedback - Support multiple aliases for user convenience
This commit is contained in:
parent
ec32286b0d
commit
acef7ccbec
6 changed files with 198 additions and 0 deletions
|
|
@ -786,6 +786,22 @@ public:
|
|||
static network::Packet build(uint8_t state);
|
||||
};
|
||||
|
||||
// ============================================================
|
||||
// Display Toggles
|
||||
// ============================================================
|
||||
|
||||
/** CMSG_SHOWING_HELM packet builder */
|
||||
class ShowingHelmPacket {
|
||||
public:
|
||||
static network::Packet build(bool show);
|
||||
};
|
||||
|
||||
/** CMSG_SHOWING_CLOAK packet builder */
|
||||
class ShowingCloakPacket {
|
||||
public:
|
||||
static network::Packet build(bool show);
|
||||
};
|
||||
|
||||
// ============================================================
|
||||
// Random Roll
|
||||
// ============================================================
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue