Arma Reforger Explorer 1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Loading...
Searching...
No Matches
SCR_SpawnPoint Class Reference

Spawn point entity defines positions on which players can possibly spawn. More...

Inheritance diagram for SCR_SpawnPoint:
SCR_CampaignSpawnPointGroup SCR_DeployableSpawnPoint SCR_RestrictedDeployableSpawnPoint

Protected Member Functions

bool IsSpawnPointVisibleForPlayer (int pid)
bool IsSpawnPointEnabled ()
void SetSpawnPointEnabled_S (bool enabled)
void OnSetEnabled ()
ScriptInvokerBool GetOnSpawnPointEnabled ()
float GetRespawnTime ()
void SetRespawnTime (float time)
int GetPriority ()
void SetPriority (int priority)
bool CanReserveFor_S (int playerId, out SCR_ESpawnResult result=SCR_ESpawnResult.SPAWN_NOT_ALLOWED)
bool IsReservedFor_S (int playerId)
bool ReserveFor_S (int playerId)
void ClearReservationFor_S (int playerId)
float GetSpawnRadius ()
void SetSpawnRadius (float radius)
RplId GetRplId ()
bool GetEmptyPositionAndRotationInRange (out vector pos, out vector rot)
void SetUseNearbySpawnPositions (bool use)
bool IsSpawnPointRandom ()
void GetPositionAndRotation (out vector pos, out vector rot)
bool IsSpawnPointActive ()
bool GetVisibleInDeployMapOnly ()
void SetVisibleInDeployMapOnly (bool visible)
void ApplyFactionChange (FactionAffiliationComponent owner, Faction previousFaction, Faction newFaction)
void SetFaction (Faction faction)
void SetFactionKey (string factionKey)
void OnSetFactionKey ()
void SetSpawnPositionRange (float range)
float GetSpawnPositionRange ()
array< SCR_PositionGetChildSpawnPoints ()
string GetFactionKey ()
void InitFactionAffiliation (IEntity owner)
override bool RplSave (ScriptBitWriter writer)
bool RplLoad (ScriptBitReader reader)
void SCR_SpawnPoint (IEntitySource src, IEntity parent)
void ~SCR_SpawnPoint ()
bool GetRandomPositionAndRotation (out vector vOutPosition, out vector vOutRotation)

Static Protected Member Functions

static SCR_SpawnPointFinalizeSpawn_Invoker GetOnSpawnPointFinalizeSpawn ()
static void ShowSpawnPointDescriptors (bool show, Faction faction)
static SCR_SpawnPoint GetSpawnPointByRplId (RplId id)
static SCR_SpawnPoint GetSpawnPointByIndex (int spawnPointIndex)
 Return spawn point or null if out of bounds.
static int GetSpawnPointIndex (SCR_SpawnPoint spawnPoint)
 Return spawn point index or -1 if not existent.
static int CountSpawnPoints ()

Protected Attributes

RplComponent m_RplComponent
float m_fSpawnRadius = 10
float m_fPlayerCylinderRadius = 0.5
float m_fPlayerCylinderHeight = 2
float m_fColliderWidth = m_fPlayerCylinderRadius * 1.73205
float m_fColliderHeight = m_fPlayerCylinderRadius * 2
vector m_vCylinderVectorOffset = Vector(0, m_fPlayerCylinderHeight * 0.5, 0)
float m_fRandomSpawnRadius
string m_sFaction
bool m_bShowInDeployMapOnly
bool m_bTimedSpawnPoint
int m_iPriority
SCR_UIInfo m_LinkedInfo
SCR_FactionAffiliationComponent m_FactionAffiliationComponent
ref SCR_UIInfo m_Info
bool m_bUseNearbySpawnPositions
float m_fSpawnPositionUsageRange
float m_fRespawnTime
bool m_bForcedPosition
bool m_bRandomizedSpawn
int m_iRandomSpawnMaxAttempts
string m_sSpawnPointName
ref array< SCR_Positionm_aChildren = {}
ref set< intm_ReservationLocks = new set<int>()
ref ScriptInvokerBool m_OnSetSpawnPointEnabled
bool m_bSpawnPointEnabled

