VR Development Framework
v 1.0.0
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events Pages
static Transform AVR.Core.Utils.Misc.CreateEmptyGameObject ( string  name,
Transform  parent,
Vector3  worldPos,
Quaternion  worldRot 
)
inlinestatic

Creates an empty gameobject with specifed position and rotation. Returns its transform component.

Parameters
nameName of the gameobject
parentParent of the gameobject (null for no parent)
worldPosWorld-space position to instantiate the object at
worldRotWorld-space rotation of the gameobject

Definition at line 239 of file AVR_Utils.cs.

239  {
240  GameObject o = new GameObject(name);
241  o.transform.SetParent(parent);
242  o.transform.SetPositionAndRotation(worldPos, worldRot);
243  return o.transform;
244  }