Esempio n. 1
0
 void Awake()
 {
     if (instance == null)
     {
         instance = this;
         isMute   = (PlayerPrefs.GetInt("mute", 0) == 0) ? false : true;
         DoMute();
         DontDestroyOnLoad(this);
     }
     else if (this != instance)
     {
         Destroy(gameObject);
     }
 }
Esempio n. 2
0
    void Start()
    {
        Count_Timer = 0;                                                        ///	タイマー初期化
        isAction    = true;                                                     ///	メインの実態生成ON
        ///	ゲームメインをグローバルに登録する
        CommonUtility.GameMain = this;
        if (isFadeOneFlag)
        {
            Fade m_Fade = GetComponent <Fade>();
            m_Fade.FadeStart(2, Stage1_Fade_out);
        }
        m_enemy.Clear();

        BGMObj   = GameObject.Find("BGM_Control").GetComponent <BGMControll> ();
        SoundObj = GameObject.Find("SoundsControll").GetComponent <SoundControll> ();
    }
Esempio n. 3
0
 private void Awake()
 {
     instance = this;
 }
Esempio n. 4
0
 // Use this for initialization
 void Start()
 {
     SoundObj = GameObject.Find("SoundsControll").GetComponent <SoundControll> ();
 }