Static Protected Attributes

static ref SCR_SpawnPointNameChanged_Invoker OnSpawnPointNameChanged = new SCR_SpawnPointNameChanged_Invoker()

Detailed Description

Spawn point entity defines positions on which players can possibly spawn.

Definition at line 27 of file SCR_SpawnPoint.c.

Constructor & Destructor Documentation

◆ SCR_SpawnPoint()

void SCR_SpawnPoint::SCR_SpawnPoint ( IEntitySource src,
IEntity parent )
inlineprotected

Definition at line 825 of file SCR_SpawnPoint.c.

◆ ~SCR_SpawnPoint()

void SCR_SpawnPoint::~SCR_SpawnPoint ( )
inlineprotected

Definition at line 832 of file SCR_SpawnPoint.c.

Member Function Documentation

◆ ApplyFactionChange()

void SCR_SpawnPoint::ApplyFactionChange ( FactionAffiliationComponent owner,
Faction previousFaction,
Faction newFaction )
inlineprotected

Definition at line 454 of file SCR_SpawnPoint.c.

◆ CanReserveFor_S()

bool SCR_SpawnPoint::CanReserveFor_S ( int playerId,
out SCR_ESpawnResult result = SCR_ESpawnResult.SPAWN_NOT_ALLOWED )
inlineprotected

Authority: Returns whether this point can be reserved for provided player. Derived logic can e.g. check amount of pending locks versus available compartments for vehicle spawn points and similar.

Parameters
playerIdPlayerId of player who wants to reserve this point
[out]resultReason why respawn is disabled. Note that if returns true the reason will always be OK
Returns
Return true if reservation can proceed, false otherwise.

Definition at line 191 of file SCR_SpawnPoint.c.

◆ ClearReservationFor_S()

void SCR_SpawnPoint::ClearReservationFor_S ( int playerId)
inlineprotected

Authority: Clears reservation for provided player.

Parameters
playerIdPlayerId of player to check reservation for.

Definition at line 244 of file SCR_SpawnPoint.c.

◆ CountSpawnPoints()

int SCR_SpawnPoint::CountSpawnPoints ( )
inlinestaticprotected
Returns
Number of spawn points in the world

Definition at line 436 of file SCR_SpawnPoint.c.

◆ GetChildSpawnPoints()

array< SCR_Position > SCR_SpawnPoint::GetChildSpawnPoints ( )
inlineprotected

Definition at line 496 of file SCR_SpawnPoint.c.

◆ GetEmptyPositionAndRotationInRange()

bool SCR_SpawnPoint::GetEmptyPositionAndRotationInRange ( out vector pos,
out vector rot )
inlineprotected

Definition at line 328 of file SCR_SpawnPoint.c.

◆ GetFactionKey()

string SCR_SpawnPoint::GetFactionKey ( )
inlineprotected
Returns
string name of the faction of the spawn point.

Definition at line 503 of file SCR_SpawnPoint.c.

◆ GetOnSpawnPointEnabled()

ScriptInvokerBool SCR_SpawnPoint::GetOnSpawnPointEnabled ( )
inlineprotected

Definition at line 135 of file SCR_SpawnPoint.c.

◆ GetOnSpawnPointFinalizeSpawn()

SCR_SpawnPointFinalizeSpawn_Invoker SCR_SpawnPoint::GetOnSpawnPointFinalizeSpawn ( )
inlinestaticprotected

Definition at line 144 of file SCR_SpawnPoint.c.

◆ GetPositionAndRotation()

void SCR_SpawnPoint::GetPositionAndRotation ( out vector pos,
out vector rot )
inlineprotected

Definition at line 374 of file SCR_SpawnPoint.c.

◆ GetPriority()

int SCR_SpawnPoint::GetPriority ( )
inlineprotected

