public void CheckGameStatus(ParticlesDataHandler particles)
 {
     if (gameStatus.GetStatus() == GameStatus.VICTORY)
     {
         particles.SetDataValue("burstVictory", true);
         particles.SetDataValue("victoryPinID", gameStatus.GetIntValue("lastVictoryPin"));
     }
 }
Exemplo n.º 2
0
        IEnumerator CheckVictoryCO()
        {
            while (true)
            {
                if (data.GetBoolValue("burstVictory"))
                {
                    if (data.GetIntValue("victoryPinID") != lastStarPos)
                    {
                        lastStarPos = data.GetIntValue("victoryPinID");
                        starParticles[data.GetIntValue("victoryPinID")].Play();
                    }


                    data.SetDataValue("burstVictory", false);
                }

                mediator.CheckGameStatus(data);
                yield return(new WaitForSeconds(0.1f));
            }
        }