public override void PreStartClient() { audioSource = GetComponent <AudioSource>(); audioSync = GetComponent <AudioSync>(); firstPersonController = GetComponent <FirstPersonController>(); firstPersonCamera = cameraTransform.GetComponent <Camera>(); scoreScript = GetComponent <Player_Score>(); }
// Start is called before the first frame update void Start() { _money = PlayerPrefs.GetInt("Money"); DamagePercent = 0; _gameManager = GameObject.Find("GameManager").GetComponent <GameManager>(); _vThirdPersonController = this.gameObject.GetComponent <vThirdPersonController>(); _audioSync = this.gameObject.GetComponent <AudioSync>(); _playerName = this.gameObject.GetComponent <PlayerName>(); }
//Initialize on start void Start() { navmeshAgent = GetComponent <UnityEngine.AI.NavMeshAgent>(); animator = GetComponentInChildren <Animator> (); audioSync = GetComponent <AudioSync> (); GameObject.FindGameObjectWithTag("Greet").GetComponentInChildren <Text> ().text = "ASK"; GameObject.FindGameObjectWithTag("ThankButton").GetComponentInChildren <Text>().text = "THANK"; }
private void Start() { if (cam == null) { Debug.LogError("PlayerShoot: No camera referenced!"); this.enabled = false; } audioSync = gameObject.GetComponent <AudioSync>(); playerMotor = gameObject.GetComponent <PlayerMotor>(); playerUIInstance = gameObject.GetComponent <PlayerSetup>().playerUIInstance; }
void Start() { myTransform = transform; targetScript = GetComponent <Zombie_Target>(); audioSync = GetComponent <AudioSync>(); if (isServer) { StartCoroutine(Attack()); StartCoroutine(Bellow()); } }
protected virtual void Start() { _animator = GetComponent <Animator>(); _audioSync = GetComponent <AudioSync>(); _particleSync = GetComponent <ParticleSync>(); _forceSync = GetComponent <ForceSync>(); _playerGameRules = GetComponent <PlayerGameRules>(); _playerName = GetComponent <PlayerName>(); _gameManager = GameObject.Find("GameManager").GetComponent <GameManager>(); _UI = GameObject.Find("UI"); // Instead of syncing the name upon connecting, just do this InvokeRepeating("SyncName", 1f, 5f); #if !UNITY_EDITOR Cursor.visible = false; #endif }
// Start is called before the first frame update void Start() { _textDisplays = GameObject.FindGameObjectsWithTag("Elevator text"); if (isServer) { this.GameManager = GameObject.Find("GameManager").GetComponent <GameManager>(); _arenaDoor = GameObject.FindGameObjectWithTag("Elevator arena door"); _entranceDoor = GameObject.FindGameObjectWithTag("Elevator back door"); _bottomPlatform = GameObject.Find("Elevator floor"); _audioSync = this.gameObject.GetComponent <AudioSync>(); _rigidBody = this.gameObject.GetComponent <Rigidbody>(); _state = ElevatorState.WaitingForPlayers; _startPos = this.gameObject.transform.position; _endPos = this.gameObject.transform.position + new Vector3(0, 0, -20); } }
// Use this for initialization void Start() { audioSync = GetComponent <AudioSync>(); }
//Used to initialize values void Start() { animator = GetComponentInChildren <Animator> (); audioSync = GetComponent <AudioSync> (); }
private void Start() { _audioSync = GetComponent <AudioSync>(); _gameState = GameState.Waiting; _random = new System.Random(); }
private Animator animator; //Reference to animator //Used to initialize values void Start() { animator = GetComponentInChildren <Animator> (); audioSync = GetComponent <AudioSync> (); GameObject.FindGameObjectWithTag("Kick").GetComponentInChildren <Text> ().text = "KICK"; }
// Use this for initialization void Start() { audioSync = GameObject.Find("Audio Manager").GetComponent <AudioSync>(); }
void Start() { audioSync = GameObject.FindGameObjectWithTag("AudioController").GetComponent <AudioSync>(); controller = GetComponent <StateController>(); }
//Initialiize variables void Start() { audioSync = GetComponent <AudioSync> (); agentSpeed = GetComponent <UnityEngine.AI.NavMeshAgent>().speed; Invoke("SetInitializeTrigger", 3f); }