Arma Reforger Script API
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes | Static Protected Attributes | List of all members
SCR_TimeAndWeatherHandlerComponent Interface Reference
Inheritance diagram for SCR_TimeAndWeatherHandlerComponent:
[legend]

Public Member Functions

void SetupDaytimeAndWeather (int hours, int minutes, int seconds=0, string loadedWeatherState="", bool loadDone=false)
 
override void OnWorldPostProcess (World world)
 Called once loading of all entities of the world have been finished (still within the loading)
 
override void OnPostInit (IEntity owner)
 
- Public Member Functions inherited from SCR_BaseGameModeComponent
SCR_BaseGameMode GetGameMode ()
 
void OnGameEnd ()
 Called on all machines when the world ends.
 
void OnGameStateChanged (SCR_EGameModeState state)
 Called when game mode state changes called on all machines.
 
void OnGameModeStart ()
 Called on every machine when game mode starts.
 
void OnGameModeEnd (SCR_GameModeEndData data)
 Called when game mode ends.
 
void OnPlayerConnected (int playerId)
 Called after a player is connected.
 
void OnPlayerAuditSuccess (int playerId)
 Event is called when player connecting Session hosting current Game Mode where is required authentication verification via.
 
void OnPlayerAuditFail (int playerId)
 Event is called when player connecting Session hosting current Game Mode AuditFail() call may be called under two occasions: 1) verification is required but failed (account is not valid, player is banned, internet issues) 2) player cannot be verified as authentication is not required or possible - where it may be valid behavior (server online connectivity turned off for example) Basically non-audited player cannot access persistency/ etc.
 
void OnPlayerAuditTimeouted (int playerId)
 Event is called when player connected to Session was kicked and did not reconnected in time This mean that slot reservation can be canceled.
 
void OnPlayerAuditRevived (int playerId)
 Event is called when player reconnected successfully back to Session after kick This mean that slot reservation need to be finished (closed).
 
void OnPlayerRegistered (int playerId)
 Called on every machine after a player is registered (identity, name etc.).
 
void OnPlayerDisconnected (int playerId, KickCauseCode cause, int timeout)
 Called after a player is disconnected.
 
void OnPlayerSpawned (int playerId, IEntity controlledEntity)
 Called after a player is spawned.
 
bool PreparePlayerEntity_S (SCR_SpawnRequestComponent requestComponent, SCR_SpawnHandlerComponent handlerComponent, SCR_SpawnData data, IEntity entity)
 
void OnSpawnPlayerEntityFailure_S (SCR_SpawnRequestComponent requestComponent, SCR_SpawnHandlerComponent handlerComponent, IEntity entity, SCR_SpawnData data, SCR_ESpawnResult reason)
 
void OnPlayerSpawnFinalize_S (SCR_SpawnRequestComponent requestComponent, SCR_SpawnHandlerComponent handlerComponent, SCR_SpawnData data, IEntity entity)
 
bool HandlePlayerKilled (int playerId, IEntity playerEntity, IEntity killerEntity, notnull Instigator instigator)
 See SCR_BaseGameMode.HandlePlayerKilled.
 
void OnPlayerKilled (notnull SCR_InstigatorContextData instigatorContextData)
 Called after a player gets killed.
 
void OnPlayerKilledHandled (int playerId, IEntity playerEntity, IEntity killerEntity, notnull Instigator instigator)
 Called after player gets killed in cases where the kill was handled by the game mode, supressing the default OnPlayerKilled behaviour.
 
void OnPlayerDeleted (int playerId, IEntity player)
 Called after a player gets deleted.
 
void OnPlayerRoleChange (int playerId, EPlayerRole roleFlags)
 Called when player role changes.
 
void OnWorldPostProcess (World world)
 Called once loading of all entities of the world have been finished (still within the loading)
 
void HandleOnLoadoutAssigned (int playerID, SCR_BasePlayerLoadout assignedLoadout)
 What happens when a player is assigned a loadout.
 
void HandleOnFactionAssigned (int playerID, Faction assignedFaction)
 What happens when a player is assigned a faction.
 
void HandleOnSpawnPointAssigned (int playerID, SCR_SpawnPoint spawnPoint)
 What happens when a player is assigned a spawn point.
 
void OnControllableSpawned (IEntity entity)
 When a controllable entity is spawned, this event is raised.
 
void OnControllableDestroyed (notnull SCR_InstigatorContextData instigatorContextData)
 When a controllable entity is destroyed, this event is raised.
 
void OnControllableDeleted (IEntity entity)
 Prior to a controllable entity being DELETED, this event is raised.
 
void SCR_BaseGameModeComponent (IEntityComponentSource src, IEntity ent, IEntity parent)
 

Static Public Member Functions

static SCR_TimeAndWeatherHandlerComponent GetInstance ()
 

Static Public Attributes

const int DAYTIME_CHECK_PERIOD = 60000
 
const float DEFAULT_DAYTIME_START = 5.0
 
const float DEFAULT_DAYTIME_END = 19.0
 
const int DAY_DURATION = 24 * 60 * 60
 

Protected Member Functions

void HandleDaytimeAcceleration (bool setup=false)
 

Protected Attributes

int m_iStartingHours
 
int m_iStartingMinutes
 
bool m_bRandomStartingDaytime
 
bool m_bRandomStartingDaytimeRange
 
