diff options
| author | Vincent-Michael <vincent_michael@gmx.de> | 2016-09-03 19:44:37 +0200 |
|---|---|---|
| committer | Vincent-Michael <vincent_michael@gmx.de> | 2016-09-03 19:44:37 +0200 |
| commit | 3a860429d3410b1c8679486c75e575c8c75f9ab1 (patch) | |
| tree | e6c942f9fc5db2c7fb95c7ce22c85d268acf300a | |
| parent | 994d81369991ae61cfac7844eafd68aff7a08a2b (diff) | |
Core/Commands: Fixed build
| -rw-r--r-- | src/server/scripts/Commands/cs_debug.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/server/scripts/Commands/cs_debug.cpp b/src/server/scripts/Commands/cs_debug.cpp index c14d6f4b70a..84f86492750 100644 --- a/src/server/scripts/Commands/cs_debug.cpp +++ b/src/server/scripts/Commands/cs_debug.cpp @@ -1554,7 +1554,7 @@ public: static bool HandleDebugNearGraveyard(ChatHandler* handler, char const* args) { Player* player = handler->GetSession()->GetPlayer(); - const WorldSafeLocsEntry* nearestLoc = nullptr; + WorldSafeLocsEntry const* nearestLoc = nullptr; if (stricmp(args, "linked")) { @@ -1577,10 +1577,10 @@ public: for (uint32 i = 0; i < sWorldSafeLocsStore.GetNumRows(); ++i) { - const WorldSafeLocsEntry* loc = sWorldSafeLocsStore.LookupEntry(i); - if (loc && loc->map_id == player->GetMapId()) + WorldSafeLocsEntry const* loc = sWorldSafeLocsStore.LookupEntry(i); + if (loc && loc->MapID == player->GetMapId()) { - float dist = (loc->x - x) * (loc->x - x) + (loc->y - y) * (loc->y - y) + (loc->z - z) * (loc->z - z); + float dist = (loc->Loc.X - x) * (loc->Loc.X - x) + (loc->Loc.Y - y) * (loc->Loc.Y - y) + (loc->Loc.Z - z) * (loc->Loc.Z - z); if (dist < distNearest) { distNearest = dist; @@ -1591,7 +1591,7 @@ public: } if (nearestLoc) - handler->PSendSysMessage(LANG_COMMAND_NEARGRAVEYARD, nearestLoc->ID, nearestLoc->x, nearestLoc->y, nearestLoc->z); + handler->PSendSysMessage(LANG_COMMAND_NEARGRAVEYARD, nearestLoc->ID, nearestLoc->Loc.X, nearestLoc->Loc.Y, nearestLoc->Loc.Z); else handler->PSendSysMessage(LANG_COMMAND_NEARGRAVEYARD_NOTFOUND); |
