Hi!
I need to keep track of the in-game date and time.
While setting up the project, I made a timer that takes a speed (so I can change game speed easily) and fires an ActionList that updates several global variable integers. I have a script that takes those and returns a DateTime object for where that is more useful.
Is this an efficient way to do in-game time management? In terms of memory usage etc.? Or would I be better off writing a custom script that handles it in something like the Update function?
It looks like you're new here. If you want to get involved, click one of these buttons!
Comments
AC Timers are updated as part of the StateHandler's Update loop, so their performance isn't anything to worry about. I don't know exactly what Actions you're running, or how often, though.
Of course, a custom, dedicated, script that can cache variables, avoid overhead, etc is always going to be more performant - but from what you've described I'd say the difference wouldn't be noticeable either way.
Unity's Profiler is always the first port-of-call if performance is a convern, however.