OregonCore  revision be9e804-git
Your Favourite TBC server
WorldLocation Class Reference

#include <Object.h>

+ Inheritance diagram for WorldLocation:

Public Member Functions

 WorldLocation (uint32 _mapid=MAPID_INVALID, float _x=0, float _y=0, float _z=0, float _o=0)
 WorldLocation (const WorldLocation &loc)
void WorldRelocate (const WorldLocation &loc)
uint32 GetMapId () const
- Public Member Functions inherited from Position
 Position (float x=0, float y=0, float z=0, float o=0)
 Position (Position const &loc)
bool operator== (Position const &a)
bool operator!= (Position const &a)
void Relocate (float x, float y)
void Relocate (float x, float y, float z)
void Relocate (float x, float y, float z, float orientation)
void Relocate (Position const &pos)
void Relocate (Position const *pos)
void RelocateOffset (Position const &offset)
void SetOrientation (float orientation)
float GetPositionX () const
float GetPositionY () const
float GetPositionZ () const
float GetOrientation () const
void GetPosition (float &x, float &y) const
void GetPosition (float &x, float &y, float &z) const
void GetPosition (float &x, float &y, float &z, float &o) const
Position GetPosition () const
Position::PositionXYStreamer PositionXYStream ()
Position::PositionXYZStreamer PositionXYZStream ()
Position::PositionXYZOStreamer PositionXYZOStream ()
bool IsPositionValid () const
float GetExactDist2dSq (float x, float y) const
float GetExactDist2d (const float x, const float y) const
float GetExactDist2dSq (Position const *pos) const
float GetExactDist2d (Position const *pos) const
float GetExactDistSq (float x, float y, float z) const
float GetExactDist (float x, float y, float z) const
float GetExactDistSq (Position const *pos) const
float GetExactDist (Position const *pos) const
void GetPositionOffsetTo (Position const &endPos, Position &retOffset) const
Position GetPositionWithOffset (Position const &offset) const
float GetAngle (Position const *pos) const
float GetAngle (float x, float y) const
float GetRelativeAngle (Position const *pos) const
float GetRelativeAngle (float x, float y) const
void GetSinCos (float x, float y, float &vsin, float &vcos) const
bool IsInDist2d (float x, float y, float dist) const
bool IsInDist2d (Position const *pos, float dist) const
bool IsInDist (float x, float y, float z, float dist) const
bool IsInDist (Position const *pos, float dist) const
bool IsWithinBox (const Position &center, float xradius, float yradius, float zradius) const
bool HasInArc (float arcangle, Position const *pos, float border=2.0f) const
bool HasInLine (Position const *pos, float width) const
std::string ToString () const

Public Attributes

uint32 m_mapId
- Public Attributes inherited from Position
float m_positionX
float m_positionY
float m_positionZ

Additional Inherited Members

- Static Public Member Functions inherited from Position
static float NormalizeOrientation (float o)

Detailed Description

Definition at line 549 of file Object.h.

Constructor & Destructor Documentation

