Example #1
0
 private void Awake() {
     pInst = playerInstantiater.GetComponent<PlayerInstantiater>();
     eInst = enemyInstantiater.GetComponent<EnemyInstantiater>();
     pUIMana = playerStatusUI.GetComponent<PlayerStatusUIManager>();
     dCount = dayCounter.GetComponent<DayCounter>();
     
     //camera取得
     cameraObj = Camera.main.gameObject;
     cameraController = cameraObj.GetComponent<CameraController>();
 }
 private void Awake()
 {
     if (Instance == null)
     {
         HPBar    = PlayerStatus.GetComponentInChildren <Slider>();
         Instance = this;
     }
     else
     {
         if (Instance != this)
         {
             Destroy(gameObject);
         }
     }
 }