mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-23 10:26:28 +01:00
Merge [SD2]
r1146 Use ForcedDespawn() where possible and remove some not needed function calls. Code style applied. Requires Mangos 8040+ r1147 Make Millhouse have better movement, using distance for MoveChase r1148 Added missing call sendGossipMenu r1149 Correct mixed up emote and language in one script_texts r1150 Update custom SD2 patch for Mangos 0.12 branch - skip --HG-- branch : trunk
This commit is contained in:
@@ -114,9 +114,6 @@ void npc_escortAI::UpdateAI(const uint32 diff)
|
||||
debug_log("TSCR: EscortAI reached end of waypoints");
|
||||
|
||||
m_creature->setDeathState(JUST_DIED);
|
||||
m_creature->SetHealth(0);
|
||||
m_creature->CombatStop(true);
|
||||
m_creature->DeleteThreatList();
|
||||
m_creature->Respawn();
|
||||
m_creature->GetMotionMaster()->Clear(true);
|
||||
|
||||
|
||||
@@ -315,7 +315,7 @@ struct TRINITY_DLL_DECL mob_ethereal_beaconAI : public ScriptedAI
|
||||
m_creature->InterruptNonMeleeSpells(true);
|
||||
|
||||
m_creature->CastSpell(m_creature,SPELL_ETHEREAL_APPRENTICE,true);
|
||||
KillSelf();
|
||||
m_creature->ForcedDespawn();
|
||||
return;
|
||||
}else Apprentice_Timer -= diff;
|
||||
}
|
||||
|
||||
@@ -153,16 +153,9 @@ struct TRINITY_DLL_DECL npc_draenei_survivorAI : public ScriptedAI
|
||||
if (RunAwayTimer)
|
||||
{
|
||||
if (RunAwayTimer <= diff)
|
||||
{
|
||||
m_creature->RemoveAllAuras();
|
||||
m_creature->GetMotionMaster()->Clear();
|
||||
m_creature->GetMotionMaster()->MoveIdle();
|
||||
m_creature->setDeathState(JUST_DIED);
|
||||
m_creature->SetHealth(0);
|
||||
m_creature->CombatStop(true);
|
||||
m_creature->DeleteThreatList();
|
||||
m_creature->RemoveCorpse();
|
||||
}else RunAwayTimer -= diff;
|
||||
m_creature->ForcedDespawn();
|
||||
else
|
||||
RunAwayTimer -= diff;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -436,6 +436,7 @@ bool GossipHello_boss_gloomrel(Player *player, Creature *_Creature)
|
||||
if (player->GetQuestRewardStatus(4083) == 0 && player->GetSkillValue(SKILL_MINING) >= 230)
|
||||
player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_TRIBUTE, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
|
||||
|
||||
player->SEND_GOSSIP_MENU(_Creature->GetNpcTextId(), _Creature->GetGUID());
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -98,12 +98,15 @@ struct TRINITY_DLL_DECL npc_millhouse_manastormAI : public ScriptedAI
|
||||
}
|
||||
}
|
||||
|
||||
void AttackStart(Unit* who)
|
||||
void AttackStart(Unit* pWho)
|
||||
{
|
||||
if (m_creature->Attack(who, true))
|
||||
if (m_creature->Attack(pWho, true))
|
||||
{
|
||||
//TODO: Make it so he moves when target out of range
|
||||
DoStartNoMovement(who);
|
||||
m_creature->AddThreat(pWho, 0.0f);
|
||||
m_creature->SetInCombatWith(pWho);
|
||||
pWho->SetInCombatWith(m_creature);
|
||||
|
||||
m_creature->GetMotionMaster()->MoveChase(pWho, 25.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user