Definition at line 166 of file SCR_SpawnPoint.c.

◆ GetRandomPositionAndRotation()

bool SCR_SpawnPoint::GetRandomPositionAndRotation ( out vector vOutPosition,
out vector vOutRotation )
inlineprotected

Definition at line 852 of file SCR_SpawnPoint.c.

◆ GetRespawnTime()

float SCR_SpawnPoint::GetRespawnTime ( )
inlineprotected

Definition at line 153 of file SCR_SpawnPoint.c.

◆ GetRplId()

RplId SCR_SpawnPoint::GetRplId ( )
inlineprotected

Returns RplId of this spawn point.

Definition at line 302 of file SCR_SpawnPoint.c.

◆ GetSpawnPointByIndex()

SCR_SpawnPoint SCR_SpawnPoint::GetSpawnPointByIndex ( int spawnPointIndex)
inlinestaticprotected

Return spawn point or null if out of bounds.

Definition at line 411 of file SCR_SpawnPoint.c.

◆ GetSpawnPointByRplId()

SCR_SpawnPoint SCR_SpawnPoint::GetSpawnPointByRplId ( RplId id)
inlinestaticprotected

Definition at line 311 of file SCR_SpawnPoint.c.

◆ GetSpawnPointIndex()

int SCR_SpawnPoint::GetSpawnPointIndex ( SCR_SpawnPoint spawnPoint)
inlinestaticprotected

Return spawn point index or -1 if not existent.

Definition at line 421 of file SCR_SpawnPoint.c.

◆ GetSpawnPositionRange()

float SCR_SpawnPoint::GetSpawnPositionRange ( )
inlineprotected

Definition at line 490 of file SCR_SpawnPoint.c.

◆ GetSpawnRadius()

float SCR_SpawnPoint::GetSpawnRadius ( )
inlineprotected
Returns
Radius in which players can be spawned on empty position.

Definition at line 261 of file SCR_SpawnPoint.c.

◆ GetVisibleInDeployMapOnly()

bool SCR_SpawnPoint::GetVisibleInDeployMapOnly ( )
inlineprotected

Definition at line 442 of file SCR_SpawnPoint.c.

◆ InitFactionAffiliation()

void SCR_SpawnPoint::InitFactionAffiliation ( IEntity owner)
inlineprotected

Definition at line 789 of file SCR_SpawnPoint.c.

◆ IsReservedFor_S()

bool SCR_SpawnPoint::IsReservedFor_S ( int playerId)
inlineprotected

Authority: Returns whether this point is currently reserved for provided player.

Parameters
playerIdPlayerId of player to check reservation for.
Returns
Return true if reservation can proceed, false otherwise.

Definition at line 211 of file SCR_SpawnPoint.c.

◆ IsSpawnPointActive()

bool SCR_SpawnPoint::IsSpawnPointActive ( )
inlineprotected

Definition at line 427 of file SCR_SpawnPoint.c.

◆ IsSpawnPointEnabled()

bool SCR_SpawnPoint::IsSpawnPointEnabled ( )
inlineprotected

Definition at line 111 of file SCR_SpawnPoint.c.

◆ IsSpawnPointRandom()

bool SCR_SpawnPoint::IsSpawnPointRandom ( )
inlineprotected

Definition at line 368 of file SCR_SpawnPoint.c.

◆ IsSpawnPointVisibleForPlayer()

bool SCR_SpawnPoint::IsSpawnPointVisibleForPlayer ( int pid)
inlineprotected

Definition at line 105 of file SCR_SpawnPoint.c.

◆ OnSetEnabled()

void SCR_SpawnPoint::OnSetEnabled ( )
inlineprotected

Definition at line 128 of file SCR_SpawnPoint.c.

◆ OnSetFactionKey()

void SCR_SpawnPoint::OnSetFactionKey ( )
inlineprotected

Definition at line 478 of file SCR_SpawnPoint.c.

◆ ReserveFor_S()

