IVehicleAction

Interface used to implement a special behavior that affect the vehicle

C++
struct IVehicleAction : public IVehicleObject {
};
File

IVehicleSystem.h

Description

In example, landing gears on flying vehicles or the entering procedure for the player are implemented as vehicle action.

IVehicleAction::GetId Method
C++
virtual TVehicleObjectId GetId() = 0;
Description
IVehicleAction::Init Method
C++
virtual bool Init(IVehicle* pVehicle, const CVehicleParams& table) = 0;
IVehicleAction::OnEvent Method
C++
virtual int OnEvent(int eventType, SVehicleEventParams& eventParams) = 0;
IVehicleAction::Release Method
C++
virtual void Release() = 0;
IVehicleAction::Reset Method
C++
virtual void Reset() = 0;
IVehicleAction::Serialize Method

Serialize the vehicle object

C++
virtual void Serialize(TSerialize ser, EEntityAspects aspects) = 0;
IVehicleAction::Update Method

Update the vehicle object

C++
virtual void Update(const float deltaTime) = 0;
Parameters
Parameters
Description
const float deltaTime
total time for the update, in seconds
Description

Used to handle any time sensitive updates. In example, rotation for turret parts is implemented in this function.