Skip to content
Permalink
Browse files

Map persistant state fix for respawn of death creature that appear al…

…ive on gm mode.
  • Loading branch information
cyberium committed Feb 12, 2020
1 parent d9d5308 commit 471ebfd670d69c857ba96b933428404560cb91b6
Showing with 2 additions and 0 deletions.
  1. +2 −0 src/game/Entities/Creature.cpp
@@ -1488,6 +1488,7 @@ bool Creature::LoadFromDB(uint32 guidlow, Map* map)
if (m_respawnTime > time(nullptr)) // not ready to respawn
{
m_deathState = DEAD;
SetHealth(0);
if (CanFly())
{
float tz = GetTerrain()->GetHeightStatic(data->posX, data->posY, data->posZ, false);
@@ -1508,6 +1509,7 @@ bool Creature::LoadFromDB(uint32 guidlow, Map* map)
if (m_deathState == ALIVE && !GetMap()->GetCreatureLinkingHolder()->CanSpawn(this))
{
m_deathState = DEAD;
SetHealth(0);

// Just set to dead, so need to relocate like above
if (CanFly())

0 comments on commit 471ebfd

Please sign in to comment.
You can’t perform that action at this time.