bool SCR_SpawnPoint::ReserveFor_S ( int playerId)
inlineprotected

Authority: Returns whether this point is currently reserved for provided player.

Parameters
playerIdPlayerId of player to check reservation for.
Returns
Return true if reservation can proceed, false otherwise.

Definition at line 223 of file SCR_SpawnPoint.c.

◆ RplLoad()

bool SCR_SpawnPoint::RplLoad ( ScriptBitReader reader)
inlineprotected

Definition at line 810 of file SCR_SpawnPoint.c.

◆ RplSave()

override bool SCR_SpawnPoint::RplSave ( ScriptBitWriter writer)
inlineprotected

Definition at line 802 of file SCR_SpawnPoint.c.

◆ SetFaction()

void SCR_SpawnPoint::SetFaction ( Faction faction)
inlineprotected

Definition at line 460 of file SCR_SpawnPoint.c.

◆ SetFactionKey()

void SCR_SpawnPoint::SetFactionKey ( string factionKey)
inlineprotected

Definition at line 469 of file SCR_SpawnPoint.c.

◆ SetPriority()

void SCR_SpawnPoint::SetPriority ( int priority)
inlineprotected

Definition at line 172 of file SCR_SpawnPoint.c.

◆ SetRespawnTime()

void SCR_SpawnPoint::SetRespawnTime ( float time)
inlineprotected

Definition at line 159 of file SCR_SpawnPoint.c.

◆ SetSpawnPointEnabled_S()

void SCR_SpawnPoint::SetSpawnPointEnabled_S ( bool enabled)
inlineprotected

Definition at line 117 of file SCR_SpawnPoint.c.

◆ SetSpawnPositionRange()

void SCR_SpawnPoint::SetSpawnPositionRange ( float range)
inlineprotected

Definition at line 484 of file SCR_SpawnPoint.c.

◆ SetSpawnRadius()

void SCR_SpawnPoint::SetSpawnRadius ( float radius)
inlineprotected

Definition at line 268 of file SCR_SpawnPoint.c.

◆ SetUseNearbySpawnPositions()

void SCR_SpawnPoint::SetUseNearbySpawnPositions ( bool use)
inlineprotected

Definition at line 362 of file SCR_SpawnPoint.c.

◆ SetVisibleInDeployMapOnly()

void SCR_SpawnPoint::SetVisibleInDeployMapOnly ( bool visible)
inlineprotected

Definition at line 448 of file SCR_SpawnPoint.c.

◆ ShowSpawnPointDescriptors()

void SCR_SpawnPoint::ShowSpawnPointDescriptors ( bool show,
Faction faction )
inlinestaticprotected

Definition at line 274 of file SCR_SpawnPoint.c.

Member Data Documentation

◆ m_aChildren

ref array<SCR_Position> SCR_SpawnPoint::m_aChildren = {}
protected

Definition at line 91 of file SCR_SpawnPoint.c.

◆ m_bForcedPosition

bool SCR_SpawnPoint::m_bForcedPosition
protected

Definition at line 68 of file SCR_SpawnPoint.c.

◆ m_bRandomizedSpawn

bool SCR_SpawnPoint::m_bRandomizedSpawn
protected

Definition at line 71 of file SCR_SpawnPoint.c.

◆ m_bShowInDeployMapOnly

bool SCR_SpawnPoint::m_bShowInDeployMapOnly
protected

Definition at line 44 of file SCR_SpawnPoint.c.

◆ m_bSpawnPointEnabled

bool SCR_SpawnPoint::m_bSpawnPointEnabled
protected

Definition at line 102 of file SCR_SpawnPoint.c.

◆ m_bTimedSpawnPoint

bool SCR_SpawnPoint::m_bTimedSpawnPoint
protected

Definition at line 47 of file SCR_SpawnPoint.c.

◆ m_bUseNearbySpawnPositions

bool SCR_SpawnPoint::m_bUseNearbySpawnPositions
protected

Definition at line 59 of file SCR_SpawnPoint.c.

