144 "pipe_creaking_sound_pos_1",
145 "pipe_creaking_sound_pos_2",
146 "pipe_creaking_sound_pos_3",
147 "pipe_creaking_sound_pos_4"
304 super.OnVariablesSynchronized();
372 RegisterNetSyncVariableInt(
"m_ValveStatesPacked", 0);
373 RegisterNetSyncVariableInt(
"m_ValveManipulatedIndex", -1,
VALVES_COUNT - 1);
374 RegisterNetSyncVariableInt(
"m_WaterLevelActual",
WL_MIN,
WL_MAX);
375 RegisterNetSyncVariableInt(
"m_WaterLevelPrev",
WL_MIN,
WL_MAX);
398 GetGame().RegisterNetworkStaticObject(
this);
865 pos = ModelToWorld(pos);
868 ErrorEx(
string.Format(
"Memory point %1 not found, falling back to vector.Zero",
pMemoryPoint));
Param4< int, int, string, int > TSelectableActionInfoWithColor
ActionTurnValveUndergroundReservoirCB ActionTurnValveCB ActionTurnValveUndergroundReservoir()
void AddAction(typename actionName)
override void OnVariablesSynchronized()
const int ECE_CREATEPHYSICS
override bool OnAction(int action_id, Man player, ParamsReadContext ctx)
override void GetDebugActions(out TSelectableActionInfoArrayEx outputList)
ref ParticleSourceArray m_PipeBrokenParticles
ref array< ref PressureLevelSettings > m_DrainValvePressureDeanimationSettings
float m_WaterLevelHeightActual
void RegisterValve(string pCompName, int pIndex)
const int PIPE_INDEX_BROKEN1
override void EOnPostSimulate(IEntity other, float timeSlice)
ref ParticleSourceArray m_ValveParticles
ref map< string, vector > m_WaterLevelsAvailable
const string SOUND_NAME_PIPE_SPRINKLING_START
void SetDefaultPressureLevelStageSettings(int pValveIndex)
bool IsValvePressureLevelGaugeAtBase(int pValveIndex)
int m_ValveManipulatedIndexPrev
void HandleSoundEffectsWaterLevelMovementSounds()
const string SOUND_NAME_PIPE_CREAKING
ref array< ref PressureLevelSettings > m_FillValvePressureStageSettings
override bool HasTurnableValveBehavior()
const string ANIM_PHASE_VALVE_GAUGE_FILL
const int PARTICLE_FILL_PIPE_JET
PressureLevelSettings ActualPressureLevelStageSettings(int pValveIndex, bool pDeanimationRequest=false)
ref array< ref PressureLevelSettings > m_FillValvePressureDeanimationSettings
const string SOUND_NAME_WATER_FILL_LOOP
static const string WATER_LEVEL_MIN
const int PARTICLE_FILL_PIPE_MAX_PRESSURE
ref array< ref WaterLevelSettings > m_DrainValveWaterStageSettings
valve/pipe stages for water and pressure levels
int m_DrainValvePressureLevelStageIndex
ref array< ref WaterLevelSettings > m_FillValveWaterStageSettings
for deanimation purposes
ref EffectSound m_WaterLevelMovementSound
const string VALVE_NAME_FILL
const string WATER_LEVELS[WATER_LEVELS_COUNT]
void PlayPipeCreakingSoundOnLocation()
ref array< bool > m_PressureDeanimationRequests
const string PIPE_NAME_BROKEN1
const string ANIM_PHASE_VALVE_FILL
WaterLevelSettings ActualWaterLevelStageSettings(int pValveIndex)
void OnValveManipulationStart(int pValveIndex)
void SetLastActiveValve(int pValveIndex)
void HandleSoundEffectsUnderwaterPipeSounds()
const string PIPE_NAME_LEAKING_DRAIN
const int PARTICLE_DRAIN_PIPE_MAX_PRESSURE
class WaterLevelSettings PressureLevel
const string SOUND_NAME_PIPE_SPRINKLING_LOOP2
void AdvanceToNextPressureLevelStageSettings(int pValveIndex)
bool m_ValveManipulationSoundRequested
VFX/SFX.
ref array< ref PressureLevelSettings > m_DrainValvePressureStageSettings
const string SOUND_NAME_VALVE_MANIPULATION
const int VALVE_INDEX_DRAIN
const string ANIM_PHASE_VALVE_DRAIN
PressureLevelSettings PreviousPressureLevelStageSettings(int pValveIndex, bool pDeanimationRequest=false)
const string SOUND_NAME_WATER_DRAIN_LOOP
int PackArrayOfBoolStatesIntoBits(array< bool > pStates)
void SetWaterLevelHeight(float pHeight)
void OnValveManipulationEnd(int pValveIndex)
ref array< bool > m_ValveStates
void SetValvePressureLevelGauge(int pValveIndex, float pValue)
ref array< string > m_ValveNames
array< bool > UnpackBitsToArrayOfBoolStates(int pPackedBits, int pArrayLength)
float WaterLevelToHeight(int pWaterLevel)
void Land_Underground_WaterReservoir()
array< vector > GetValveAligningPointsWS(int pValveIndex)
void HandleSoundEffectsPipeCreaking()
ref EffectSound m_ValveManipulationSound
const string PIPE_NAME_LEAKING_FILL
float GetValvePressureLevelGauge(int pValveIndex)
static const string WATER_LEVEL_MAX
const int PIPE_CREAKING_SOUND_LOCATIONS_COUNT
const int PIPE_INDEX_BROKEN2
main broken pipe
void OnValveManipulationCanceled(int pValveIndex)
bool m_PipeCreakingSoundRequested
ref array< float > m_PressureTimesAccumulated
WaterLevelSettings PreviousWaterLevelStageSettings(int pValveIndex)
const int WATER_LEVELS_COUNT
bool IsValveActive(int pValveIndex)
ref array< EffectSound > m_PipeSounds
override bool IsValveTurnable(int pValveIndex)
const int PARTICLE_FILL_PIPE_JET_WEAK
const string PIPE_CREAKING_SOUND_LOCATIONS[PIPE_CREAKING_SOUND_LOCATIONS_COUNT]
static const string WATER_LEVEL_ABOVE_PIPES
void AdvanceToNextWaterLevelStageSettings(int pValveIndex)
const string VALVE_NAME_DRAIN
void HandleSoundEffects()
const int PIPE_CREAKING_MIN_TIME_DELAY_MS
float PressureLevelToValue(int pPressureLevel)
void ~Land_Underground_WaterReservoir()
const int VALVE_INDEX_FILL
void HandleSoundEffectsPipeSprinkling()
const string SOUND_NAME_PIPE_SPRINKLING_LOOP1
ref WaterLevelSnapshot m_WaterLevelSnapshot
for deanimation purposes
int m_DrainValveWaterLevelStageIndex
pointing to specific stage for each valve/pipe
const int PIPES_BROKEN_COUNT
int m_FillValveWaterLevelStageIndex
override int GetTurnableValveIndex(int pComponentIndex)
float AdjustTime(float originalTime)
const string SOUND_NAME_UPIPE_SPRINKLING_START
const string PIPE_NAME_BROKEN2
void SyncValveVariables()
const string SOUND_NAME_UPIPE_SPRINKLING_END
int m_ValveStatesPackedPrev
int HeightToWaterLevel(float pHeight)
ref array< float > m_WaterLevelTimesAccumulated
void TranslateMemoryPointsToWaterLevels()
int m_ValveManipulatedIndex
int m_FillValvePressureLevelStageIndex
Object m_SpawnedWaterObject
void AnimateValve(int pValveIndex, float pPhase)
ref EffectSound m_PipeUnderwaterSound
ref array< bool > m_PressureAnimationRequests
class WaterLevelSnapshot OBJECT_NAME_WATER_PLANE
const string SOUND_NAME_PIPE_SPRINKLING_END
const string SOUND_NAME_UPIPE_SPRINKLING_LOOP
ref EffectSound m_PipeCreakingSounds
static const string WATER_LEVEL_AVERAGE
vector m_WaterLevelDefault
const string ANIM_PHASE_VALVE_GAUGE_DRAIN
tighter broken pipe
void PlayValveManipulationSound()
void PressureLevelSettings(int pPressureLevel, float pDuration)
void CleanVisualEffects()
const int PIPE_CREAKING_MAX_TIME_DELAY_MS
void ConfigureValvesAndGaugesCourse()
vector GetMemoryPointPosition(string pMemoryPoint)
void HandleVisualEffects()
void ParticleManager(ParticleManagerSettings settings)
Constructor (ctor)
array< ParticleSource > ParticleSourceArray
Input value between 0 and 1, returns value adjusted by easing, no automatic clamping of input(do your...
static float EaseInOutSine(float t)
Wrapper class for managing sound through SEffectManager.
static const int WATER_JET
static const int WATER_JET_WEAK
static const int WATER_SPILLING
Manager class for managing Effect (EffectParticle, EffectSound)
static bool DestroySound(EffectSound sound_effect)
Legacy, backwards compatibility.
Serialization general interface. Serializer API works with:
void WaterLevelSettings(int pWaterLevel, float pDuration)
const int INDEX_NOT_FOUND
proto native CGame GetGame()
EntityEvent
Entity events for event-mask, or throwing event from code.
proto native vector Vector(float x, float y, float z)
Vector constructor from components.
static proto float Lerp(float a, float b, float time)
Linearly interpolates between 'a' and 'b' given 'time'.
static proto float Clamp(float value, float min, float max)
Clamps 'value' to 'min' if it is lower than 'min', or to 'max' if it is higher than 'max'.
static proto int RandomInt(int min, int max)
Returns a random int number between and min [inclusive] and max [exclusive].
const int SAT_DEBUG_ACTION