当前位置: 首页>>代码示例>>C++>>正文


C++ BossSpellWorker::doRemove方法代码示例

本文整理汇总了C++中BossSpellWorker::doRemove方法的典型用法代码示例。如果您正苦于以下问题:C++ BossSpellWorker::doRemove方法的具体用法?C++ BossSpellWorker::doRemove怎么用?C++ BossSpellWorker::doRemove使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在BossSpellWorker的用法示例。


在下文中一共展示了BossSpellWorker::doRemove方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: JustDied

    void JustDied(Unit* pKiller)
    {
        if (defaultTarget && defaultTarget->isAlive()) bsw->doRemove(SPELL_SNOBOLLED, defaultTarget);
//      if (pBoss && pBoss->isAlive()) bsw->doRemove(SPELL_RISING_ANGER,pBoss);
//      This string - not offlike, in off this buff not removed! especially for small servers.
    }
开发者ID:eviljared,项目名称:diamondcore,代码行数:6,代码来源:boss_northrend_beasts.cpp

示例2: UpdateAI

    void UpdateAI(const uint32 uiDiff)
    {
        if ((!m_creature->SelectHostileTarget() || !m_creature->getVictim()) &&
            (m_pInstance->GetData(TYPE_NORTHREND_BEASTS) != DREADSCALE_SUBMERGED))
            return;

        switch (stage) 
        {
            case 0:
            {
                bsw->timedCast(SPELL_BURNING_BITE, uiDiff);
                bsw->timedCast(SPELL_MOLTEN_SPEW, uiDiff);
                bsw->timedCast(SPELL_FIRE_SPIT, uiDiff);
                bsw->timedCast(SPELL_BURNING_SPRAY, uiDiff);
                bsw->timedCast(SPELL_SWEEP_0, uiDiff);

                if (m_pInstance->GetData(TYPE_NORTHREND_BEASTS) == DREADSCALE_SUBMERGED)
                     stage = 1;

                break;
            }
            case 1:
            {
                m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
                bsw->doCast(SPELL_SUBMERGE_0);
                stage = 2;
                DoScriptText(-1713557,m_creature);
                m_pInstance->SetData(TYPE_NORTHREND_BEASTS, DREADSCALE_SUBMERGED);
                break;
            }
            case 2:
            {
                if (bsw->timedQuery(SPELL_SLIME_POOL, uiDiff))
                    bsw->doCast(NPC_SLIME_POOL);

                if (bsw->timedQuery(SPELL_SUBMERGE_0, uiDiff) && m_pInstance->GetData(TYPE_NORTHREND_BEASTS) == DREADSCALE_SUBMERGED) 
                         stage = 3;
                    break;
            }
            case 3:
            {
                DoScriptText(-1713559,m_creature);
                bsw->doRemove(SPELL_SUBMERGE_0);
                m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
                stage = 0;
                m_pInstance->SetData(TYPE_NORTHREND_BEASTS, ACIDMAW_SUBMERGED);
                break;
            }
        }

        if (m_pInstance->GetData(TYPE_NORTHREND_BEASTS) == SNAKES_SPECIAL && !enraged)
        {
            DoScriptText(-1713559,m_creature);
            bsw->doRemove(SPELL_SUBMERGE_0);
            m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
            bsw->doCast(SPELL_ENRAGE);
            enraged = true;
            stage = 0;
            DoScriptText(-1713504,m_creature);
        };

        DoMeleeAttackIfReady();
    }
开发者ID:eviljared,项目名称:diamondcore,代码行数:63,代码来源:boss_northrend_beasts.cpp

示例3: UpdateAI

    void UpdateAI(const uint32 uiDiff)
    {
        if (m_pInstance && !Unit::GetCreature((*me), m_pInstance->GetData64(NPC_ACIDMAW)))
            this->JustReachedHome();

        if (!UpdateVictim())
            return;

        switch (stage) 
        {
        case 0: {
                bsw->timedCast(SPELL_BURNING_BITE, uiDiff);

                bsw->timedCast(SPELL_MOLTEN_SPEW, uiDiff);

                bsw->timedCast(SPELL_FIRE_SPIT, uiDiff);

                bsw->timedCast(SPELL_BURNING_SPRAY, uiDiff);

                bsw->timedCast(SPELL_SWEEP_0, uiDiff);

                if (m_pInstance->GetData(TYPE_NORTHREND_BEASTS) == DREADSCALE_SUBMERGED)
                     stage = 1;

                    break;}
        case 1: {
                    me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
                    bsw->doCast(SPELL_SUBMERGE_0);
                    stage = 2;
                    DoScriptText(-1713557,me);
                    m_pInstance->SetData(TYPE_NORTHREND_BEASTS, DREADSCALE_SUBMERGED);
                    break;}
        case 2: {
                if (bsw->timedQuery(SPELL_SLIME_POOL, uiDiff))
                    bsw->doCast(NPC_SLIME_POOL);

                if (bsw->timedQuery(SPELL_SUBMERGE_0, uiDiff) && m_pInstance->GetData(TYPE_NORTHREND_BEASTS) == DREADSCALE_SUBMERGED) 
                         stage = 3;
                    break;}
        case 3: {
                    DoScriptText(-1713559,me);
                    bsw->doRemove(SPELL_SUBMERGE_0);

                    me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
                    bsw->resetTimer(SPELL_SLIME_POOL);
                    stage = 0;
                    m_pInstance->SetData(TYPE_NORTHREND_BEASTS, ACIDMAW_SUBMERGED);
                    break;}
        }

        if (m_pInstance->GetData(TYPE_NORTHREND_BEASTS) == SNAKES_SPECIAL && !enraged)
                        {
                        DoScriptText(-1713559,me);
                        bsw->doRemove(SPELL_SUBMERGE_0);
                        me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
                        bsw->doCast(SPELL_ENRAGE);
                        enraged = true;
                        stage = 0;
                        DoScriptText(-1713504,me);
                        };

        DoMeleeAttackIfReady();
    }
开发者ID:SergeySV,项目名称:PhantomCore,代码行数:63,代码来源:boss_northrend_beasts.cpp


注:本文中的BossSpellWorker::doRemove方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。