InitializePlayer
How do I use Initialize Player
Below are practical examples compiled from projects for learning and reference purposes
Featured Snippets
Line | Code | Ex.. |
---|---|---|
46 | InitializePlayer (); | 1 |
115 | void InitializePlayer(){ | 2 |
16 | InitializePlayerVariables (); | 3 |
85 | void InitializePlayerVariables(){ | 4 |
File name: GameplayController.cs
Copy
40 void InitializeGameplayVariables(){
41 if(GameController.instance != null){
42 InitializeCoins ();
43 InitializeWeaponLevel ();
44 InitializeUpgradePrice ();
45 }
46 InitializePlayer ();
47 statusTab.SetActive (true);
48 deployButton.SetActive (true);
49 upgradeButton.SetActive (true);
50 coinTab.SetActive (false);
51 gameoverPanel.SetActive (false);
52 startMoving = false;
53 }
File name: GameplayController.cs
Copy
115 void InitializePlayer(){
116 Instantiate (player, new Vector3 (0, -3.5f, 0), Quaternion.identity);
117 }
File name: PlayerController.cs
Copy
85 void InitializePlayerVariables(){
86 position = transform.position;
87 audioSource = GetComponent
88 }
InitializePlayer 169 lượt xem
Gõ tìm kiếm nhanh...