Beispiel #1
0
 public void Awake()
 {
     if (adutil == null)
     {
         adutil = GameObject.Find("AdfurikunMovieRewardUtility").GetComponent <AdfurikunMovieRewardUtility>();
     }
 }
Beispiel #2
0
    void Update()
    {
        if (!initialized)
        {
            initialized = true;
            GameObject ob = GameObject.Find("AdfurikunMovieRewardUtility");
            AdfurikunMovieRewardUtility au = ob.GetComponent <AdfurikunMovieRewardUtility>();
            au.setMovieRewardSrcObject(this.gameObject);
            au.initializeMovieReward();
        }
        switch (this.sceneState)
        {
        case SCENE_STATE.MAIN:
            break;

        case SCENE_STATE.QUIT_WAIT:
            this.sceneState = SCENE_STATE.QUIT;
            break;

        case SCENE_STATE.QUIT:
            this.sceneState = SCENE_STATE.END;
            break;

        case SCENE_STATE.END:
            break;
        }
    }
Beispiel #3
0
 public void Awake()
 {
     if (mInstance == null)
     {
         mInstance = this;
         DontDestroyOnLoad(gameObject);
     }
     else
     {
         Destroy(gameObject);
     }
 }
Beispiel #4
0
        override protected void Awake()
        {
            // 子クラスでAwakeを使う場合は
            // 必ず親クラスのAwakeをCallして
            // 複数のGameObjectにアタッチされないようにします.
            base.Awake();

            if (adutil == null)
            {
                adutil = GameObject.Find("AdfurikunMovieRewardUtility").GetComponent <AdfurikunMovieRewardUtility>();
            }
        }
Beispiel #5
0
    // 準備ができたら広告を再生する
    IEnumerator PlayAdsense()
    {
        GameObject ob = GameObject.Find("AdfurikunMovieRewardUtility");
        AdfurikunMovieRewardUtility au = ob.GetComponent <AdfurikunMovieRewardUtility>();


        while (!au.isPreparedMovieReward())
        {
            yield return(null);
        }
        au.playMovieReward();
    }