[10114] Store associated InstanceSave for dungeon map in Map object

This commit is contained in:
VladimirMangos 2010-06-27 21:01:29 +04:00
parent 6f4481a591
commit 67a7892075
9 changed files with 89 additions and 62 deletions

View file

@ -552,7 +552,7 @@ bool ChatHandler::HandleGonameCommand(const char* args)
InstanceGroupBind *gBind = group ? group->GetBoundInstance(target) : NULL;
// if no bind exists, create a solo bind
if (!gBind)
if (InstanceSave *save = sInstanceSaveMgr.GetInstanceSave(target->GetInstanceId()))
if (InstanceSave *save = target->GetMap()->GetInstanceSave())
_player->BindToInstance(save, !save->CanReset());
}