aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjal.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.cpp10
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/instance_hyjal.cpp3
-rw-r--r--src/game/Spell.cpp2
-rw-r--r--src/game/Unit.cpp5
5 files changed, 10 insertions, 14 deletions
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjal.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjal.cpp
index 331dab2fed4..a63856ea6f2 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjal.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjal.cpp
@@ -91,7 +91,7 @@ bool GossipSelect_npc_jaina_proudmoore(Player *player, Creature *_Creature, uint
{
if(_Creature->GetMap()->GetPlayersCountExceptGMs() < MINPLAYERS && !player->isGameMaster())
{
- _Creature->Say("Did you come to die with me?",0,0);
+ _Creature->MonsterSay("Did you come to die with me?",0,0);
return true;
}
hyjalAI* ai = ((hyjalAI*)_Creature->AI());
@@ -169,7 +169,7 @@ bool GossipSelect_npc_thrall(Player *player, Creature *_Creature, uint32 sender,
{
if(_Creature->GetMap()->GetPlayersCountExceptGMs() < MINPLAYERS && !player->isGameMaster())//to stop idiot farmers
{
- _Creature->Say("Did you come to die with me?",0,0);
+ _Creature->MonsterSay("Did you come to die with me?",0,0);
return true;
}
hyjalAI* ai = ((hyjalAI*)_Creature->AI());
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.cpp
index 2671bebacea..727caed4912 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.cpp
@@ -957,7 +957,7 @@ void hyjalAI::HideNearPos(float x, float y)
// First get all creatures.
std::list<Creature*> creatures;
Trinity::AllFriendlyCreaturesInGrid creature_check(m_creature);
- Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(creatures, creature_check);
+ Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(m_creature, creatures, creature_check);
TypeContainerVisitor
<Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid>,
GridTypeMapContainer> creature_visitor(creature_searcher);
@@ -985,7 +985,7 @@ void hyjalAI::RespawnNearPos(float x, float y)
cell.SetNoCreate();
Trinity::RespawnDo u_do;
- Trinity::WorldObjectWorker<Trinity::RespawnDo> worker(u_do);
+ Trinity::WorldObjectWorker<Trinity::RespawnDo> worker(m_creature, u_do);
TypeContainerVisitor<Trinity::WorldObjectWorker<Trinity::RespawnDo>, GridTypeMapContainer > obj_worker(worker);
CellLock<GridReadGuard> cell_lock(cell, p);
cell_lock->Visit(cell_lock, obj_worker, *m_creature->GetMap());
@@ -994,7 +994,7 @@ void hyjalAI::WaypointReached(uint32 i)
{
if(i == 1 || (i == 0 && m_creature->GetEntry() == THRALL))
{
- m_creature->Yell("Hurry, we don't have much time",0,0);
+ m_creature->MonsterYell("Hurry, we don't have much time",0,0);
WaitForTeleport = true;
TeleportTimer = 15000;
//do some talking
@@ -1007,7 +1007,7 @@ void hyjalAI::WaypointReached(uint32 i)
// First get all creatures.
std::list<Creature*> creatures;
Trinity::AllFriendlyCreaturesInGrid creature_check(m_creature);
- Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(creatures, creature_check);
+ Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(m_creature, creatures, creature_check);
TypeContainerVisitor
<Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid>,
GridTypeMapContainer> creature_visitor(creature_searcher);
@@ -1049,7 +1049,7 @@ void hyjalAI::DoOverrun(uint32 faction, const uint32 diff)
std::list<Creature*> creatures;
Trinity::AllFriendlyCreaturesInGrid creature_check(m_creature);
- Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(creatures, creature_check);
+ Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(m_creature, creatures, creature_check);
TypeContainerVisitor
<Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid>,
GridTypeMapContainer> creature_visitor(creature_searcher);
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/instance_hyjal.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/instance_hyjal.cpp
index 87624a773a2..89a895713f7 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/instance_hyjal.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/instance_hyjal.cpp
@@ -113,8 +113,7 @@ struct TRINITY_DLL_DECL instance_mount_hyjal : public ScriptedInstance
void OpenDoor(uint64 DoorGUID, bool open)
{
- if(GameObject *Door = instance->GetGameObjectInMap(DoorGUID))
- Door->SetUInt32Value(GAMEOBJECT_STATE, open ? 0 : 1);
+ HandleGameObject(DoorGUID, open, NULL);
}
void OnCreatureCreate(Creature *creature, uint32 creature_entry)
diff --git a/src/game/Spell.cpp b/src/game/Spell.cpp
index 857bf19ac31..4bb55ceee04 100644
--- a/src/game/Spell.cpp
+++ b/src/game/Spell.cpp
@@ -2225,7 +2225,7 @@ void Spell::cancel()
return;
SetReferencedFromCurrent(false);
- if(m_selfContainer)
+ if(m_selfContainer && *m_selfContainer == this)
*m_selfContainer = NULL;
uint32 oldState = m_spellState;
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp
index 182d661fdde..c93a9dd6a1d 100644
--- a/src/game/Unit.cpp
+++ b/src/game/Unit.cpp
@@ -3218,10 +3218,7 @@ void Unit::_DeleteAuras()
{
// remove auras only for non-aoe spells or when chanelled aura is removed
// because aoe spells don't require aura on target to continue
- {
- caster->m_currentSpells[CURRENT_CHANNELED_SPELL]->cancel();
- caster->m_currentSpells[CURRENT_CHANNELED_SPELL]=NULL;
- }
+ caster->m_currentSpells[CURRENT_CHANNELED_SPELL]->cancel();
}
if(caster->GetTypeId()==TYPEID_UNIT && ((Creature*)caster)->isTotem() && ((Totem*)caster)->GetTotemType()==TOTEM_STATUE)