ScoreCount.cs
576 Bytes
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
using UnityEngine.EventSystems;
public class ScoreCount : MonoBehaviour
{
public static int currentScore = 0;
public static int startingScore = 0;
public static int fakeScore = 0;
[SerializeField] Text ScoreText;
public void addScore()
{
currentScore += 1;
fakeScore += 1;
}
void Start()
{
//currentScore = 0;
}
void Update()
{
ScoreText.text = "Score: " + fakeScore.ToString();
}
}