◆ m_FactionAffiliationComponent

SCR_FactionAffiliationComponent SCR_SpawnPoint::m_FactionAffiliationComponent
protected

Definition at line 53 of file SCR_SpawnPoint.c.

◆ m_fColliderHeight

float SCR_SpawnPoint::m_fColliderHeight = m_fPlayerCylinderRadius * 2
protected

Definition at line 34 of file SCR_SpawnPoint.c.

◆ m_fColliderWidth

float SCR_SpawnPoint::m_fColliderWidth = m_fPlayerCylinderRadius * 1.73205
protected

Definition at line 33 of file SCR_SpawnPoint.c.

◆ m_fPlayerCylinderHeight

float SCR_SpawnPoint::m_fPlayerCylinderHeight = 2
protected

Definition at line 32 of file SCR_SpawnPoint.c.

◆ m_fPlayerCylinderRadius

float SCR_SpawnPoint::m_fPlayerCylinderRadius = 0.5
protected

Definition at line 31 of file SCR_SpawnPoint.c.

◆ m_fRandomSpawnRadius

float SCR_SpawnPoint::m_fRandomSpawnRadius
protected

Definition at line 38 of file SCR_SpawnPoint.c.

◆ m_fRespawnTime

float SCR_SpawnPoint::m_fRespawnTime
protected

Definition at line 65 of file SCR_SpawnPoint.c.

◆ m_fSpawnPositionUsageRange

float SCR_SpawnPoint::m_fSpawnPositionUsageRange
protected

Definition at line 62 of file SCR_SpawnPoint.c.

◆ m_fSpawnRadius

float SCR_SpawnPoint::m_fSpawnRadius = 10
protected

Definition at line 30 of file SCR_SpawnPoint.c.

◆ m_Info

ref SCR_UIInfo SCR_SpawnPoint::m_Info
protected

Definition at line 56 of file SCR_SpawnPoint.c.

◆ m_iPriority

int SCR_SpawnPoint::m_iPriority
protected

Definition at line 50 of file SCR_SpawnPoint.c.

◆ m_iRandomSpawnMaxAttempts

int SCR_SpawnPoint::m_iRandomSpawnMaxAttempts
protected

Definition at line 74 of file SCR_SpawnPoint.c.

◆ m_LinkedInfo

SCR_UIInfo SCR_SpawnPoint::m_LinkedInfo
protected

Definition at line 52 of file SCR_SpawnPoint.c.

◆ m_OnSetSpawnPointEnabled

ref ScriptInvokerBool SCR_SpawnPoint::m_OnSetSpawnPointEnabled
protected

Definition at line 99 of file SCR_SpawnPoint.c.

◆ m_ReservationLocks

ref set<int> SCR_SpawnPoint::m_ReservationLocks = new set<int>()
protected

Authority: Set of all pending players that have a reservation for this spawn point.

Definition at line 97 of file SCR_SpawnPoint.c.

◆ m_RplComponent

RplComponent SCR_SpawnPoint::m_RplComponent
protected

Definition at line 29 of file SCR_SpawnPoint.c.

◆ m_sFaction

string SCR_SpawnPoint::m_sFaction
protected

Definition at line 41 of file SCR_SpawnPoint.c.

◆ m_sSpawnPointName

string SCR_SpawnPoint::m_sSpawnPointName
protected

Definition at line 86 of file SCR_SpawnPoint.c.

◆ m_vCylinderVectorOffset

vector SCR_SpawnPoint::m_vCylinderVectorOffset = Vector(0, m_fPlayerCylinderHeight * 0.5, 0)
protected

Definition at line 35 of file SCR_SpawnPoint.c.

◆ OnSpawnPointNameChanged

ref SCR_SpawnPointNameChanged_Invoker SCR_SpawnPoint::OnSpawnPointNameChanged = new SCR_SpawnPointNameChanged_Invoker()
staticprotected

Definition at line 88 of file SCR_SpawnPoint.c.


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