diff options
| author | Shauren <shauren.trinity@gmail.com> | 2016-08-15 00:03:38 +0200 |
|---|---|---|
| committer | Shauren <shauren.trinity@gmail.com> | 2016-08-15 00:03:38 +0200 |
| commit | fea0cb16f2e73ec21891ac14cdc10d9d8f518cfe (patch) | |
| tree | 7e3a6ee9b3876ca5b3a7115a9d932ce8125c41e1 /src/server/game/Entities/Unit | |
| parent | f8c5a2c723c734513eddc98a5c7f380c2f00e479 (diff) | |
Core/Items: Implemented artifacts
Diffstat (limited to 'src/server/game/Entities/Unit')
| -rw-r--r-- | src/server/game/Entities/Unit/Unit.cpp | 6 | ||||
| -rw-r--r-- | src/server/game/Entities/Unit/Unit.h | 3 |
2 files changed, 8 insertions, 1 deletions
diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index c8cd3645721..d665225edc1 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -14214,6 +14214,12 @@ uint32 Unit::GetModelForForm(ShapeshiftForm form) const { if (GetTypeId() == TYPEID_PLAYER) { + if (Aura* artifactAura = GetAura(ARTIFACTS_ALL_WEAPONS_GENERAL_WEAPON_EQUIPPED_PASSIVE)) + if (Item* artifact = ToPlayer()->GetItemByGuid(artifactAura->GetCastItemGUID())) + if (ArtifactAppearanceEntry const* artifactAppearance = sArtifactAppearanceStore.LookupEntry(artifact->GetModifier(ITEM_MODIFIER_ARTIFACT_APPEARANCE_ID))) + if (ShapeshiftForm(artifactAppearance->ModifiesShapeshiftFormDisplay) == form) + return artifactAppearance->ShapeshiftDisplayID; + switch (form) { case FORM_CAT_FORM: diff --git a/src/server/game/Entities/Unit/Unit.h b/src/server/game/Entities/Unit/Unit.h index 246a8a09818..4847723fb9c 100644 --- a/src/server/game/Entities/Unit/Unit.h +++ b/src/server/game/Entities/Unit/Unit.h @@ -31,6 +31,7 @@ #include <boost/container/flat_set.hpp> #define WORLD_TRIGGER 12999 +#define ARTIFACTS_ALL_WEAPONS_GENERAL_WEAPON_EQUIPPED_PASSIVE 197886 enum SpellInterruptFlags { @@ -773,7 +774,7 @@ enum NPCFlags : uint64 UNIT_NPC_FLAG_SPELLCLICK = 0x0001000000, // cause client to send 1015 opcode (spell click) UNIT_NPC_FLAG_PLAYER_VEHICLE = 0x0002000000, // players with mounts that have vehicle data should have it set UNIT_NPC_FLAG_MAILBOX = 0x0004000000, // mailbox - UNIT_NPC_FLAG_REFORGER = 0x0008000000, // reforging + UNIT_NPC_FLAG_ARTIFACT_POWER_RESPEC = 0x0008000000, // artifact powers reset UNIT_NPC_FLAG_TRANSMOGRIFIER = 0x0010000000, // transmogrification UNIT_NPC_FLAG_VAULTKEEPER = 0x0020000000, // void storage UNIT_NPC_FLAG_BLACK_MARKET = 0x0080000000, // black market |
