All Classes Functions Typedefs
Public Member Functions | List of all members
EnjoLib::MFDGoodies::MFDData Class Reference

Class used for storing a given vessel's data. More...

#include <MFDData.hpp>

Inheritance diagram for EnjoLib::MFDGoodies::MFDData:
MyMFDData

Public Member Functions

 MFDData (VESSEL *vessel)
 Default constructor.
virtual ~MFDData ()
 Destructor.
virtual void Update ()=0
 Updates the vessel's state.
VESSEL * GetVessel () const
 Returns associated vessel.
void Invalidate ()
 Sets this object as invalid.
bool IsValid () const
 Checks if this object is still valid.

Detailed Description

Class used for storing a given vessel's data.

Stores a given vessel's data, that can be retrieved later, or updated on every MFD refresh, or every simulation step if needed.

Constructor & Destructor Documentation

MFDData::MFDData ( VESSEL *  vessel)

Default constructor.

Constructs MFDData object for a given vessel.

Should only be called from within PluginMultipleVessels::AssociateMFDData().

Parameters
vesselpassed by PluginMultipleVessels::AssociateMFDData()

Member Function Documentation

VESSEL * MFDData::GetVessel ( ) const

Returns associated vessel.

Returns the vessel associated with this object

void MFDData::Invalidate ( )

Sets this object as invalid.

Sets this object as invalid in the event of deleting the associated vessel.

Called automatically from PluginMultipleVessels::DeleteVessel().

bool MFDData::IsValid ( ) const

Checks if this object is still valid.

    Checks if this object is still, because it may have been invalidated

upon vessel deletion. In such case, no operations should be performed on this object.

virtual void EnjoLib::MFDGoodies::MFDData::Update ( )
pure virtual

Updates the vessel's state.

Updates the vessel's state as in for example - position, velocity, reference planet, etc.

Should be called from MyMFDMultipleVessels::Update() and on every simulation step from PluginMultipleVessels::UpdateClient() if necessary. This method should update all the required data of the vessel to be able operate properly without an opened MFD.

Implemented in MyMFDData.


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