Exemplo n.º 1
0
    void UpdateAI(const uint32 diff)
    {
        mPortalCount = pInstance->GetData(DATA_PORTAL_COUNT);

        if (TimeRiftWave_Timer)
        {
            if (TimeRiftWave_Timer <= diff)
            {
                DoSelectSummon();

                if (mPortalCount > 0 && mPortalCount < 13)
                    TimeRiftWave_Timer = urand(12000, 17000);
                else if (mPortalCount > 12 && mPortalCount < 18)
                    TimeRiftWave_Timer = urand(7000, 12000);
                else
                    TimeRiftWave_Timer = 0;

            }
            else TimeRiftWave_Timer -= diff;
        }

        if (m_creature->IsNonMeleeSpellCasted(false))
            return;

        debug_log("TSCR: npc_time_rift: not casting anylonger, i need to die.");
        m_creature->setDeathState(JUST_DIED);

        mRiftWaveCount = 0;
        pInstance->SetData(TYPE_RIFT,SPECIAL);
    }
        void UpdateAI(uint32 diff) override
        {
            if (TimeRiftWave_Timer <= diff)
            {
                DoSelectSummon();
                TimeRiftWave_Timer = 15000;
            } else TimeRiftWave_Timer -= diff;

            if (me->IsNonMeleeSpellCast(false))
                return;

            TC_LOG_DEBUG("scripts", "npc_time_rift: not casting anylonger, i need to die.");
            me->setDeathState(JUST_DIED);

            if (instance->GetData(TYPE_RIFT) == IN_PROGRESS)
                instance->SetData(TYPE_RIFT, SPECIAL);
        }
Exemplo n.º 3
0
    void UpdateAI(const uint32 diff)
    {
        if (!pInstance)
            return;

        if (TimeRiftWave_Timer <= diff)
        {
            DoSelectSummon();
            TimeRiftWave_Timer = 15000;
        } else TimeRiftWave_Timer -= diff;

        if (me->IsNonMeleeSpellCasted(false))
            return;

        debug_log("BSCR: npc_time_rift: not casting anylonger, i need to die.");
        me->setDeathState(JUST_DIED);

        pInstance->SetData(TYPE_RIFT,SPECIAL);
    }
Exemplo n.º 4
0
        void UpdateAI(const uint32 diff)
        {
            if(!pInstance)
                return;

            if(TimeRiftWave_Timer <= diff)
            {
                DoSelectSummon();
                TimeRiftWave_Timer = 15000;
            } else TimeRiftWave_Timer -= diff;

            if(me->IsNonMeleeSpellCasted(false))
                return;

            sLog->outDebug(LOG_FILTER_TSCR, "TSCR: npc_time_rift: not casting anylonger, i need to die.");
            me->setDeathState(JUST_DIED);

            if(pInstance->GetData(TYPE_RIFT) == IN_PROGRESS)
                pInstance->SetData(TYPE_RIFT, SPECIAL);
        }