Arma Reforger Script API
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
SCR_WallGroup Interface Reference

Collection of wall pair data objects into a single wall group. More...

Public Member Functions

SCR_WallPair GetRandomWall ()
 Get a random wall piece, respecting piece weights.
 

Public Attributes

ref array< ref SCR_WallPairm_aWallPairs = {}
 
ref array< float > m_aWeights = {}
 
float m_fWallLength
 

Detailed Description

Collection of wall pair data objects into a single wall group.

Wall group is meant to group walls of the same length. It's possible to add shorter wall(s) to a wall group as well(a feature required by map designers), but the wall group as a whole is considered to have only a single length(that of the longest wall in the wallgroup) and when considering which wall group is selected during generation, it's the wall group length as a whole that's being considered, not individual walls within the group. When placing the walls during wall generation, after it's already been decided which wall group will satisfy the length requirenment, and after a particular wall pair was selected based on the weights, the actual prefab is placed in the world and the exact length of this prefab is then deducted from the remaining segment(so no gap is created by possibly using a shorter variance).

Member Function Documentation

◆ GetRandomWall()

SCR_WallPair SCR_WallGroup.GetRandomWall ( )

Get a random wall piece, respecting piece weights.

Returns
a weighted, random wall pair

Member Data Documentation

◆ m_aWallPairs

ref array<ref SCR_WallPair> SCR_WallGroup.m_aWallPairs = {}

◆ m_aWeights

ref array<float> SCR_WallGroup.m_aWeights = {}

◆ m_fWallLength

float SCR_WallGroup.m_fWallLength

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