Beispiel #1
0
        void Awake()
        {
            _camera  = GetComponent <Camera>();
            uservars = new UserVarManager();
            history  = new Pose[maxHistoryPoses];

            if (startControllerAsset != null)
            {
                startControllerAsset.Load();
                start_controller          = startControllerAsset.controller;
                start_controller.executor = this;
            }

            if (updateControllerAsset != null)
            {
                updateControllerAsset.Load();
                update_controller          = updateControllerAsset.controller;
                update_controller.executor = this;
            }

            user_controllers = new Controller[userControllerAsset.Length];
            for (int i = 0; i < userControllerAsset.Length; ++i)
            {
                userControllerAsset[i].Load();
                user_controllers[i]          = userControllerAsset[i].controller;
                user_controllers[i].executor = this;
            }

            if (OnControllerCreate != null)
            {
                OnControllerCreate(this);
            }
        }
Beispiel #2
0
 public static Transform GetTransform(string name)
 {
     return(UserVarManager.GetTransform(name));
 }
Beispiel #3
0
 public static Var GetGlobalVar(string name)
 {
     return(UserVarManager.GetGlobalVar(name));
 }
Beispiel #4
0
 public static void SetGlobalVar(string name, Var value)
 {
     UserVarManager.SetGlobalVar(name, value);
 }
Beispiel #5
0
 public static void UnsetTransform(string name)
 {
     UserVarManager.UnsetTransform(name);
 }
Beispiel #6
0
 public static void SetTransform(string name, Transform t)
 {
     UserVarManager.SetTransform(name, t);
 }