本文整理匯總了C++中GetCaster函數的典型用法代碼示例。如果您正苦於以下問題:C++ GetCaster函數的具體用法?C++ GetCaster怎麽用?C++ GetCaster使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了GetCaster函數的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C++代碼示例。
示例1: HandleDummy
void HandleDummy(SpellEffIndex effIndex)
{
GetCaster()->CastSpell(GetTargetUnit(),spell_trigger,false);
}
示例2: OnCast
void OnCast()
{
if (GetCaster()->GetTypeId() != TYPEID_PLAYER)
return;
SpellEntry const* spell = sSpellStore.LookupEntry(SPELL_FRENZIED_BLOODTHIRST);
spell = sSpellMgr->GetSpellForDifficultyFromSpell(spell, GetCaster());
GetCaster()->RemoveAura(spell->Id, 0, 0, AURA_REMOVE_BY_ENEMY_SPELL);
GetCaster()->CastSpell(GetCaster(), SPELL_ESSENCE_OF_THE_BLOOD_QUEEN_PLR, true);
// Presence of the Darkfallen buff on Blood-Queen
if (GetCaster()->GetMap()->IsHeroic())
GetCaster()->CastSpell(GetCaster(), SPELL_PRESENCE_OF_THE_DARKFALLEN, true);
// Shadowmourne questline
if (GetCaster()->ToPlayer()->GetQuestStatus(QUEST_BLOOD_INFUSION) == QUEST_STATUS_INCOMPLETE)
{
if (Aura* aura = GetCaster()->GetAura(SPELL_GUSHING_WOUND))
{
if (aura->GetStackAmount() == 3)
{
GetCaster()->CastSpell(GetCaster(), SPELL_THIRST_QUENCHED, true);
GetCaster()->RemoveAura(aura);
}
else
GetCaster()->CastSpell(GetCaster(), SPELL_GUSHING_WOUND, true);
}
}
if (InstanceScript* instance = GetCaster()->GetInstanceScript())
if (Creature* bloodQueen = ObjectAccessor::GetCreature(*GetCaster(), instance->GetData64(DATA_BLOOD_QUEEN_LANA_THEL)))
bloodQueen->AI()->SetGUID(GetHitUnit()->GetGUID(), GUID_VAMPIRE);
}
示例3: FilterTargets
void FilterTargets(std::list<Unit*>& unitList)
{
unitList.remove_if(PactOfTheDarkfallenCheck(true));
unitList.push_back(GetCaster());
}
示例4: CheckProc
bool CheckProc(ProcEventInfo& eventInfo)
{
return eventInfo.GetProcTarget() == GetCaster();
}
示例5: HandleEffectScriptEffect
void HandleEffectScriptEffect(SpellEffIndex /*effIndex*/)
{
// Refresh Shadow Word: Pain on target
if (Unit* unitTarget = GetHitUnit())
if (AuraEffect* aur = unitTarget->GetAuraEffect(SPELL_AURA_PERIODIC_DAMAGE, SPELLFAMILY_PRIEST, 0x8000, 0, 0, GetCaster()->GetGUID()))
aur->GetBase()->RefreshDuration();
}
示例6: HandleEffectApply
void HandleEffectApply(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/)
{
Unit* target = GetTarget();
if (Unit* caster = GetCaster())
caster->CastSpell(target, PALADIN_SPELL_BLESSING_OF_SANCTUARY_BUFF, true);
}
示例7: HandleScriptEffect
void HandleScriptEffect(SpellEffIndex /*effIndex*/)
{
// Divine Plea
if (Aura* aura = GetCaster()->GetAura(PALADIN_SPELL_DIVINE_PLEA))
aura->RefreshDuration();
}
示例8: HandleDummy
void HandleDummy(SpellEffIndex effIndex)
{
PreventHitDefaultEffect(effIndex);
GetCaster()->CastSpell(GetHitUnit(), SPELL_VILE_GAS_TRIGGER_SUMMON);
}
示例9: HandleUpdatePeriodic
void HandleUpdatePeriodic(AuraEffect* aurEff)
{
aurEff->CalculatePeriodic(GetCaster());
}
示例10: NotifyTargets
void NotifyTargets()
{
if (Creature* caster = GetCaster()->ToCreature())
if (Unit* target = GetHitUnit())
caster->AI()->Talk(EMOTE_MUTATED_INFECTION, target);
}
示例11: FilterTargets
void FilterTargets(std::list<Unit*>& unitList)
{
unitList.remove_if (OrientationCheck(GetCaster()));
}
示例12: Load
bool Load() {
absorbPct = SpellMgr::CalculateSpellEffectAmount(GetSpellProto(),
EFFECT_0, GetCaster());
return true;
}
示例13: FilterTargetsInitial
void FilterTargetsInitial(std::list<Unit*>& unitList)
{
unitList.remove_if (DistanceCheck(GetCaster()));
sharedUnitList = unitList;
}
示例14: HandleScriptEffect
void HandleScriptEffect(SpellEffIndex /*effIndex*/)
{
Unit* caster = GetCaster();
caster->CastSpell(caster, RAND(SUMMON_ANGRY_KVALDIR, SUMMON_NORTH_SEA_MAKO, SUMMON_NORTH_SEA_THRESHER, SUMMON_NORTH_SEA_BLUE_SHARK));
}
示例15: HandleDummy
void HandleDummy(SpellEffIndex /*effIndex*/)
{
Unit* caster = GetCaster();
uint32 spellId = roll_chance_i(50) ? SPELL_CREATE_RESONATING_SKULL : SPELL_CREATE_BONE_DUST;
caster->CastSpell(caster, spellId, true, NULL);
}