mirror of
https://github.com/mangosfour/server.git
synced 2025-12-12 10:37:03 +00:00
[10114] Store associated InstanceSave for dungeon map in Map object
This commit is contained in:
parent
6f4481a591
commit
67a7892075
9 changed files with 89 additions and 62 deletions
|
|
@ -841,8 +841,9 @@ uint32 Unit::DealDamage(Unit *pVictim, uint32 damage, CleanDamage const* cleanDa
|
|||
// the reset time is set but not added to the scheduler
|
||||
// until the players leave the instance
|
||||
time_t resettime = cVictim->GetRespawnTimeEx() + 2 * HOUR;
|
||||
if(InstanceSave *save = sInstanceSaveMgr.GetInstanceSave(cVictim->GetInstanceId()))
|
||||
if(save->GetResetTime() < resettime) save->SetResetTime(resettime);
|
||||
if (InstanceSave *save = m->GetInstanceSave())
|
||||
if (save->GetResetTime() < resettime)
|
||||
save->SetResetTime(resettime);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue