Question by
importguru88 · Jun 16, 2016 at 05:43 AM ·
c#operator
How do I my operators properly in Unity in c#
My operators on my script are in correct . I need the operators to be set so numbers is below number I set for the scene change and I need the operator set to when the countdown timer reaches zero . So here is my script :
using UnityEngine; using System.Collections; using UnityEngine.UI; using UnityEngine.SceneManagement; public class Game : MonoBehaviour {
private MyClockScript myClock; void Start () { myClock = GetComponent(); }
// Update is called once per frame
void Update () {
if (myClock.m_leftTime < 0 || GameManagerSingleton.score > 0)
{
SceneManager.LoadScene("ui");
}
}
}
Comment