public void UndoScore() { int score; if (undoScoreDict.TryGetValue(DictPosition - 1, out score)) { scoreScript.DecreaseScore(score); } }