int m_iRangeHoursStart
 
int m_iRangeMinutesStart
 
int m_iRangeHoursEnd
 
int m_iRangeMinutesEnd
 
float m_fDayTimeAcceleration
 
float m_fNightTimeAcceleration
 
bool m_bRandomStartingWeather
 
bool m_bUsePredefineStartingTimeAndWeather
 
ref array< ref SCR_TimeAndWeatherStatem_aStartingWeatherAndTime
 
bool m_bRandomWeatherChanges
 
bool m_bAllowHeaderSettings
 
bool m_bDaytimeAcceleration = true
 
bool m_bSavedSettingApplied = false
 
- Protected Attributes inherited from SCR_BaseGameModeComponent
SCR_BaseGameMode m_pGameMode
 The game mode entity this component is attached to.
 

Static Protected Attributes

static SCR_TimeAndWeatherHandlerComponent s_Instance
 

Member Function Documentation

◆ GetInstance()

static SCR_TimeAndWeatherHandlerComponent SCR_TimeAndWeatherHandlerComponent.GetInstance ( )
static
Returns

◆ HandleDaytimeAcceleration()

void SCR_TimeAndWeatherHandlerComponent.HandleDaytimeAcceleration ( bool  setup = false)
protected

◆ OnPostInit()

override void SCR_TimeAndWeatherHandlerComponent.OnPostInit ( IEntity  owner)

◆ OnWorldPostProcess()

override void SCR_TimeAndWeatherHandlerComponent.OnWorldPostProcess ( World  world)

Called once loading of all entities of the world have been finished (still within the loading)

Parameters
[in]worldLoaded world

Implements SCR_BaseGameModeComponent.

◆ SetupDaytimeAndWeather()

void SCR_TimeAndWeatherHandlerComponent.SetupDaytimeAndWeather ( int  hours,
int  minutes,
int  seconds = 0,
string  loadedWeatherState = "",
bool  loadDone = false 
)
Parameters
[in]hours
[in]minutes
[in]seconds
[in]loadedWeatherState
[in]loadDone

Member Data Documentation

◆ DAY_DURATION

const int SCR_TimeAndWeatherHandlerComponent.DAY_DURATION = 24 * 60 * 60
static

◆ DAYTIME_CHECK_PERIOD

const int SCR_TimeAndWeatherHandlerComponent.DAYTIME_CHECK_PERIOD = 60000
static

◆ DEFAULT_DAYTIME_END

const float SCR_TimeAndWeatherHandlerComponent.DEFAULT_DAYTIME_END = 19.0
static

◆ DEFAULT_DAYTIME_START

const float SCR_TimeAndWeatherHandlerComponent.DEFAULT_DAYTIME_START = 5.0
static

◆ m_aStartingWeatherAndTime

ref array<ref SCR_TimeAndWeatherState> SCR_TimeAndWeatherHandlerComponent.m_aStartingWeatherAndTime
protected

◆ m_bAllowHeaderSettings

bool SCR_TimeAndWeatherHandlerComponent.m_bAllowHeaderSettings
protected

◆ m_bDaytimeAcceleration

bool SCR_TimeAndWeatherHandlerComponent.m_bDaytimeAcceleration = true
protected

◆ m_bRandomStartingDaytime

bool SCR_TimeAndWeatherHandlerComponent.m_bRandomStartingDaytime
protected

◆ m_bRandomStartingDaytimeRange

bool SCR_TimeAndWeatherHandlerComponent.m_bRandomStartingDaytimeRange
protected

◆ m_bRandomStartingWeather

bool SCR_TimeAndWeatherHandlerComponent.m_bRandomStartingWeather
protected

◆ m_bRandomWeatherChanges

bool SCR_TimeAndWeatherHandlerComponent.m_bRandomWeatherChanges
protected

◆ m_bSavedSettingApplied

bool SCR_TimeAndWeatherHandlerComponent.m_bSavedSettingApplied = false
protected

◆ m_bUsePredefineStartingTimeAndWeather

bool SCR_TimeAndWeatherHandlerComponent.m_bUsePredefineStartingTimeAndWeather
protected

◆ m_fDayTimeAcceleration

float SCR_TimeAndWeatherHandlerComponent.m_fDayTimeAcceleration
protected

◆ m_fNightTimeAcceleration

float SCR_TimeAndWeatherHandlerComponent.m_fNightTimeAcceleration
protected

◆ m_iRangeHoursEnd

int SCR_TimeAndWeatherHandlerComponent.m_iRangeHoursEnd
protected

◆ m_iRangeHoursStart

int SCR_TimeAndWeatherHandlerComponent.m_iRangeHoursStart
protected

◆ m_iRangeMinutesEnd

int SCR_TimeAndWeatherHandlerComponent.m_iRangeMinutesEnd
protected

◆ m_iRangeMinutesStart

int SCR_TimeAndWeatherHandlerComponent.m_iRangeMinutesStart
protected

◆ m_iStartingHours

int SCR_TimeAndWeatherHandlerComponent.m_iStartingHours
protected

◆ m_iStartingMinutes

int SCR_TimeAndWeatherHandlerComponent.m_iStartingMinutes
protected

◆ s_Instance

SCR_TimeAndWeatherHandlerComponent SCR_TimeAndWeatherHandlerComponent.s_Instance
staticprotected

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