Postby Hoeloe » Tue Oct 08, 2019 12:13 pm
What is data here? You never define that, so you'll probably get an error saying you were "attempting to index a nil value" - that is, you tried to do:
data.timer
when data doesn't exist. That doesn't make sense, since it can't look for the timer field inside something non-existent, so it'll just error.
Speaking of which, you don't actually need to use a timer at all here. You can just check lunatime.tick(), which will give you the current game tick.