DIFF

class BoatScriptSource

BoatScript Boat Transport Pawn EntityAI Entity ObjectTyped Object IEntity Managed

All members, including inherited

Base script class for boats

Constructors 2

void ~BoatScript()

Constants 8

protected const int DECAY_PLAYER_RANGE = 300

when a player is found within this range, decay is deactivated

Referenced by DecayHealthTick()
protected const int DECAY_FLAG_RANGE = 100

when a boat is parked around a territoryflag, decay is deactivated

Referenced by IsInFlagRange()
protected const float DECAY_TICK_FREQUENCY = 10

seconds

Referenced by BoatScript()
protected const float DECAY_DAMAGE = 0.017
Referenced by DecayHealthTick()
protected const float DECAY_FLIPPED_MULT = 4
Referenced by DecayHealthTick()
protected const float SOUND_ENGINE_FADE = 0.2
Referenced by FadeEngineSound(), and OnSound()
protected const float SPLASH_THRESHOLD_CONDITION = 0.08

diff between sea surface and propeller pos which determines if the splash should happen

protected const float SPLASH_THRESHOLD = 0.18

diff between sea surface and propeller pos which determines when the splash happens

Members 29

private static ref map<typename, ref TInputActionMap> m_BoatTypeActionsMap = new map<typename, ref TInputActionMap>()
Referenced by InitializeActions()
private TInputActionMap m_InputActionMap
Referenced by AddAction(), GetActions(), InitializeActions()
Show 1 more, RemoveAction()
private bool m_ActionsInitialized
Referenced by AddAction(), and GetActions()
protected vector m_VelocityPrevTick
Referenced by EOnPostSimulate(), and OnContact()
protected float m_MomentumPrevTick
Referenced by EOnPostSimulate(), and OnContact()
protected ref VehicleContactData m_ContactData
Referenced by CheckContactCache(), and OnContact()
protected ref Timer m_DecayTimer
Referenced by ~BoatScript(), and BoatScript()
protected bool m_UpdateParticles
protected ref EffectBoatWaterBase m_WaterEffects[4]
protected bool m_SplashIncoming

boat is high enough for the splash to trigger when it falls back down to sea level

protected bool m_PlaySoundEngineStopNoFuel
protected bool m_PlaySoundImpactLight
protected bool m_PlaySoundImpactHeavy
protected bool m_PlaySoundPushBoat
protected bool m_IsEngineSoundFading
protected bool m_EngineFadeDirection

true>in | false>out

Referenced by FadeEngineSound(), and OnSound()
protected float m_EngineFadeTime
protected string m_SoundImpactLight
protected string m_SoundImpactHeavy
protected string m_SoundPushBoat
protected string m_SoundWaterSplash
protected string m_SoundEngineStart
protected string m_SoundEngineStop
protected string m_SoundEngineStartNoFuel
protected string m_SoundEngineStopNoFuel
protected ref EffectSound m_SoundPushBoatEffect
protected ref EffectSound m_SoundWaterSplashEffect
protected ref EffectSound m_SoundEngineEffect
Referenced by HandleEngineSound()
protected ref EffectSound m_SoundEngineEffectDeletion

hold engine sound which is being stopped & deleted while another is starting

Referenced by HandleEngineSound()

Methods 58

override void EEDelete(EntityAI parent)
void InitializeActions()
Referenced by GetActions()
override void GetActions(typename action_input_type, out array<ActionBase_Basic> actions)
override bool DisableVicinityIcon()
override string GetVehicleType()
override float GetTransportCameraDistance()
override vector GetTransportCameraOffset()
override int GetAnimInstance()
override int Get3rdPersonCameraType()
override bool CrewCanGetThrough(int posIdx)
override bool CanReachSeatFromSeat(int currentSeat, int nextSeat)
override bool CanReachSeatFromDoors(string pSeatSelection, vector pFromPos, float pDistance = 1.0)
override bool CanReachDoorsFromSeat(string pDoorsSelection, int pCurrentSeat)
override bool IsAreaAtDoorFree(int currentSeat, float maxAllowedObjHeight, inout vector extents, out vector transform[4])
override bool OnBeforeEngineStart()

Gets called everytime the game wants to start the engine.

Returns: true if the engine can start, false otherwise.

void OnIgnition()
override void OnEngineStart()
override void EEOnCECreate()
override void OnInput(float dt)
override void EOnFrame(IEntity other, float timeSlice)
override void EEHitBy(TotalDamageResult damageResult, int damageType, EntityAI source, int component, string dmgZone, string ammo, vector modelPos, float speedCoef)
override void MarkCrewMemberUnconscious(int crewMemberIndex)
override void MarkCrewMemberDead(int crewMemberIndex)
override void OnDriverExit(Human player)
protected void SyncSoundImpactLight()
Referenced by CheckContactCache()
protected void SyncSoundImpactHeavy()
Referenced by CheckContactCache()
protected void FadeEngineSound(bool fadeIn)
Referenced by OnEngineStart(), and OnEngineStop()
protected void FlipVehicle()
Referenced by OnAction()
protected void SetActions()
References AddAction()
Referenced by InitializeActions()
protected void UpdateParticles(float timeSlice = 0)
Referenced by EOnFrame()
protected void StopParticleUpdate()
Referenced by OnEngineStop()
override void GetDebugActions(out TSelectableActionInfoArrayEx outputList)
override bool OnAction(int action_id, Man player, ParamsReadContext ctx)
protected override event typename GetOwnerStateType()
protected override event typename GetMoveType()
override void FixEntity()DIAG_DEVELOPER