mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-22 18:15:31 +01:00
Core/Maps: Moved corpse management to map level
This commit is contained in:
@@ -217,7 +217,7 @@ public:
|
||||
{
|
||||
playerName = param3;
|
||||
if (normalizePlayerName(playerName))
|
||||
player = sObjectAccessor->FindPlayerByName(playerName);
|
||||
player = ObjectAccessor::FindPlayerByName(playerName);
|
||||
}
|
||||
|
||||
if (!player)
|
||||
@@ -283,7 +283,7 @@ public:
|
||||
{
|
||||
playerName = param2;
|
||||
if (normalizePlayerName(playerName))
|
||||
player = sObjectAccessor->FindPlayerByName(playerName);
|
||||
player = ObjectAccessor::FindPlayerByName(playerName);
|
||||
}
|
||||
|
||||
if (!player)
|
||||
|
||||
@@ -620,8 +620,10 @@ public:
|
||||
target->SaveToDB();
|
||||
}
|
||||
else
|
||||
// will resurrected at login without corpse
|
||||
sObjectAccessor->ConvertCorpseForPlayer(targetGuid);
|
||||
{
|
||||
SQLTransaction trans(nullptr);
|
||||
Player::OfflineResurrect(targetGuid, trans);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
@@ -842,7 +844,7 @@ public:
|
||||
// Save all players in the world
|
||||
static bool HandleSaveAllCommand(ChatHandler* handler, char const* /*args*/)
|
||||
{
|
||||
sObjectAccessor->SaveAllPlayers();
|
||||
ObjectAccessor::SaveAllPlayers();
|
||||
handler->SendSysMessage(LANG_PLAYERS_SAVED);
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -1117,7 +1117,6 @@ public:
|
||||
{
|
||||
TC_LOG_INFO("misc", "Reloading terrain_phase_info table...");
|
||||
sObjectMgr->LoadTerrainPhaseInfo();
|
||||
sWorld->UpdatePhaseDefinitions();
|
||||
handler->SendGlobalGMSysMessage("Terrain phase infos reloaded.");
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -100,7 +100,7 @@ public:
|
||||
// Triggering corpses expire check in world
|
||||
static bool HandleServerCorpsesCommand(ChatHandler* /*handler*/, char const* /*args*/)
|
||||
{
|
||||
sObjectAccessor->RemoveOldCorpses();
|
||||
sWorld->RemoveOldCorpses();
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -527,7 +527,7 @@ public:
|
||||
case PHASE_PLANT_FIRST_DETONATE: // first explosives detonate finish
|
||||
for (GuidList::iterator itr = _explosivesGuids.begin(); itr != _explosivesGuids.end(); ++itr)
|
||||
{
|
||||
if (GameObject* explosive = sObjectAccessor->GetGameObject(*me, *itr))
|
||||
if (GameObject* explosive = ObjectAccessor::GetGameObject(*me, *itr))
|
||||
me->RemoveGameObject(explosive, true);
|
||||
}
|
||||
_explosivesGuids.clear();
|
||||
@@ -624,7 +624,7 @@ public:
|
||||
case PHASE_PLANT_SECOND_DETONATE: // second explosives detonate finish
|
||||
for (GuidList::iterator itr = _explosivesGuids.begin(); itr != _explosivesGuids.end(); ++itr)
|
||||
{
|
||||
if (GameObject* explosive = sObjectAccessor->GetGameObject(*me, *itr))
|
||||
if (GameObject* explosive = ObjectAccessor::GetGameObject(*me, *itr))
|
||||
me->RemoveGameObject(explosive, true);
|
||||
}
|
||||
_explosivesGuids.clear();
|
||||
|
||||
Reference in New Issue
Block a user