TrinityCore
Loading...
Searching...
No Matches
GameObjectType::Transport Class Reference
+ Inheritance diagram for GameObjectType::Transport:

Public Member Functions

 Transport (GameObject &owner)
 
void Update (uint32 diff) override
 
void OnStateChanged (GOState oldState, GOState newState) override
 
void OnRelocated () override
 
void UpdatePassengerPositions ()
 
uint32 GetTransportPeriod () const
 
std::span< uint32 const > GetPauseTimes () const
 
ObjectGuid GetTransportGUID () const override
 
float GetTransportOrientation () const override
 
void AddPassenger (WorldObject *passenger, Position const &offset) override
 
TransportBaseRemovePassenger (WorldObject *passenger) override
 
Position GetPositionWithOffset (Position const &offset) const override
 This method transforms supplied transport offsets into global coordinates.
 
Position GetPositionOffsetTo (Position const &endPos) const override
 This method transforms supplied global coordinates into local offsets.
 
int32 GetMapIdForSpawning () const override
 
void SetAutoCycleBetweenStopFrames (bool on)
 
- Public Member Functions inherited from GameObjectTypeBase
 GameObjectTypeBase (GameObject &owner)
 
virtual ~GameObjectTypeBase ()=default
 
virtual bool IsNeverVisibleFor (WorldObject const *seer, bool allowServersideObjects) const
 
virtual void ActivateObject (GameObjectActions action, int32 param, WorldObject *spellCaster=nullptr, uint32 spellId=0, int32 effectIndex=-1)
 
- Public Member Functions inherited from TransportBase
void UpdatePassengerPosition (Map *map, WorldObject *passenger, Position const &position, bool setHomePosition)
 

Static Public Attributes

static constexpr Milliseconds PositionUpdateInterval = 50ms
 

Private Attributes

TransportAnimation const * _animationInfo
 
uint32 _pathProgress
 
uint32 _stateChangeTime
 
uint32 _stateChangeProgress
 
std::vector< uint32_stopFrames
 
bool _autoCycleBetweenStopFrames
 
TimeTracker _positionUpdateTimer
 
std::unordered_set< WorldObject * > _passengers
 

Additional Inherited Members

- Protected Member Functions inherited from TransportBase
 TransportBase ()
 
virtual ~TransportBase ()
 
- Protected Attributes inherited from GameObjectTypeBase
GameObject_owner
 

Detailed Description

Definition at line 138 of file GameObject.cpp.

Constructor & Destructor Documentation

◆ Transport()

GameObjectType::Transport::Transport ( GameObject owner)
inlineexplicit

Definition at line 143 of file GameObject.cpp.

+ Here is the call graph for this function:

Member Function Documentation

◆ AddPassenger()

void GameObjectType::Transport::AddPassenger ( WorldObject passenger,
Position const &  offset 
)
inlineoverridevirtual

Implements TransportBase.

Definition at line 444 of file GameObject.cpp.

+ Here is the call graph for this function:

◆ GetMapIdForSpawning()

int32 GameObjectType::Transport::GetMapIdForSpawning ( ) const
inlineoverridevirtual

Implements TransportBase.

Definition at line 483 of file GameObject.cpp.

+ Here is the call graph for this function:

◆ GetPauseTimes()

std::span< uint32 const > GameObjectType::Transport::GetPauseTimes ( ) const
inline

Definition at line 435 of file GameObject.cpp.

◆ GetPositionOffsetTo()

Position GameObjectType::Transport::GetPositionOffsetTo ( Position const &  endPos) const
inlineoverridevirtual

This method transforms supplied global coordinates into local offsets.

Implements TransportBase.

Definition at line 478 of file GameObject.cpp.

+ Here is the call graph for this function:

◆ GetPositionWithOffset()

Position GameObjectType::Transport::GetPositionWithOffset ( Position const &  offset) const
inlineoverridevirtual

This method transforms supplied transport offsets into global coordinates.

Implements TransportBase.

Definition at line 473 of file GameObject.cpp.

+ Here is the call graph for this function:

◆ GetTransportGUID()

ObjectGuid GameObjectType::Transport::GetTransportGUID ( ) const
inlineoverridevirtual

Implements TransportBase.

Definition at line 440 of file GameObject.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetTransportOrientation()

float GameObjectType::Transport::GetTransportOrientation ( ) const
inlineoverridevirtual

Implements TransportBase.

Definition at line 442 of file GameObject.cpp.

+ Here is the call graph for this function:

◆ GetTransportPeriod()

uint32 GameObjectType::Transport::GetTransportPeriod ( ) const
inline

Definition at line 427 of file GameObject.cpp.

+ Here is the caller graph for this function:

◆ OnRelocated()

void GameObjectType::Transport::OnRelocated ( )
inlineoverridevirtual

Reimplemented from GameObjectTypeBase.

Definition at line 416 of file GameObject.cpp.

+ Here is the call graph for this function:

◆ OnStateChanged()

void GameObjectType::Transport::OnStateChanged ( GOState  oldState,
GOState  newState 
)
inlineoverridevirtual

Reimplemented from GameObjectTypeBase.

Definition at line 357 of file GameObject.cpp.

+ Here is the call graph for this function:

◆ RemovePassenger()

TransportBase * GameObjectType::Transport::RemovePassenger ( WorldObject passenger)
inlineoverridevirtual

Implements TransportBase.

Definition at line 458 of file GameObject.cpp.

+ Here is the call graph for this function:

◆ SetAutoCycleBetweenStopFrames()

void GameObjectType::Transport::SetAutoCycleBetweenStopFrames ( bool  on)
inline

Definition at line 488 of file GameObject.cpp.

◆ Update()

void GameObjectType::Transport::Update ( uint32  diff)
inlineoverridevirtual

Reimplemented from GameObjectTypeBase.

Definition at line 192 of file GameObject.cpp.

+ Here is the call graph for this function:

◆ UpdatePassengerPositions()

void GameObjectType::Transport::UpdatePassengerPositions ( )
inline

Definition at line 421 of file GameObject.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ _animationInfo

TransportAnimation const* GameObjectType::Transport::_animationInfo
private

Definition at line 494 of file GameObject.cpp.

◆ _autoCycleBetweenStopFrames

bool GameObjectType::Transport::_autoCycleBetweenStopFrames
private

Definition at line 499 of file GameObject.cpp.

◆ _passengers

std::unordered_set<WorldObject*> GameObjectType::Transport::_passengers
private

Definition at line 501 of file GameObject.cpp.

◆ _pathProgress

uint32 GameObjectType::Transport::_pathProgress
private

Definition at line 495 of file GameObject.cpp.

◆ _positionUpdateTimer

TimeTracker GameObjectType::Transport::_positionUpdateTimer
private

Definition at line 500 of file GameObject.cpp.

◆ _stateChangeProgress

uint32 GameObjectType::Transport::_stateChangeProgress
private

Definition at line 497 of file GameObject.cpp.

◆ _stateChangeTime

uint32 GameObjectType::Transport::_stateChangeTime
private

Definition at line 496 of file GameObject.cpp.

◆ _stopFrames

std::vector<uint32> GameObjectType::Transport::_stopFrames
private

Definition at line 498 of file GameObject.cpp.

◆ PositionUpdateInterval

constexpr Milliseconds GameObjectType::Transport::PositionUpdateInterval = 50ms
staticconstexpr

Definition at line 141 of file GameObject.cpp.


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