platformer
Public Member Functions | Public Attributes | List of all members
UnityPlatformer.InstancePrefab Class Reference

Instance a prefab on start More...

Inheritance diagram for UnityPlatformer.InstancePrefab:
UnityPlatformer.PlayerStart

Public Member Functions

void Awake ()
 NOTE no virtual on purpose. override OnAwake More...
 
virtual void RenameInstance (string rootName, int index)
 Rename logic: append counter to the name More...
 
virtual void OnAwake (bool notify=true)
 Instance the prefab, rename and attach it More...
 

Public Attributes

Sprite placeholder
 Placeholder sprite for editor, to see something More...
 
GameObject prefab
 Prefab to instance More...
 
bool attachToRoot = true
 Attach the prefab as a child or at root node. More...
 
GameObject instance = null
 reference to instanced prefab More...
 

Detailed Description

Instance a prefab on start

Member Function Documentation

◆ Awake()

void UnityPlatformer.InstancePrefab.Awake ( )
inline

NOTE no virtual on purpose. override OnAwake

◆ OnAwake()

virtual void UnityPlatformer.InstancePrefab.OnAwake ( bool  notify = true)
inlinevirtual

Instance the prefab, rename and attach it

Parameters
notifytrue -> SendMessage: OnInstancePrefab

Reimplemented in UnityPlatformer.PlayerStart.

◆ RenameInstance()

virtual void UnityPlatformer.InstancePrefab.RenameInstance ( string  rootName,
int  index 
)
inlinevirtual

Rename logic: append counter to the name

Member Data Documentation

◆ attachToRoot

bool UnityPlatformer.InstancePrefab.attachToRoot = true

Attach the prefab as a child or at root node.

◆ instance

GameObject UnityPlatformer.InstancePrefab.instance = null

reference to instanced prefab

◆ placeholder

Sprite UnityPlatformer.InstancePrefab.placeholder

Placeholder sprite for editor, to see something

◆ prefab

GameObject UnityPlatformer.InstancePrefab.prefab

Prefab to instance


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