5438{
5439
5442
5443
5445 {
5448 }
5449
5450
5452 {
5454 {
5455
5457 {
5458
5465
5467 {
5469 {
5480 }
5481 }
5482 }
5483
5484
5487 }
5488
5490 {
5492 {
5495 else
5497 }
5498
5501 }
5502 }
5503
5505 {
5508 }
5509
5510
5513
5514
5519
5521 {
5525
5529 }
5530
5532 {
5535
5536
5537
5539 {
5540 bool checkForm = true;
5541
5544 {
5546 continue;
5547
5548 checkForm = false;
5549 break;
5550 }
5551
5552 if (checkForm)
5553 {
5554
5557 return shapeError;
5558
5561 }
5562 }
5563
5564 bool reqCombat = true;
5566 for (Unit::AuraEffectList::const_iterator j = stateAuras.begin(); j != stateAuras.end(); ++j)
5567 {
5569 {
5571 if ((*j)->GetMiscValue() == 1)
5572 {
5573 reqCombat = false;
5574 break;
5575 }
5576 }
5577 }
5578
5579
5580
5582 {
5587
5588
5593
5598
5601 }
5602
5603
5605 {
5608 return vehicleCheck;
5609 }
5610 }
5611
5612
5613 {
5616 {
5617
5619 {
5623 }
5624
5628 }
5629 }
5630
5631
5632
5633
5634
5636 {
5637
5639
5640
5643
5646 return castResult;
5647 }
5648
5650 {
5653 return castResult;
5654
5655
5657 {
5659 {
5661 if (!unitCaster->IsFriendlyTo(auraEff->GetCaster()) && !target->HasAura(auraEff->GetId(), auraEff->GetCasterGUID()))
5663
5665 if (!unitCaster->IsFriendlyTo(auraEff->GetCaster()) && (!target->HasAura(auraEff->GetId(), auraEff->GetCasterGUID()) || !unitCaster->HasAura(auraEff->GetId(), auraEff->GetCasterGUID())))
5667 }
5668 }
5669
5671 {
5672
5675
5676
5679
5680
5682 {
5686 losTarget = dynObj;
5687
5690 }
5691 }
5692 }
5693
5694
5696 {
5697 float x, y, z;
5699
5702 }
5703
5704
5706 {
5708 if (!unitCaster->GetPetGUID().IsEmpty())
5710
5712 {
5714 {
5715 if (!unitCaster->GetGuardianPet())
5716 {
5719 else
5721 }
5722 break;
5723 }
5724 }
5725 }
5726
5727
5731
5732
5734 if (player->InArena())
5735 {
5738 return castResult;
5739 }
5740
5741
5743 {
5746
5749 return locRes;
5750 }
5751
5752
5754 {
5756 {
5759 else
5761 }
5762 }
5763
5764
5766 {
5768 {
5772 }
5773 }
5774
5776
5777
5779 {
5782 return castResult;
5783 }
5784
5785
5789 return castResult;
5790
5792 {
5795 return castResult;
5796 }
5797
5799 {
5802 return castResult;
5803 }
5804
5805
5808 return castResult;
5809
5810 uint32 approximateAuraEffectMask = 0;
5811 uint32 nonAuraEffectMask = 0;
5813 {
5814
5815 switch (spellEffectInfo.Effect)
5816 {
5818 {
5820 {
5822 if (!unit || !unit->
HasAura(17743))
5824 }
5826 {
5829
5833
5834 }
5835 break;
5836 }
5838 {
5840 break;
5841
5843 if (!pet)
5845
5847 if (!learn_spellproto)
5849
5852
5853 break;
5854 }
5856 {
5862 break;
5863 }
5865 {
5866
5868 {
5871
5875
5877
5878 if (!learn_spellproto)
5880
5883 }
5884 break;
5885 }
5887 {
5890
5894
5895 if (
uint32 glyphId = spellEffectInfo.MiscValue)
5896 {
5898 if (!glyphProperties)
5900
5901 std::vector<uint32>
const* glyphBindableSpells =
sDB2Manager.GetGlyphBindableSpells(glyphId);
5902 if (!glyphBindableSpells)
5904
5905 if (std::find(glyphBindableSpells->begin(), glyphBindableSpells->end(),
m_misc.SpellId) == glyphBindableSpells->end())
5907
5908 if (std::vector<uint32>
const* glyphRequiredSpecs =
sDB2Manager.GetGlyphRequiredSpecs(glyphId))
5909 {
5912
5913 if (std::find(glyphRequiredSpecs->begin(), glyphRequiredSpecs->end(), caster->
GetPrimarySpecialization()) == glyphRequiredSpecs->end())
5915 }
5916
5917 uint32 replacedGlyph = 0;
5919 {
5920 if (std::vector<uint32>
const* activeGlyphBindableSpells =
sDB2Manager.GetGlyphBindableSpells(activeGlyphId))
5921 {
5922 if (std::find(activeGlyphBindableSpells->begin(), activeGlyphBindableSpells->end(),
m_misc.SpellId) != activeGlyphBindableSpells->end())
5923 {
5924 replacedGlyph = activeGlyphId;
5925 break;
5926 }
5927 }
5928 }
5929
5931 {
5932 if (activeGlyphId == replacedGlyph)
5933 continue;
5934
5935 if (activeGlyphId == glyphId)
5937
5940 }
5941 }
5942 break;
5943 }
5945 {
5948
5950 if (!foodItem)
5952
5954 if (!pet)
5956
5959
5962
5965
5966 break;
5967 }
5969 {
5971 if (!unitCaster)
5973
5976
5978 {
5980 if (!target)
5982
5983
5986
5989
5992
5993
6001
6003 }
6004 break;
6005 }
6007 {
6010
6013
6018
6020
6023 int32 ReqValue = (skillValue < 100 ? (TargetLevel-10) * 10 : TargetLevel * 5);
6024 if (ReqValue > skillValue)
6026
6027 break;
6028 }
6030 {
6033 break;
6034
6036
6039
6040 Item* pTempItem =
nullptr;
6042 {
6045 }
6048
6049
6054
6060
6061
6064 {
6065 lockId = go->GetGOInfo()->GetLockId();
6066 if (!lockId)
6068
6071 }
6073 lockId = itm->GetTemplate()->GetLockID();
6074
6076 int32 reqSkillValue = 0;
6077 int32 skillValue = 0;
6078
6079
6082 return res;
6083 break;
6084 }
6086 {
6090
6094
6097 {
6098 return petInfo && !petInfo->Health;
6099 });
6100
6101 if (deadPetItr == petStable->
ActivePets.end())
6103
6104 break;
6105 }
6106
6108 {
6110 if (!unitCaster)
6111 break;
6112
6114 if (!SummonProperties)
6115 break;
6116
6117 switch (SummonProperties->
Control)
6118 {
6122 [[fallthrough]];
6126 break;
6127 }
6128 break;
6129 }
6131 {
6133 {
6138 }
6139 break;
6140 }
6142 {
6144 if (!unitCaster)
6146
6148 {
6150 {
6151 if (strict)
6154 .SetOriginalCaster(pet->
GetGUID())
6156 }
6159 }
6160
6163
6166 {
6168 if (!spellEffectInfo.MiscValue)
6169 {
6170 petSlot =
PetSaveMode(spellEffectInfo.CalcValue());
6171
6172
6174 {
6175 if (activePet && !activePet->Health)
6176 {
6179 }
6180 }
6181 }
6182
6184 if (info.first)
6185 {
6187 {
6190 {
6191
6192 if (creatureInfo && creatureInfo->
IsTameable(
true))
6194 else
6196
6198 }
6199 }
6200 }
6201 else if (!spellEffectInfo.MiscValue)
6202 {
6205 }
6206 }
6207
6208 break;
6209 }
6211 {
6213 if (!playerCaster)
6215
6217 if (!pet)
6219
6222
6223 break;
6224 }
6226 {
6229
6232
6236
6239
6240
6242 {
6243 uint32 mapId = map->GetId();
6244 Difficulty difficulty = map->GetDifficultyID();
6245 if (
InstanceLock const* mapLock = map->GetInstanceLock())
6248
6249 if (!target->
Satisfy(
sObjectMgr->GetAccessRequirement(mapId, difficulty), mapId))
6251 }
6252 break;
6253 }
6254
6256 {
6259
6263
6265 if (!target ||
6268 break;
6269 }
6272 {
6273
6278 break;
6279 }
6281 {
6284 break;
6285 }
6287 {
6289 if (!unitCaster)
6291
6293 {
6296 else
6298 }
6299 break;
6300 }
6303 {
6305 if (!unitCaster)
6307
6310 break;
6311 }
6313 {
6316 if (!player)
6318
6321
6323 {
6327 }
6328
6329
6333 break;
6334 }
6336 {
6338 if (!playerCaster)
6340
6342 if (!talent)
6344
6346 {
6347 if (param1)
6350 }
6351 break;
6352 }
6355 {
6357 if (!playerCaster)
6359
6361 if (!artifactAura)
6363
6365 if (!artifact)
6367
6369 {
6371 if (!artifactEntry || artifactEntry->
ArtifactCategoryID != spellEffectInfo.MiscValue)
6373 }
6374 break;
6375 }
6379 {
6383
6387
6389 if (creature)
6390 {
6393
6396
6398 {
6400 {
6401 if (
uint32 battlePetType = spellEffectInfo.MiscValue)
6402 if (!(battlePetType & (1 << battlePetSpecies->PetTypeEnum)))
6404
6406 {
6408 {
6409 return a1->MaxQualityRoll < selector;
6410 });
6411
6415
6418 }
6419
6423
6424 if (battlePetSpecies->GetFlags().HasFlag(BattlePetSpeciesFlags::CantBattle))
6426 }
6427 }
6428 }
6429 break;
6430 }
6431 default:
6432 break;
6433 }
6434
6435 if (spellEffectInfo.IsAura())
6436 approximateAuraEffectMask |= 1 << spellEffectInfo.EffectIndex;
6437 else if (spellEffectInfo.IsEffect())
6438 nonAuraEffectMask |= 1 << spellEffectInfo.EffectIndex;
6439 }
6440
6442 {
6443 switch (spellEffectInfo.ApplyAuraName)
6444 {
6446 {
6449
6451 if (!pet)
6453
6456 break;
6457 }
6461 {
6463 if (!unitCaster)
6465
6468
6471 {
6474
6477 }
6478
6480 {
6483
6486
6489
6492
6496 }
6497
6498 break;
6499 }
6501 {
6503 if (!unitCaster)
6505
6508
6510 {
6513 }
6514 break;
6515 }
6517 {
6520
6521
6524 break;
6525 }
6528 {
6529
6530
6532 {
6537 }
6538 break;
6539 }
6541 {
6542 if (spellEffectInfo.IsTargetingArea())
6543 break;
6544
6547
6549 break;
6550
6553 break;
6554 }
6555 default:
6556 break;
6557 }
6558
6559
6562 && (approximateAuraEffectMask & (1 << spellEffectInfo.EffectIndex))
6567 approximateAuraEffectMask, false))
6569 }
6570
6571
6573 {
6576
6579
6582
6584 if (!my_trade)
6586
6589
6593 }
6594
6595
6598 if (!plrCaster->GetComboPoints())
6600
6601
6603}
#define sBattlefieldMgr
Definition: BattlefieldMgr.h:80
@ STATUS_WAIT_LEAVE
Definition: Battleground.h:161
@ STATUS_IN_PROGRESS
Definition: Battleground.h:160
#define M_PI
Definition: Common.h:140
#define sConditionMgr
Definition: ConditionMgr.h:351
@ CONDITION_SOURCE_TYPE_SPELL
Definition: ConditionMgr.h:168
DB2Storage< BattlePetBreedQualityEntry > sBattlePetBreedQualityStore("BattlePetBreedQuality.db2", &BattlePetBreedQualityLoadInfo::Instance)
DB2Storage< ArtifactEntry > sArtifactStore("Artifact.db2", &ArtifactLoadInfo::Instance)
DB2Storage< ChrClassesEntry > sChrClassesStore("ChrClasses.db2", &ChrClassesLoadInfo::Instance)
DB2Storage< ChrSpecializationEntry > sChrSpecializationStore("ChrSpecialization.db2", &ChrSpecializationLoadInfo::Instance)
DB2Storage< BattlePetSpeciesEntry > sBattlePetSpeciesStore("BattlePetSpecies.db2", &BattlePetSpeciesLoadInfo::Instance)
DB2Storage< SummonPropertiesEntry > sSummonPropertiesStore("SummonProperties.db2", &SummonPropertiesLoadInfo::Instance)
DB2Storage< GlyphPropertiesEntry > sGlyphPropertiesStore("GlyphProperties.db2", &GlyphPropertiesLoadInfo::Instance)
DB2Storage< TalentEntry > sTalentStore("Talent.db2", &TalentLoadInfo::Instance)
DB2Storage< AreaTableEntry > sAreaTableStore("AreaTable.db2", &AreaTableLoadInfo::Instance)
#define sDB2Manager
Definition: DB2Stores.h:502
Difficulty
Definition: DBCEnums.h:732
@ DIFFICULTY_NONE
Definition: DBCEnums.h:733
@ AREA_FLAG_NO_FLY_ZONE
Definition: DBCEnums.h:139
@ SPELL_DISABLE_LOS
Definition: DisableMgr.h:48
@ DISABLE_TYPE_SPELL
Definition: DisableMgr.h:27
#define sInstanceLockMgr
Definition: InstanceLockMgr.h:318
@ LOOT_SKINNING
Definition: Loot.h:104
@ TRANSFER_ABORT_NONE
Definition: Map.h:85
@ TYPEID_GAMEOBJECT
Definition: ObjectGuid.h:41
@ TYPEID_UNIT
Definition: ObjectGuid.h:38
#define sObjectMgr
Definition: ObjectMgr.h:1976
std::optional< T > Optional
Optional helper class to wrap optional values within.
Definition: Optional.h:25
@ PATHFIND_NOPATH
Definition: PathGenerator.h:47
@ PATHFIND_SHORT
Definition: PathGenerator.h:49
@ PATHFIND_INCOMPLETE
Definition: PathGenerator.h:46
@ HUNTER_PET
Definition: PetDefines.h:32
PetSaveMode
Definition: PetDefines.h:41
@ SPELL_ATTR7_IS_CHEAT_SPELL
Definition: SharedDefines.h:676
@ GAMEOBJECT_TYPE_TRAP
Definition: SharedDefines.h:2782
@ SPELL_ATTR5_NOT_AVAILABLE_WHILE_CHARMED
Definition: SharedDefines.h:613
@ TARGET_UNIT_PET
Definition: SharedDefines.h:2582
@ TARGET_GAMEOBJECT_TARGET
Definition: SharedDefines.h:2595
@ SPELL_ATTR2_ENCHANT_OWN_ITEM_ONLY
Definition: SharedDefines.h:501
@ SPELL_ATTR2_INITIATE_COMBAT_POST_CAST_ENABLES_AUTO_ATTACK
Definition: SharedDefines.h:508
@ SPELL_ATTR2_NO_ACTIVE_PETS
Definition: SharedDefines.h:504
@ SPELL_ATTR2_IGNORE_LINE_OF_SIGHT
Definition: SharedDefines.h:490
@ SPELL_ATTR1_INITIATES_COMBAT_ENABLES_AUTO_ATTACK
Definition: SharedDefines.h:460
@ SPELL_ATTR3_ONLY_BATTLEGROUNDS
Definition: SharedDefines.h:536
@ SPELL_DAMAGE_CLASS_MELEE
Definition: SharedDefines.h:2761
@ SPELL_EFFECT_DUMMY
Definition: SharedDefines.h:1132
@ SPELL_EFFECT_LEAP
Definition: SharedDefines.h:1158
@ SPELL_EFFECT_SUMMON_PET
Definition: SharedDefines.h:1185
@ SPELL_EFFECT_GIVE_ARTIFACT_POWER_NO_BONUS
Definition: SharedDefines.h:1371
@ SPELL_EFFECT_SUMMON_RAF_FRIEND
Definition: SharedDefines.h:1281
@ SPELL_EFFECT_WEAPON_DAMAGE
Definition: SharedDefines.h:1187
@ SPELL_EFFECT_APPLY_GLYPH
Definition: SharedDefines.h:1203
@ SPELL_EFFECT_NORMALIZED_WEAPON_DMG
Definition: SharedDefines.h:1250
@ SPELL_EFFECT_FEED_PET
Definition: SharedDefines.h:1230
@ SPELL_EFFECT_SUMMON_PLAYER
Definition: SharedDefines.h:1214
@ SPELL_EFFECT_JUMP_DEST
Definition: SharedDefines.h:1171
@ SPELL_EFFECT_TELEPORT_UNITS_FACE_CASTER
Definition: SharedDefines.h:1172
@ SPELL_EFFECT_ATTACK
Definition: SharedDefines.h:1207
@ SPELL_EFFECT_RESURRECT_PET
Definition: SharedDefines.h:1238
@ SPELL_EFFECT_CHANGE_BATTLEPET_QUALITY
Definition: SharedDefines.h:1333
@ SPELL_EFFECT_WEAPON_PERCENT_DAMAGE
Definition: SharedDefines.h:1160
@ SPELL_EFFECT_GRANT_BATTLEPET_LEVEL
Definition: SharedDefines.h:1354
@ SPELL_EFFECT_WEAPON_DAMAGE_NOSCHOOL
Definition: SharedDefines.h:1146
@ SPELL_EFFECT_LEAP_BACK
Definition: SharedDefines.h:1267
@ SPELL_EFFECT_SUMMON
Definition: SharedDefines.h:1157
@ SPELL_EFFECT_UNLOCK_GUILD_VAULT_TAB
Definition: SharedDefines.h:1302
@ SPELL_EFFECT_CHARGE
Definition: SharedDefines.h:1225
@ SPELL_EFFECT_DISMISS_PET
Definition: SharedDefines.h:1231
@ SPELL_EFFECT_TALENT_SPEC_SELECT
Definition: SharedDefines.h:1291
@ SPELL_EFFECT_GRANT_BATTLEPET_EXPERIENCE
Definition: SharedDefines.h:1415
@ SPELL_EFFECT_LEARN_SPELL
Definition: SharedDefines.h:1165
@ SPELL_EFFECT_GIVE_ARTIFACT_POWER
Definition: SharedDefines.h:1369
@ SPELL_EFFECT_JUMP
Definition: SharedDefines.h:1170
@ SPELL_EFFECT_SKINNING
Definition: SharedDefines.h:1224
@ SPELL_EFFECT_REMOVE_TALENT
Definition: SharedDefines.h:1310
@ SPELL_EFFECT_CREATE_TAMED_PET
Definition: SharedDefines.h:1282
@ SPELL_EFFECT_OPEN_LOCK
Definition: SharedDefines.h:1162
@ SPELL_EFFECT_STEAL_BENEFICIAL_BUFF
Definition: SharedDefines.h:1255
@ SPELL_EFFECT_LEARN_PET_SPELL
Definition: SharedDefines.h:1186
SpellCustomErrors
Definition: SharedDefines.h:1766
@ SPELL_CUSTOM_ERROR_GM_ONLY
Definition: SharedDefines.h:1832
@ POWER_MANA
Definition: SharedDefines.h:278
@ SPELL_ATTR0_ONLY_INDOORS
Definition: SharedDefines.h:428
@ SPELL_ATTR0_ONLY_OUTDOORS
Definition: SharedDefines.h:429
@ SPELL_ATTR0_ALLOW_WHILE_MOUNTED
Definition: SharedDefines.h:438
@ SPELL_ATTR0_COOLDOWN_ON_EVENT
Definition: SharedDefines.h:439
@ SPELL_ATTR0_USES_RANGED_SLOT
Definition: SharedDefines.h:415
@ SPELL_ATTR0_ALLOW_CAST_WHILE_DEAD
Definition: SharedDefines.h:437
@ SPELL_ATTR0_ONLY_STEALTHED
Definition: SharedDefines.h:431
@ LINEOFSIGHT_ALL_CHECKS
Definition: SharedDefines.h:6809
@ SPELL_ATTR12_IGNORE_CASTING_DISABLED
Definition: SharedDefines.h:867
AuraStateType
Definition: SharedDefines.h:2453
@ SPELL_ATTR4_AURA_NEVER_BOUNCES
Definition: SharedDefines.h:582
@ SPELL_ATTR4_AURA_BOUNCE_FAILS_SPELL
Definition: SharedDefines.h:591
@ SUMMON_CATEGORY_PET
Definition: SharedDefines.h:5979
@ SUMMON_CATEGORY_PUPPET
Definition: SharedDefines.h:5980
SkillType
Definition: SharedDefines.h:5279
@ SPELL_FAILED_TARGET_NOT_LOOTED
Definition: SharedDefines.h:1583
@ SPELL_FAILED_NOT_INFRONT
Definition: SharedDefines.h:1525
@ GRANT_PET_LEVEL_FAIL
Definition: SharedDefines.h:1697
@ SPELL_FAILED_NOT_MOUNTED
Definition: SharedDefines.h:1528
@ SPELL_FAILED_AFFECTING_COMBAT
Definition: SharedDefines.h:1441
@ SPELL_FAILED_CASTER_AURASTATE
Definition: SharedDefines.h:1466
@ SPELL_FAILED_WRONG_ARTIFACT_EQUIPPED
Definition: SharedDefines.h:1728
@ SPELL_FAILED_TARGET_NOT_PLAYER
Definition: SharedDefines.h:1584
@ SPELL_FAILED_CANT_UNTALENT
Definition: SharedDefines.h:1465
@ SPELL_FAILED_NOT_KNOWN
Definition: SharedDefines.h:1527
@ SPELL_FAILED_FOOD_LOWLEVEL
Definition: SharedDefines.h:1481
@ SPELL_FAILED_NO_SPEC
Definition: SharedDefines.h:1689
@ SPELL_FAILED_NOT_HERE
Definition: SharedDefines.h:1524
@ SPELL_FAILED_ROOTED
Definition: SharedDefines.h:1564
@ SPELL_FAILED_GLYPH_INVALID_SPEC
Definition: SharedDefines.h:1661
@ SPELL_FAILED_ALREADY_HAVE_PET
Definition: SharedDefines.h:1448
@ SPELL_FAILED_WRONG_PET_FOOD
Definition: SharedDefines.h:1599
@ SPELL_FAILED_CUSTOM_ERROR
Definition: SharedDefines.h:1654
@ SPELL_FAILED_SUMMON_PENDING
Definition: SharedDefines.h:1669
@ SPELL_FAILED_BAD_IMPLICIT_TARGETS
Definition: SharedDefines.h:1452
@ SPELL_FAILED_TRY_AGAIN
Definition: SharedDefines.h:1595
@ SPELL_FAILED_NO_COMBO_POINTS
Definition: SharedDefines.h:1541
@ SPELL_FAILED_CANT_UPGRADE_BATTLE_PET
Definition: SharedDefines.h:1691
@ SPELL_FAILED_ALREADY_HAVE_SUMMON
Definition: SharedDefines.h:1447
@ SPELL_FAILED_NOT_TRADING
Definition: SharedDefines.h:1535
@ SPELL_FAILED_NOT_IN_BATTLEGROUND
Definition: SharedDefines.h:1648
@ SPELL_FAILED_NOT_BEHIND
Definition: SharedDefines.h:1521
@ SPELL_FAILED_ALREADY_HAVE_CHARM
Definition: SharedDefines.h:1446
@ SPELL_FAILED_HIGHLEVEL
Definition: SharedDefines.h:1499
@ SPELL_FAILED_LOWLEVEL
Definition: SharedDefines.h:1512
@ SPELL_FAILED_NOT_READY
Definition: SharedDefines.h:1531
@ SPELL_FAILED_WRONG_BATTLE_PET_TYPE
Definition: SharedDefines.h:1692
@ SPELL_FAILED_ONLY_BATTLEGROUNDS
Definition: SharedDefines.h:1606
@ SPELL_FAILED_ITEM_ALREADY_ENCHANTED
Definition: SharedDefines.h:1505
@ SPELL_FAILED_ONLY_STEALTHED
Definition: SharedDefines.h:1556
@ SPELL_FAILED_CANT_DO_THAT_RIGHT_NOW
Definition: SharedDefines.h:1655
@ SPELL_FAILED_TARGET_IS_PLAYER_CONTROLLED
Definition: SharedDefines.h:1580
@ SPELL_FAILED_NO_ARTIFACT_EQUIPPED
Definition: SharedDefines.h:1727
@ SPELL_FAILED_ONLY_ABOVEWATER
Definition: SharedDefines.h:1551
@ SPELL_FAILED_TARGETS_DEAD
Definition: SharedDefines.h:1570
@ SPELL_FAILED_GLYPH_NO_SPEC
Definition: SharedDefines.h:1662
@ SPELL_FAILED_CANT_BE_CHARMED
Definition: SharedDefines.h:1455
@ SPELL_FAILED_CASTER_DEAD
Definition: SharedDefines.h:1467
@ SPELL_FAILED_ITEM_ENCHANT_TRADE_WINDOW
Definition: SharedDefines.h:1668
@ SPELL_FAILED_GLYPH_EXCLUSIVE_CATEGORY
Definition: SharedDefines.h:1660
@ SPELL_FAILED_TARGET_UNSKINNABLE
Definition: SharedDefines.h:1588
@ SPELL_FAILED_UNIQUE_GLYPH
Definition: SharedDefines.h:1658
@ SPELL_FAILED_ONLY_OUTDOORS
Definition: SharedDefines.h:1554
@ SPELL_FAILED_CHARMED
Definition: SharedDefines.h:1468
@ SPELL_FAILED_INVALID_GLYPH
Definition: SharedDefines.h:1657
@ SPELL_FAILED_LINE_OF_SIGHT
Definition: SharedDefines.h:1511
@ SPELL_FAILED_VISION_OBSCURED
Definition: SharedDefines.h:1598
@ SPELL_FAILED_NO_PET
Definition: SharedDefines.h:1547
@ SPELL_FAILED_TARGET_LOCKED_TO_RAID_INSTANCE
Definition: SharedDefines.h:1651
@ SPELL_FAILED_REQUIRES_SPELL_FOCUS
Definition: SharedDefines.h:1563
@ SPELL_FAILED_NOPATH
Definition: SharedDefines.h:1520
@ SPELL_FAILED_ONLY_INDOORS
Definition: SharedDefines.h:1552
@ SPELL_FAILED_NOT_ON_TAXI
Definition: SharedDefines.h:1529
@ SPELL_FAILED_TARGET_FRIENDLY
Definition: SharedDefines.h:1576
@ SPELL_AURA_ABILITY_IGNORE_AURASTATE
Definition: SpellAuraDefines.h:356
@ SPELL_AURA_DISABLE_CASTING_EXCEPT_ABILITIES
Definition: SpellAuraDefines.h:357
@ SPELL_AURA_DISABLE_ATTACKING_EXCEPT_ABILITIES
Definition: SpellAuraDefines.h:358
@ SPELL_AURA_MOD_IGNORE_SHAPESHIFT
Definition: SpellAuraDefines.h:369
@ SPELL_AURA_PERIODIC_MANA_LEECH
Definition: SpellAuraDefines.h:158
@ SPELL_AURA_MOD_POSSESS_PET
Definition: SpellAuraDefines.h:472
@ SPELL_AURA_RANGED_ATTACK_POWER_ATTACKER_BONUS
Definition: SpellAuraDefines.h:221
@ SPELL_AURA_FLY
Definition: SpellAuraDefines.h:295
@ SPELL_AURA_MOD_CHARM
Definition: SpellAuraDefines.h:100
@ SPELL_AURA_MOUNTED
Definition: SpellAuraDefines.h:172
@ SPELL_AURA_AOE_CHARM
Definition: SpellAuraDefines.h:271
@ SPELL_AURA_PROVIDE_SPELL_FOCUS
Definition: SpellAuraDefines.h:375
@ SPELL_AURA_MOD_POSSESS
Definition: SpellAuraDefines.h:96
@ SPELL_AURA_INTERFERE_TARGETTING
Definition: SpellAuraDefines.h:416
@ SPELL_AURA_MOD_INCREASE_MOUNTED_FLIGHT_SPEED
Definition: SpellAuraDefines.h:301
@ TARGET_FLAG_ITEM
Definition: SpellDefines.h:277
@ TRIGGERED_IGNORE_CASTER_AURASTATE
Will ignore most target checks (mostly DBC target checks)
Definition: SpellDefines.h:266
@ TRIGGERED_IGNORE_CASTER_MOUNTED_OR_ON_VEHICLE
Disallows proc events from triggered spell (default)
Definition: SpellDefines.h:255
@ TRIGGERED_IGNORE_SHAPESHIFT
Will not adjust facing to target (if any)
Definition: SpellDefines.h:252
@ TRIGGERED_IGNORE_GCD
Not triggered.
Definition: SpellDefines.h:242
@ TRIGGERED_IGNORE_CASTER_AURAS
Will ignore mounted/on vehicle restrictions.
Definition: SpellDefines.h:258
@ SPELL_ATTR0_CU_REQ_TARGET_FACING_CASTER
Definition: SpellInfo.h:164
@ SPELL_ATTR0_CU_REQ_CASTER_BEHIND_TARGET
Definition: SpellInfo.h:165
@ TRADE_SLOT_NONTRADED
Definition: TradeData.h:27
@ UNIT_FLAG2_ALLOW_CHEAT_SPELLS
Definition: UnitDefines.h:207
@ UNIT_FLAG_IMMUNE
Definition: UnitDefines.h:170
@ UNIT_FLAG_SKINNABLE
Definition: UnitDefines.h:165
@ UNIT_STATE_ROOT
Definition: Unit.h:254
#define ARTIFACTS_ALL_WEAPONS_GENERAL_WEAPON_EQUIPPED_PASSIVE
Definition: Unit.h:36
constexpr std::underlying_type< E >::type AsUnderlyingType(E enumValue)
Definition: Util.h:475
Definition: SpellAuraEffects.h:29
Definition: SpellAuras.h:123
ObjectGuid GetCastItemGUID() const
Definition: SpellAuras.h:144
Definition: BattlePetMgr.h:147
BattlePet * GetPet(ObjectGuid guid)
Definition: BattlePetMgr.cpp:444
bool HasJournalLock() const
Definition: BattlePetMgr.h:201
Definition: Battlefield.h:210
bool CanFlyIn()
Return if we can use mount in battlefield.
Definition: Battlefield.h:347
Definition: Battleground.h:256
Loot * GetLootForPlayer(Player const *player) const override
Definition: Creature.cpp:1367
CreatureTemplate const * GetCreatureTemplate() const
Definition: Creature.h:214
Definition: DynamicObject.h:37
Definition: GameObject.h:125
GameObjectTemplate const * GetGOInfo() const
Definition: GameObject.h:161
Definition: InstanceLockMgr.h:84
bool IsLocked() const
Definition: Item.h:251
ItemTemplate const * GetTemplate() const
Definition: Item.cpp:1140
bool IsPotion() const
Definition: Item.h:333
bool IsBattleground() const
Definition: Map.cpp:3222
InstanceMap * ToInstanceMap()
Definition: Map.h:430
static ObjectGuid const TradeItem
Definition: ObjectGuid.h:266
static GameObject * ToGameObject(Object *o)
Definition: Object.h:217
bool IsCreature() const
Definition: Object.h:204
Definition: PetDefines.h:116
std::array< Optional< PetInfo >, MAX_ACTIVE_PETS > ActivePets
Definition: PetDefines.h:140
Player * GetOwner() const
Definition: Pet.cpp:1811
static std::pair< PetStable::PetInfo const *, PetSaveMode > GetLoadPetInfo(PetStable const &stable, uint32 petEntry, uint32 petnumber, Optional< PetSaveMode > slot)
Definition: Pet.cpp:104
PetType getPetType() const
Definition: Pet.h:57
bool HaveInDiet(ItemTemplate const *item) const
Definition: Pet.cpp:1110
bool Satisfy(AccessRequirement const *ar, uint32 target_map, TransferAbortParams *params=nullptr, bool report=false)
Definition: Player.cpp:19358
bool IsInSameRaidWith(Player const *p) const
Definition: Player.cpp:2208
ObjectGuid GetSummonedBattlePetGUID() const
Definition: Player.h:2814
bool CanTameExoticPets() const
Definition: Player.h:2308
bool CanUseBattlegroundObject(GameObject *gameobject) const
Definition: Player.cpp:25647
bool InBattleground() const
Definition: Player.h:2396
std::vector< uint32 > const & GetGlyphs(uint8 spec) const
Definition: Player.h:1880
PetStable * GetPetStable()
Definition: Player.h:1238
Pet * GetPet() const
Definition: Player.cpp:21152
Guild * GetGuild()
Definition: Player.cpp:28563
bool HasSummonPending() const
Definition: Player.cpp:24750
WorldSession * GetSession() const
Definition: Player.h:2103
void SendTameFailure(PetTameResult result)
Definition: Player.cpp:21252
Battleground * GetBattleground() const
Definition: Player.cpp:24457
bool IsGameMaster() const
Definition: Player.h:1194
uint8 GetActiveTalentGroup() const
Definition: Player.h:1847
Player * GetSelectedPlayer() const
Definition: Player.cpp:23712
bool HasSpell(uint32 spell) const override
Definition: Player.cpp:3766
Item * GetItemByGuid(ObjectGuid guid) const
Definition: Player.cpp:9469
uint32 GetPrimarySpecialization() const
Definition: Player.h:1845
GameObject * GetGOTarget() const
Definition: Spell.cpp:240
ObjectGuid GetItemTargetGUID() const
Definition: SpellDefines.h:352
bool IsReady(SpellInfo const *spellInfo, uint32 itemId=0) const
Definition: SpellHistory.cpp:278
bool HasCooldown(SpellInfo const *spellInfo, uint32 itemId=0) const
Definition: SpellHistory.cpp:669
Definition: SpellInfo.h:322
uint32 RequiresSpellFocus
Definition: SpellInfo.h:352
uint32 SpellLevel
Definition: SpellInfo.h:385
uint32 CasterAuraSpell
Definition: SpellInfo.h:358
float GetMaxRange(bool positive=false, WorldObject *caster=nullptr, Spell *spell=nullptr) const
Definition: SpellInfo.cpp:3814
SpellCastResult CheckShapeshift(uint32 form) const
Definition: SpellInfo.cpp:1917
bool IsCooldownStartedOnEvent() const
Definition: SpellInfo.cpp:1616
SpellCastResult CheckLocation(uint32 map_id, uint32 zone_id, uint32 area_id, Player const *player=nullptr) const
Definition: SpellInfo.cpp:1966
uint32 ExcludeCasterAuraState
Definition: SpellInfo.h:356
uint32 CasterAuraState
Definition: SpellInfo.h:354
bool CanBeUsedInCombat() const
Definition: SpellInfo.cpp:1670
flag128 SpellFamilyFlags
Definition: SpellInfo.h:410
bool IsNextMeleeSwingSpell() const
Definition: SpellInfo.cpp:1700
SpellCastResult CheckVehicle(Unit const *caster) const
Definition: SpellInfo.cpp:2334
SpellCastResult CheckExplicitTarget(WorldObject const *caster, WorldObject const *target, Item const *itemTarget=nullptr) const
Definition: SpellInfo.cpp:2298
AuraType ExcludeCasterAuraType
Definition: SpellInfo.h:364
AuraType CasterAuraType
Definition: SpellInfo.h:362
uint32 ExcludeCasterAuraSpell
Definition: SpellInfo.h:360
bool HasAura(AuraType aura) const
Definition: SpellInfo.cpp:1367
bool IsTargetingArea() const
Definition: SpellInfo.cpp:1509
uint32 CategoryId
Definition: SpellInfo.h:328
int32 CalculateDamage(SpellEffectInfo const &spellEffectInfo, Unit const *target, float *var=nullptr) const
Definition: Spell.cpp:6897
SpellCastResult CheckItems(int32 *param1, int32 *param2) const
Definition: Spell.cpp:7120
GameObject * SearchSpellFocus()
Definition: Spell.cpp:2198
std::unique_ptr< PathGenerator > m_preGeneratedPath
Definition: Spell.h:890
SpellCastResult CanOpenLock(SpellEffectInfo const &effect, uint32 lockid, SkillType &skillid, int32 &reqSkillValue, int32 &skillValue)
Definition: Spell.cpp:8268
bool IsAutoRepeat() const
Definition: Spell.h:594
void SendMountResult(MountResult result)
Definition: Spell.cpp:4537
SpellCastResult CallScriptCheckCastHandlers()
Definition: Spell.cpp:8444
bool IsTriggered() const
Definition: Spell.cpp:7965
SpellCastResult CheckCasterAuras(int32 *param1) const
Definition: Spell.cpp:6639
SpellCastResult CheckPower() const
Definition: Spell.cpp:7078
bool HasGlobalCooldown() const
Definition: Spell.cpp:8711
SpellCastResult CheckRange(bool strict) const
Definition: Spell.cpp:6971
SpellCastResult CheckArenaAndRatedBattlegroundCastRules()
Definition: Spell.cpp:6842
uint32 GetSpell() const
Definition: TradeData.h:49
bool IsVehicle() const
Definition: Unit.h:853
Pet * ToPet()
Definition: Unit.h:1846
bool HasAuraTypeWithMiscvalue(AuraType auraType, int32 miscValue) const
Definition: Unit.cpp:4567
uint8 GetClass() const
Definition: Unit.h:861
bool IsInDisallowedMountForm() const
Definition: Unit.cpp:8676
Powers GetPowerType() const
Definition: Unit.h:908
bool HasUnitFlag(UnitFlags flags) const
Definition: Unit.h:940
ObjectGuid GetCharmedGUID() const
Definition: Unit.h:1277
bool HasUnitFlag2(UnitFlags2 flags) const
Definition: Unit.h:945
bool IsAlive() const
Definition: Unit.h:1253
float GetCombatReach() const override
Definition: Unit.h:804
CharmInfo * GetCharmInfo()
Definition: Unit.h:1308
bool IsInFlight() const
Definition: Unit.h:1118
Aura * GetAura(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint32 reqEffMask=0) const
Definition: Unit.cpp:4440
bool IsInWater() const
Definition: Unit.cpp:3078
AttackerSet const & getAttackers() const
Definition: Unit.h:823
uint8 GetLevelForTarget(WorldObject const *) const override
Definition: Unit.h:856
bool IsMounted() const
Definition: Unit.h:1006
bool HasUnitState(const uint32 f) const
Definition: Unit.h:842
DynamicObject * GetDynObject(uint32 spellId) const
Definition: Unit.cpp:5044
bool HasAura(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint32 reqEffMask=0) const
Definition: Unit.cpp:4544
ObjectGuid GetCharmerGUID() const
Definition: Unit.h:1274
bool isAttackReady(WeaponAttackType type=BASE_ATTACK) const
Definition: Unit.h:800
ObjectGuid GetBattlePetCompanionGUID() const
Definition: Unit.h:1269
bool IsHighestExclusiveAuraEffect(SpellInfo const *spellInfo, AuraType auraType, int32 effectAmount, uint32 auraEffectMask, bool removeOtherAuraApplications=false)
Definition: Unit.cpp:13477
ObjectGuid GetTarget() const
Definition: Unit.h:1855
bool IsInCombat() const
Definition: Unit.h:1143
ObjectGuid GetPetGUID() const
Definition: Unit.h:1265
bool isLineOfSightCalcEnabled() const
Definition: IVMapManager.h:109
static VMapManager2 * createOrGetVMapManager()
Definition: VMapFactory.cpp:27
bool IsWithinLOS(float x, float y, float z, LineOfSightChecks checks=LINEOFSIGHT_ALL_CHECKS, VMAP::ModelIgnoreFlags ignoreFlags=VMAP::ModelIgnoreFlags::Nothing) const
Definition: Object.cpp:1133
Unit * GetOwner() const
Definition: Object.cpp:2184
bool IsOutdoors() const
Definition: Object.h:539
bool IsWithinLOSInMap(WorldObject const *obj, LineOfSightChecks checks=LINEOFSIGHT_ALL_CHECKS, VMAP::ModelIgnoreFlags ignoreFlags=VMAP::ModelIgnoreFlags::Nothing) const
Definition: Object.cpp:1153
uint32 GetAreaId() const
Definition: Object.h:536
uint32 GetZoneId() const
Definition: Object.h:535
void GetZoneAndAreaId(uint32 &zoneid, uint32 &areaid) const
Definition: Object.h:537
uint32 GetRecruiterId() const
Definition: WorldSession.h:1152
uint32 GetAccountId() const
Definition: WorldSession.h:990
BattlePets::BattlePetMgr * GetBattlePetMgr() const
Definition: WorldSession.h:1165
BattlePetBreedQuality
Definition: BattlePetMgr.h:44
static constexpr uint16 MAX_BATTLE_PET_LEVEL
Definition: BattlePetMgr.h:41
bool IsDisabledFor(DisableType type, uint32 entry, WorldObject const *ref, uint8 flags)
Definition: DisableMgr.cpp:285
TC_GAME_API Player * FindPlayer(ObjectGuid const &)
Definition: ObjectAccessor.cpp:252
Definition: DB2Structure.h:126
Definition: DB2Structure.h:200
uint8 ArtifactCategoryID
Definition: DB2Structure.h:209
Definition: DB2Structure.h:452
Definition: DB2Structure.h:468
Definition: BattlePetMgr.h:137
Definition: DB2Structure.h:816
bool IsPetSpecialization() const
Definition: DB2Structure.h:831
int8 ClassID
Definition: DB2Structure.h:821
Definition: ConditionMgr.h:213
Condition const * mLastFailedCondition
Definition: ConditionMgr.h:216
uint32 ErrorType
Definition: ConditionMgr.h:232
uint8 ConditionTarget
Definition: ConditionMgr.h:236
uint32 ErrorTextId
Definition: ConditionMgr.h:233
Definition: CreatureData.h:471
SkillType GetRequiredLootSkill() const
Definition: CreatureData.h:551
bool IsTameable(bool canTameExotic) const
Definition: CreatureData.h:568
uint32 type
Definition: GameObjectData.h:33
uint32 GetNoDamageImmune() const
Definition: GameObjectData.h:1009
Definition: DB2Structure.h:1866
uint8 GlyphExclusiveCategoryID
Definition: DB2Structure.h:1870
uint32 GetBaseItemLevel() const
Definition: ItemTemplate.h:771
uint8 GetArtifactID() const
Definition: ItemTemplate.h:806
uint32 GetLockID() const
Definition: ItemTemplate.h:792
bool isLooted() const
Definition: Loot.h:305
LootType loot_type
Definition: Loot.h:286
float GetPositionZ() const
Definition: Position.h:79
float GetPositionX() const
Definition: Position.h:77
void GetPosition(float &x, float &y) const
Definition: Position.h:82
float GetPositionY() const
Definition: Position.h:78
Definition: DB2Structure.h:3833
int32 Control
Definition: DB2Structure.h:3835
Definition: DB2Structure.h:3853
uint32 SpellID
Definition: DB2Structure.h:3861