Mare_413
Mare_413

Reputation: 417

Is there something similar to the Update void in Unity?

i need to make a label change color and text according to a boolean, if the boolean is true, make label say sth and if false, say sth else. i know you can do this in Unity by the Update void, here's a 2 minute video explaining how it works https://youtu.be/ZukcUv3pyXQ how can i archive this result in visual studio?

Upvotes: 0

Views: 1230

Answers (1)

How about using a timer to achieve that behavior?

using System.Timers;

timer = new System.Timers.Timer();
timer.Interval = 100;//miliseconds
timer.Elapsed += Update;
timer.Start();     

private void Update(object sender, ElapsedEventArgs e) {

}

Upvotes: 1

Related Questions