예제 #1
0
    // Note: If gameObject is not found at first call (in case scene is not fully loaded), this function is called multiple times
    public override void Init()
    {
        this.currentTurn = 1;

        spawners = GameObject.FindGameObjectsWithTag("Spawner");
        if (spawners == null)
        {
            return;
        }
        if (spawners.Length == 0)
        {
            return;
        }

        // Instantiate initial pieces
        foreach (GameObject spawner in spawners)
        {
            string pieceName = Pieces.LotPieceName();
            spawner.GetComponent <PieceSpawner>().Spawn(pieceName);
        }

        // prepare unityads
        UnityAdsManager.GetInstance();

        // unlock pieces
        Pieces.Instance.UnLock();

        // initialize flg
        this.isInitialized = true;

        SocialPlatformsManager.Instance.Init();
    }
예제 #2
0
 void Start()
 {
     // GetInstance for initialization
     UnityAdsManager.GetInstance();
 }
예제 #3
0
    public void ShowAds()
    {
        UnityAdsManager unityAdsManager = UnityAdsManager.GetInstance();

        unityAdsManager.ShowAds(null, RecoverPassCount);
    }