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

Preview entity created from entity prefab. More...

Inheritance diagram for SCR_PrefabPreviewEntity:
[legend]

Public Member Functions

void CreatePrefabFromSource (WorldEditorAPI api, ResourceName basePrefab)
 
override void _WB_OnContextMenu (int id)
 
override array< ref WB_UIMenuItem > _WB_GetContextMenuItems ()
 
- Public Member Functions inherited from SCR_BasePreviewEntity
void SetPreviewTransform (vector worldTransform[4], EEditorTransformVertical verticalMode, float heightTerrain=0, bool isUnderwater=false, TraceParam trace=null)
 Set transformation of the preview.
 
array< SCR_BasePreviewEntityGetPreviewChildren ()
 Get all direct preview entity children.
 
IEntity GetSourceEntity ()
 Get entity from which the preview was copied from.
 
void GetPreviewBounds (out vector outBoundMin, out vector outBoundMax)
 Get local bounding box of the preview entity (including all children)
 
bool HasMultipleEditableEntities ()
 
void SCR_BasePreviewEntity (IEntitySource src, IEntity parent)
 
void ~SCR_BasePreviewEntity ()
 
override void _WB_GetBoundBox (inout vector min, inout vector max, IEntitySource src)
 
override void _WB_AfterWorldUpdate (float timeSlice)
 

Static Public Member Functions

static SCR_BasePreviewEntity SpawnPreviewFromPrefab (Resource prefabResource, ResourceName previewPrefab, BaseWorld world=null, EntitySpawnParams spawnParams=null, ResourceName material=ResourceName.Empty, EPreviewEntityFlag flags=0)
 Spawn preview entity from prefab resource.
 
static array< ref SCR_BasePreviewEntryGetPreviewEntriesFromPrefab (Resource prefabResource)
 Get unifiedpreview configuration from prefab resource.
 
static void GetPreviewEntries (IEntitySource entitySource, out notnull array< ref SCR_BasePreviewEntry > outEntries, int parentID=-1, SCR_BasePreviewEntry entry=null, EPreviewEntityFlag flags=0)
 Get preview entries from entity source.
 
- Static Public Member Functions inherited from SCR_BasePreviewEntity
static SCR_BasePreviewEntity SpawnPreview (notnull array< ref SCR_BasePreviewEntry > entries, ResourceName previewPrefab, BaseWorld world=null, EntitySpawnParams spawnParams=null, ResourceName material=ResourceName.Empty, EPreviewEntityFlag flags=0)
 Spawn preview entity from entries.
 

Static Protected Member Functions

static void GetPreviewEntriesFromSlot (BaseContainer slotSource, out notnull array< ref SCR_BasePreviewEntry > outEntries, int parentID=-1, ResourceName slotPrefab=ResourceName.Empty)
 
static void GetPreviewEntriesFromLink (SCR_EditorLinkEntry link, out notnull array< ref SCR_BasePreviewEntry > outEntries, int parentID=-1, float parentScale=1)
 

Protected Attributes

ResourceName m_SourcePrefab
 
- Protected Attributes inherited from SCR_BasePreviewEntity
EPreviewEntityFlag m_Flags
 
IEntity m_Entity
 
IEntitySource m_EntitySource
 
float m_fHeightTerrain = -1
 
bool m_bIsOnOrigTransform = true
 
vector m_vLocalTransform [4]
 
vector m_vTerrainTransform [4]
 
ref array< SCR_BasePreviewEntitym_aChildren
 
vector m_vBounds [2]
 
bool m_bHasMultipleEditableEntities
 

Additional Inherited Members

- Protected Member Functions inherited from SCR_BasePreviewEntity
void SetChildTransform (EEditorTransformVertical verticalMode, float heightTerrain, bool isUnderwater=false, TraceParam trace=null)
 
void SetPreviewObject (VObject mesh, ResourceName material)
 
void EOnPreviewInit (SCR_BasePreviewEntry entry, SCR_BasePreviewEntity root)
 Init event called when the preview is created.
 
void EOnRootPreviewInit (array< ref SCR_BasePreviewEntry > entries)
 Init event called on preview root entity.
 

Detailed Description

Preview entity created from entity prefab.

Member Function Documentation

◆ _WB_GetContextMenuItems()

override array< ref WB_UIMenuItem > SCR_PrefabPreviewEntity._WB_GetContextMenuItems ( )

◆ _WB_OnContextMenu()

override void SCR_PrefabPreviewEntity._WB_OnContextMenu ( int  id)

◆ CreatePrefabFromSource()

void SCR_PrefabPreviewEntity.CreatePrefabFromSource ( WorldEditorAPI  api,
ResourceName  basePrefab 
)

◆ GetPreviewEntries()

static void SCR_PrefabPreviewEntity.GetPreviewEntries ( IEntitySource  entitySource,
out notnull array< ref SCR_BasePreviewEntry outEntries,
int  parentID = -1,
SCR_BasePreviewEntry  entry = null,
EPreviewEntityFlag  flags = 0 
)
static

Get preview entries from entity source.

Parameters
entitySourceEntity source
[out]outEntriesArray filled with preview entries

◆ GetPreviewEntriesFromLink()

static void SCR_PrefabPreviewEntity.GetPreviewEntriesFromLink ( SCR_EditorLinkEntry  link,
out notnull array< ref SCR_BasePreviewEntry outEntries,
int  parentID = -1,
float  parentScale = 1 
)
staticprotected

◆ GetPreviewEntriesFromPrefab()

static array< ref SCR_BasePreviewEntry > SCR_PrefabPreviewEntity.GetPreviewEntriesFromPrefab ( Resource  prefabResource)
static

Get unifiedpreview configuration from prefab resource.

Parameters
prefabResourcePrefab resource
Returns
Array of configuration entries.

◆ GetPreviewEntriesFromSlot()

static void SCR_PrefabPreviewEntity.GetPreviewEntriesFromSlot ( BaseContainer  slotSource,
out notnull array< ref SCR_BasePreviewEntry outEntries,
int  parentID = -1,
ResourceName  slotPrefab = ResourceName::Empty 
)
staticprotected

◆ SpawnPreviewFromPrefab()

static SCR_BasePreviewEntity SCR_PrefabPreviewEntity.SpawnPreviewFromPrefab ( Resource  prefabResource,
ResourceName  previewPrefab,
BaseWorld  world = null,
EntitySpawnParams  spawnParams = null,
ResourceName  material = ResourceName::Empty,
EPreviewEntityFlag  flags = 0 
)
static

Spawn preview entity from prefab resource.

Parameters
prefabResourceEntity prefab resource
previewPrefabPrefab from which the preview entity will be spawned from. Apart from file path, it can be also class name
worldWorld in which the preview will be spawned
spawnParamsSpawn params of the preview
materialMaterial of the preview
Returns
Entity preview

Member Data Documentation

◆ m_SourcePrefab

ResourceName SCR_PrefabPreviewEntity.m_SourcePrefab
protected

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