示例#1
0
 private void Start()
 {
     FillBoardWithGems();
     curTimer = levelDuration;
     if (lastGameWon)
     {
         curLevel++;
     }
     else
     {
         curLevel = 0;
     }
     curGoalScore = baseGoalScore + (curLevel * incGoalScore);
     ScorePanel.SetNewScore(curScore, false);
 }
示例#2
0
    private void AddMatchScore(List <List <Gem> > matchIslands)
    {
        int matchScore = comboBonusScore * comboCounter;

        foreach (List <Gem> island in matchIslands)
        {
            matchScore += baseMatchScore + bonusMatchScore * (island.Count - 3);
        }
        curScore += matchScore;
        ScorePanel.SetNewScore(curScore);
        if (curScore >= curGoalScore)
        {
            gameEnded   = true;
            lastGameWon = true;
            onWon.Invoke();
        }
    }