WorldLocation::WorldLocation ( uint32  _mapid = MAPID_INVALID,
float  _x = 0,
float  _y = 0,
float  _z = 0,
float  _o = 0 

Definition at line 552 of file Object.h.

Referenced by Player::_LoadBGData(), Player::GetStartPosition(), Player::SetBattlegroundEntryPoint(), and Player::TeleportTo().

553  : m_mapId(_mapid)
554  {
555  Relocate(_x, _y, _z, _o);
556  }
uint32 m_mapId
Definition: Object.h:572
void Relocate(float x, float y)
Definition: Position.h:65
WorldLocation::WorldLocation ( const WorldLocation loc)

Definition at line 557 of file Object.h.

558  {
559  WorldRelocate(loc);
560  }
void WorldRelocate(const WorldLocation &loc)
Definition: Object.h:562

Member Function Documentation

uint32 WorldLocation::GetMapId ( ) const

Definition at line 567 of file Object.h.

Referenced by Group::_homebindIfInstance(), Player::_LoadInventory(), Player::_SaveBGData(), Player::ActivateTaxiPathTo(), ObjectAccessor::AddCorpse(), Map::AddObjectToRemoveList(), WorldObject::AddObjectToRemoveList(), Map::AddObjectToSwitchList(), Player::CheckAreaExploreAndOutdoor(), Spell::CheckCast(), Spell::CheckTarget(), Player::ContinueTaxiFlight(), Player::CreateCorpse(), OPvPCapturePoint::DelCreature(), Player::DestroyZoneLimitedItem(), ScriptedAI::DoTeleportAll(), ScriptedAI::DoTeleportPlayer(), Spell::EffectBind(), Spell::EffectResurrect(), Spell::EffectResurrectNew(), Spell::EffectScriptEffect(), Spell::EffectStuck(), Spell::EffectSummonFriend(), Spell::EffectSummonObjectWild(), Spell::EffectSummonPlayer(), Spell::EffectTeleportUnits(), ChatHandler::ExecuteCommandInTable(), Group::GetBoundInstance(), Battleground::GetClosestGraveYard(), SocialMgr::GetFriendInfo(), Creature::GetLinkedCreatureRespawnTime(), Player::GetNextQuest(), ChatHandler::HandleAddTeleCommand(), ChatHandler::HandleAppearCommand(), WorldSession::HandleBattlegroundArenaJoin(), WorldSession::HandleBattlegroundJoinOpcode(), WorldSession::HandleCorpseQueryOpcode(), ChatHandler::HandleGoGridCommand(), ChatHandler::HandleGoXYCommand(), ChatHandler::HandleGoXYZCommand(), ChatHandler::HandleGPSCommand(), WorldSession::HandleGroupInviteOpcode(), ChatHandler::HandleGroupSummonCommand(), ChatHandler::HandleInstanceUnbindCommand(), WorldSession::HandleLootMasterGiveOpcode(), ChatHandler::HandleMoveObjectCommand(), WorldSession::HandleMoveWorldportAckOpcode(), ChatHandler::HandleNearGraveCommand(), ChatHandler::HandleNearObjectCommand(), ChatHandler::HandleNpcMoveCommand(), WorldSession::HandlePlayerLogin(), ChatHandler::HandleSummonCommand(), ChatHandler::HandleTargetObjectCommand(), DisableMgr::IsDisabledFor(), Player::IsInAreaTriggerRadius(), MapManager::IsValidMapCoord(), Player::KillPlayer(), Player::LoadFromDB(), WorldObject::MovePositionToFirstCollision(), PathInfo::PathInfo(), Player::PrepareQuestMenu(), ObjectAccessor::RemoveCorpse(), Player::RepopAtGraveyard(), Player::RewardPlayerAndGroupAtKill(), Player::SaveRecallPosition(), Corpse::SaveToDB(), Creature::SaveToDB(), GameObject::SaveToDB(), Player::SaveToDB(), Player::SendInitialPacketsAfterAddToMap(), Map::SendInitTransports(), Player::SendInitWorldStates(), WorldSession::SendLearnNewTaxiNode(), Map::SendRemoveTransports(), WorldSession::SendSpiritResurrect(), WorldSession::SendTaxiMenu(), WorldSession::SendTaxiStatus(), Player::SetBattlegroundEntryPoint(), Pet::setDeathState(), Player::SetHomebindToLocation(), Spell::SetTargetMap(), CreatureEventAI::SpawnedEventConditionsCheck(), Player::TeleportTo(), Transport::Update(), FlightPathMovementGenerator::Update(), Map::Update(), Player::UpdateAreaDependentAuras(), Transport::UpdateForMap(), Player::UpdateZoneDependentAuras(), and WorldRelocate().

568  {
569  return m_mapId;
570  }
uint32 m_mapId
Definition: Object.h:572
void WorldLocation::WorldRelocate ( const WorldLocation loc)

Definition at line 562 of file Object.h.

References GetMapId().

563  {
564  m_mapId = loc.GetMapId();
565  Relocate(loc);
566  }
uint32 m_mapId
Definition: Object.h:572
void Relocate(float x, float y)
Definition: Position.h:65
uint32 GetMapId() const
Definition: Object.h:567

Member Data Documentation

uint32 WorldLocation::m_mapId

The documentation for this class was generated from the following file: