// Use this for initialization void Start() { currentAni = GetComponent <Animation> (); CharacterControl = GetComponent <CharacterController> (); KnightContainer = GameObject.Find("KnightContainer"); knightControl = knight.GetComponent <KnightControl>(); //Player = GameObject.Find ("Player"); movingCube = GameObject.Find("MovingCube"); movingController = movingCube.GetComponent <MovingCubeController>(); audio = GetComponent <AudioSource> (); //knight = knightControl.gameObject; lookAtPos = movingController.transform; currentPos = transform.position; if (FirstPersonControl.VR) { Vector3 vec3 = knight.transform.localPosition; vec3.z = 0; knight.transform.localPosition = vec3; } }
// Start is called before the first frame update void Start() { ctr = GameObject.Find("knight").GetComponent <KnightControl>(); }