private void Start() { playerMotor = GameManager.Instance.PlayerMotor; controller = GetComponent <CharacterController>(); }
void Start() { playerMotor = GetComponent <PlayerMotor>(); levitateMotor = GetComponent <LevitateMotor>(); controller = GetComponent <CharacterController>(); }
void Start() { // Store references dfUnity = DaggerfallUnity.Instance; dfAudioSource = GetComponent<DaggerfallAudioSource>(); playerMotor = GetComponent<PlayerMotor>(); playerEnterExit = GetComponent<PlayerEnterExit>(); // Add our own custom audio source at runtime as we need to change the pitch of footsteps. // We don't want that affecting to other sounds on this game object. customAudioSource = gameObject.AddComponent<AudioSource>(); customAudioSource.hideFlags = HideFlags.HideInInspector; customAudioSource.playOnAwake = false; customAudioSource.loop = false; customAudioSource.dopplerLevel = 0f; customAudioSource.spatialBlend = 0f; // Set start position lastPosition = GetHorizontalPosition(); // Set starting footsteps currentFootstepSound = FootstepSoundNormal; }
void Awake() { playerController = GetComponent<CharacterController>(); playerMotor = GetComponent<PlayerMotor>(); entityBehaviour = GetComponent<DaggerfallEntityBehaviour>(); entityBehaviour.OnSetEntity += EntityBehaviour_OnSetEntity; mainCamera = GameManager.Instance.MainCamera; startCameraHeight = mainCamera.transform.localPosition.y; }
private void Start() { playerMotor = GameManager.Instance.PlayerMotor; levitateMotor = GetComponent <LevitateMotor>(); }
private void Start() { playerMotor = GameManager.Instance.PlayerMotor; levitateMotor = GetComponent <LevitateMotor>(); CanRun = CanRunUnlessRiding; }
void Awake() { instance = this; Player = GameObject.FindGameObjectWithTag("Player"); if (!Player) throw new Exception("Player object not set in FloatingOrigin script."); if (!StreamingWorld) throw new Exception("StreamingWorld not set in FloatingOrigin script."); playerMotor = Player.GetComponent<PlayerMotor>(); if (!playerMotor) throw new Exception("Player object does not have a PlayerMotor."); }
private void Start() { playerMotor = GetComponent <PlayerMotor>(); speedChanger = GetComponent <PlayerSpeedChanger>(); playerCamera = GameManager.Instance.MainCamera; }
void Start() { playerMotor = GetComponent<PlayerMotor>(); frictionMotor = GetComponent<FrictionMotor>(); myTransform = playerMotor.transform; }
private void Start() { playerMotor = GameManager.Instance.PlayerMotor; }