本文整理汇总了C++中instance_gundrak类的典型用法代码示例。如果您正苦于以下问题:C++ instance_gundrak类的具体用法?C++ instance_gundrak怎么用?C++ instance_gundrak使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了instance_gundrak类的16个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: Aggro
void Aggro(Unit* /*pWho*/) override
{
DoScriptText(SAY_AGGRO, m_creature);
if (m_pInstance)
m_pInstance->SetData(TYPE_GALDARAH , IN_PROGRESS);
}
开发者ID:AwkwardDev,项目名称:mangos-d3,代码行数:7,代码来源:boss_galdarah.cpp
示例2: Aggro
void Aggro(Unit* /*pWho*/) override
{
DoCastSpellIfCan(m_creature, m_bIsRegularMode ? SPELL_MORTAL_STRIKES : SPELL_MORTAL_STRIKES_H);
if (m_pInstance)
m_pInstance->SetData(TYPE_COLOSSUS, IN_PROGRESS);
}
开发者ID:dvdvideo1234,项目名称:mangos-wotlk,代码行数:7,代码来源:boss_colossus.cpp
示例3: JustDied
void JustDied(Unit* pKiller)
{
DoScriptText(SAY_DEATH, m_creature);
if (m_pInstance)
m_pInstance->SetData(TYPE_MOORABI, DONE);
}
开发者ID:Bootz,项目名称:StrawberryCore,代码行数:7,代码来源:boss_moorabi.cpp
示例4: JustDied
void JustDied(Unit* /*pKiller*/) override
{
DoScriptText(SAY_DEATH, m_creature);
if (m_pInstance)
m_pInstance->SetData(TYPE_GALDARAH, DONE);
}
开发者ID:AwkwardDev,项目名称:mangos-d3,代码行数:7,代码来源:boss_galdarah.cpp
示例5: Aggro
void Aggro(Unit* pWho)
{
DoScriptText(SAY_AGGRO, m_creature);
DoCastSpellIfCan(m_creature, SPELL_MOJO_FRENZY);
if (m_pInstance)
m_pInstance->SetData(TYPE_MOORABI, IN_PROGRESS);
}
开发者ID:Bootz,项目名称:StrawberryCore,代码行数:8,代码来源:boss_moorabi.cpp
示例6: JustDied
void JustDied(Unit* /*pKiller*/) override
{
if (m_pInstance)
{
// kill colossus on death - this will finish the encounter
if (Creature* pColossus = m_pInstance->GetSingleCreatureFromStorage(NPC_COLOSSUS))
pColossus->DealDamage(pColossus, pColossus->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
}
}
开发者ID:dvdvideo1234,项目名称:mangos-wotlk,代码行数:9,代码来源:boss_colossus.cpp
示例7: JustReachedHome
void JustReachedHome() override
{
if (m_pInstance)
{
if (Creature* pColossus = m_pInstance->GetSingleCreatureFromStorage(NPC_COLOSSUS))
pColossus->AI()->EnterEvadeMode();
}
m_creature->ForcedDespawn();
}
开发者ID:dvdvideo1234,项目名称:mangos-wotlk,代码行数:10,代码来源:boss_colossus.cpp
示例8: JustSummoned
void JustSummoned(Creature* pSummoned)
{
if (!m_pInstance)
return;
if (Creature* pSladran = m_pInstance->GetSingleCreatureFromStorage(NPC_SLADRAN))
{
float fPosX, fPosY, fPosZ;
pSladran->GetPosition(fPosX, fPosY, fPosZ);
pSummoned->GetMotionMaster()->MovePoint(0, fPosX, fPosY, fPosZ);
}
}
开发者ID:Jeyza,项目名称:StrawberryCore,代码行数:12,代码来源:boss_sladran.cpp
示例9: JustSummoned
void JustSummoned(Creature* pSummoned) override
{
if (pSummoned->GetEntry() == NPC_RHINO_SPIRIT)
{
if (Unit* pTarget = m_creature->SelectAttackingTarget(ATTACKING_TARGET_RANDOM, 1, m_bIsRegularMode ? SPELL_STAMPEDE_RHINO : SPELL_STAMPEDE_RHINO_H, SELECT_FLAG_PLAYER))
{
pSummoned->CastSpell(pTarget, m_bIsRegularMode ? SPELL_STAMPEDE_RHINO : SPELL_STAMPEDE_RHINO_H, false, NULL, NULL, m_creature->GetObjectGuid());
// Store the player guid in order to count it for the achievement
if (m_pInstance)
m_pInstance->SetData(TYPE_ACHIEV_SHARE_LOVE, pTarget->GetGUIDLow());
}
}
}
开发者ID:AwkwardDev,项目名称:mangos-d3,代码行数:14,代码来源:boss_galdarah.cpp
示例10: EnterEvadeMode
void EnterEvadeMode() override
{
if (!m_bIsPartOfColossus)
ScriptedAI::EnterEvadeMode();
// Force the Mojo to move to the Colossus position
else
{
if (m_pInstance)
{
float fX, fY, fZ;
m_creature->GetPosition(fX, fY, fZ);
if (Creature* pColossus = m_pInstance->GetSingleCreatureFromStorage(NPC_COLOSSUS))
pColossus->GetPosition(fX, fY, fZ);
m_creature->SetWalk(false);
m_creature->GetMotionMaster()->MovePoint(1, fX, fY, fZ);
}
}
}
开发者ID:dvdvideo1234,项目名称:mangos-wotlk,代码行数:20,代码来源:boss_colossus.cpp
示例11: MovementInform
void MovementInform(uint32 uiType, uint32 uiPointId) override
{
if (uiType != POINT_MOTION_TYPE)
return;
if (uiPointId)
{
m_creature->ForcedDespawn(1000);
if (m_pInstance)
{
// Prepare to set the Colossus in combat
if (Creature* pColossus = m_pInstance->GetSingleCreatureFromStorage(NPC_COLOSSUS))
{
if (boss_drakkari_colossusAI* pBossAI = dynamic_cast<boss_drakkari_colossusAI*>(pColossus->AI()))
pBossAI->DoPrepareColossus();
}
}
}
}
开发者ID:dvdvideo1234,项目名称:mangos-wotlk,代码行数:20,代码来源:boss_colossus.cpp
示例12: UpdateAI
void UpdateAI(const uint32 uiDiff) override
{
if (!m_creature->SelectHostileTarget() || !m_creature->getVictim())
return;
if (m_creature->HasAura(SPELL_TRANSFORMATION) && !m_bMammothPhase)
{
DoScriptText(EMOTE_TRANSFORMED, m_creature);
m_bMammothPhase = true;
// Set the achievement to failed
if (m_pInstance)
m_pInstance->SetLessRabiAchievementCriteria(false);
}
if (m_uiRoarTimer < uiDiff)
{
DoCastSpellIfCan(m_creature->getVictim(), m_bMammothPhase ? SPELL_NUMBING_ROAR : SPELL_NUMBING_SHOUT);
m_uiRoarTimer = 20000;
}
else
m_uiRoarTimer -= uiDiff;
if (m_uiQuakeTimer < uiDiff)
{
DoScriptText(SAY_QUAKE, m_creature);
DoCastSpellIfCan(m_creature->getVictim(), m_bMammothPhase ? SPELL_QUAKE : SPELL_GROUND_TREMOR);
m_uiQuakeTimer = m_bMammothPhase ? 13000 : 18000;
}
else
m_uiQuakeTimer -= uiDiff;
if (m_uiStabTimer < uiDiff)
{
if (m_bMammothPhase)
DoCastSpellIfCan(m_creature->getVictim(), m_bIsRegularMode ? SPELL_DETERMINED_GORE : SPELL_DETERMINED_GORE_H);
else
DoCastSpellIfCan(m_creature->getVictim(), SPELL_DETERMINED_STAB);
m_uiStabTimer = 7000;
}
else
m_uiStabTimer -= uiDiff;
// check only in troll phase
if (!m_bMammothPhase)
{
if (m_uiTransformationTimer < uiDiff)
{
DoScriptText(SAY_TRANSFORM, m_creature);
DoScriptText(EMOTE_TRANSFORM, m_creature);
DoCastSpellIfCan(m_creature, SPELL_TRANSFORMATION);
m_uiPreviousTimer *= 0.8;
m_uiTransformationTimer = m_uiPreviousTimer;
}
else
m_uiTransformationTimer -= uiDiff;
}
DoMeleeAttackIfReady();
}
开发者ID:AwkwardDev,项目名称:mangos-d3,代码行数:61,代码来源:boss_moorabi.cpp
示例13: JustReachedHome
void JustReachedHome() override
{
if (m_pInstance)
m_pInstance->SetData(TYPE_SLADRAN, FAIL);
}
开发者ID:jviljoen82,项目名称:ScriptDev3,代码行数:5,代码来源:boss_sladran.cpp
示例14: UpdateAI
void UpdateAI(const uint32 uiDiff) override
{
if (!m_creature->SelectHostileTarget() || !m_creature->getVictim())
return;
if (m_uiPoisonNovaTimer < uiDiff)
{
if (DoCastSpellIfCan(m_creature, m_bIsRegularMode ? SPELL_POISON_NOVA : SPELL_POISON_NOVA_H) == CAST_OK)
{
DoScriptText(EMOTE_NOVA, m_creature);
m_uiPoisonNovaTimer = 22000;
}
}
else
m_uiPoisonNovaTimer -= uiDiff;
if (m_uiSummonTimer < uiDiff)
{
if (!m_pInstance)
return;
if (Creature* pSummonTarget = m_creature->GetMap()->GetCreature(m_pInstance->SelectRandomSladranTargetGuid()))
{
if (urand(0, 3))
{
// we don't want to get spammed
if (!urand(0, 4))
DoScriptText(SAY_SUMMON_CONSTRICTOR, m_creature);
pSummonTarget->CastSpell(pSummonTarget, SPELL_SUMMON_CONSTRICTOR, false, NULL, NULL, m_creature->GetObjectGuid());
}
else
{
// we don't want to get spammed
if (!urand(0, 4))
DoScriptText(SAY_SUMMON_SNAKE, m_creature);
pSummonTarget->CastSpell(pSummonTarget, SPELL_SUMMON_VIPER, false, NULL, NULL, m_creature->GetObjectGuid());
}
}
m_uiSummonTimer = m_bIsRegularMode ? 5000 : 3000;
}
else
m_uiSummonTimer -= uiDiff;
if (m_uiPowerfulBiteTimer < uiDiff)
{
if (DoCastSpellIfCan(m_creature->getVictim(), m_bIsRegularMode ? SPELL_POWERFUL_BITE : SPELL_POWERFUL_BITE_H) == CAST_OK)
m_uiPowerfulBiteTimer = 10000;
}
else
m_uiPowerfulBiteTimer -= uiDiff;
if (m_uiVenomBoltTimer < uiDiff)
{
if (Unit* pTarget = m_creature->SelectAttackingTarget(ATTACKING_TARGET_RANDOM, 0))
{
if (DoCastSpellIfCan(pTarget, m_bIsRegularMode ? SPELL_VENOM_BOLT : SPELL_VENOM_BOLT_H) == CAST_OK)
m_uiVenomBoltTimer = 15000;
}
}
else
m_uiVenomBoltTimer -= uiDiff;
DoMeleeAttackIfReady();
}
开发者ID:jviljoen82,项目名称:ScriptDev3,代码行数:67,代码来源:boss_sladran.cpp
示例15: JustReachedHome
void JustReachedHome() override
{
if (m_pInstance)
m_pInstance->SetData(TYPE_GALDARAH, FAIL);
}
开发者ID:AwkwardDev,项目名称:mangos-d3,代码行数:5,代码来源:boss_galdarah.cpp
示例16: JustReachedHome
void JustReachedHome()
{
if (m_pInstance)
m_pInstance->SetData(TYPE_GALDARAH, NOT_STARTED);
}
开发者ID:Bootz,项目名称:StrawberryCore,代码行数:5,代码来源:boss_galdarah.cpp
注:本文中的instance_gundrak类示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论