コード例 #1
0
ファイル: ArtifactsOptions.cs プロジェクト: kalzun/2DGame
 // Use this for initialization
 void Start()
 {
     gm = GameObject.FindGameObjectWithTag ("AsteroidGameManager").GetComponent<AsteroidGameManager> ();
     player = GameObject.FindGameObjectWithTag ("Player").GetComponent<AsteroidPlayerShip> ();
     asteroidScore = GameObject.FindGameObjectWithTag ("AsteroidScore").GetComponent<AsteroidScore> ();
     // stats = GameObject.FindGameObjectWithTag ("AsteroidGameManager").GetComponent<Stats> ();
 }
コード例 #2
0
 private void Awake()
 {
     if (_instance == null)
     {
         _instance = this;
     }
     score        = 0;
     playerHealth = 100;
     DontDestroyOnLoad(this);
 }
コード例 #3
0
ファイル: AsteroidPlayerShip.cs プロジェクト: kalzun/2DGame
 void Start()
 {
     mainCamera = GameObject.FindGameObjectWithTag ("MainCamera");
     asteroidGameManager = GameObject.FindGameObjectWithTag ("AsteroidGameManager").GetComponent<AsteroidGameManager> ();
 }
コード例 #4
0
ファイル: Stats.cs プロジェクト: kalzun/2DGame
 // Use this for initialization
 void Start()
 {
     gm = GameObject.FindGameObjectWithTag ("AsteroidGameManager").GetComponent<AsteroidGameManager> ();
     player = GameObject.FindGameObjectWithTag ("Player").GetComponent<AsteroidPlayerShip> ();
 }
コード例 #5
0
ファイル: AsteroidStone.cs プロジェクト: kalzun/2DGame
 // Use this for initialization
 void Start()
 {
     asteroidScore = GameObject.FindGameObjectWithTag ("AsteroidScore").GetComponent<AsteroidScore> ();
     gm = GameObject.FindGameObjectWithTag ("AsteroidGameManager").GetComponent<AsteroidGameManager> ();
 }