aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/game/Map.cpp7
-rw-r--r--src/game/Unit.cpp2
2 files changed, 3 insertions, 6 deletions
diff --git a/src/game/Map.cpp b/src/game/Map.cpp
index 42e21f9b5eb..7a280160913 100644
--- a/src/game/Map.cpp
+++ b/src/game/Map.cpp
@@ -1015,7 +1015,6 @@ bool Map::CreatureCellRelocation(Creature *c, Cell new_cell)
RemoveFromGrid(c,getNGrid(old_cell.GridX(), old_cell.GridY()),old_cell);
AddToGrid(c,getNGrid(new_cell.GridX(), new_cell.GridY()),new_cell);
- c->SetCurrentCell(new_cell);
}
else
{
@@ -1040,7 +1039,6 @@ bool Map::CreatureCellRelocation(Creature *c, Cell new_cell)
RemoveFromGrid(c,getNGrid(old_cell.GridX(), old_cell.GridY()),old_cell);
AddToGrid(c,getNGrid(new_cell.GridX(), new_cell.GridY()),new_cell);
- c->SetCurrentCell(new_cell);
return true;
}
@@ -1056,7 +1054,6 @@ bool Map::CreatureCellRelocation(Creature *c, Cell new_cell)
RemoveFromGrid(c,getNGrid(old_cell.GridX(), old_cell.GridY()),old_cell);
EnsureGridCreated(GridPair(new_cell.GridX(), new_cell.GridY()));
AddToGrid(c,getNGrid(new_cell.GridX(), new_cell.GridY()),new_cell);
- c->SetCurrentCell(new_cell);
return true;
}
@@ -1714,7 +1711,7 @@ void Map::AddToActive( Creature* c )
AddToActiveHelper(c);
// also not allow unloading spawn grid to prevent creating creature clone at load
- if(c->GetDBTableGUIDLow())
+ if(!c->isPet() && c->GetDBTableGUIDLow())
{
float x,y,z;
c->GetRespawnCoord(x,y,z);
@@ -1735,7 +1732,7 @@ void Map::RemoveFromActive( Creature* c )
RemoveFromActiveHelper(c);
// also allow unloading spawn grid
- if(c->GetDBTableGUIDLow())
+ if(!c->isPet() && c->GetDBTableGUIDLow())
{
float x,y,z;
c->GetRespawnCoord(x,y,z);
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp
index a3fc2400208..7bdb3b28d27 100644
--- a/src/game/Unit.cpp
+++ b/src/game/Unit.cpp
@@ -8342,7 +8342,7 @@ bool Unit::AttackStop()
void Unit::CombatStop(bool cast)
{
- if(cast& IsNonMeleeSpellCasted(false))
+ if(cast && IsNonMeleeSpellCasted(false))
InterruptNonMeleeSpells(false);
AttackStop();