/// <summary>
        /// Register transform with the manager and get list if attached colliders
        /// </summary>
        public void Start()
        {
            WorldPosition center = FloatingOrigin.Make().sceneCenter; //Ensure existance of floating origin manager

            FloatingOrigin.Add(this);
            this.worldPosition = new WorldPosition(this.unityPosition);
            UpdateColliderList();

            if (worldPosition.SameSector(center))
            {
                this.OnOriginEnter(center);
            }
            else
            {
                this.OnOriginExit(center);
            }
        }
예제 #2
0
 public void Start()
 {
     FloatingOrigin.Add(this);
     this.worldPosition = new WorldPosition(this.unityPosition);
     UpdateColliderList();
 }