Example #1
0
 private void Awake()
 {
     Cursor.lockState = CursorLockMode.Locked;
     maxMouse         = mouseSensitivity;
     time             = GameObject.Find("Time").GetComponent <TimeProgression>();
     InvokeRepeating("SlowCam", 1f, 1f);
 }
 void Awake()
 {
     cam        = Camera.main;
     playerTool = GetComponentInChildren <PlayerTool>();
     anim       = GetComponent <Animator>();
     time       = GameObject.Find("Time").GetComponent <TimeProgression>();
     InvokeRepeating("SlowAnimator", 1f, 1f);
 }
Example #3
0
 Vector3 groundVelocity;//jump and fall velocity
 void Awake()
 {
     characterController = GetComponent <CharacterController>();
     groundCheck         = GameObject.Find("GroundCheck");
     maxSpeed            = speed;
     maxSprint           = sprintBoost;
     maxJump             = jumpHeight;
     time = GameObject.Find("Time").GetComponent <TimeProgression>();
     InvokeRepeating("SlowPlayer", 1f, 1f);
 }
Example #4
0
 private void Awake()
 {
     dayNight = GameObject.FindWithTag("Time").GetComponent <DayNight>();
     if (Instance == null)
     {
         Instance = this;
         DontDestroyOnLoad(gameObject);
     }
     else
     {
         Destroy(gameObject);
     }
 }
Example #5
0
 private void Awake()
 {
     dayNight = GameObject.FindWithTag("Time").GetComponent <DayNight>();
     if (Instance == null)
     {
         Instance = this;
         DontDestroyOnLoad(gameObject);
     }
     else
     {
         Destroy(gameObject);
     }
     //playerController = GameObject.Find("MovePoint");
     canvasGroup = GameObject.Find("BlackoutImage").GetComponent <CanvasGroup>();
     duskText    = GameObject.Find("DuskText").GetComponent <Text>();
     sleepText   = GameObject.Find("NightText").GetComponent <Text>();
     //InvokeRepeating("TrackTime", 1f, 1f);
     if (!charlotteInitialized)
     {
         charlotte = GameObject.Find("Charlotte");
         charlotte.SetActive(false);
         charlotteInitialized = true;
     }
 }
 void Awake()
 {
     time    = GameObject.Find("Time").GetComponent <TimeProgression>();
     trigger = this.GetComponent <Trigger>();
 }
 // Start is called before the first frame update
 void Awake()
 {
     Time = GameObject.Find("Time").GetComponent<TimeProgression>();
     time = Time.GetTime();
 }
 // Start is called before the first frame update
 void Awake()
 {
     Time = GameObject.FindWithTag("Time").GetComponent <TimeProgression>();
     time = Time.GetTime();
     will = ambientW + intrinsicW;
 }