How can I make a daily rewards system ?, please help

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By RubRub

I need to make a daily rewards system for my game since I want to give you 100 coins every day

:bust_in_silhouette: Reply From: Martik

There is a method you can get your current date through OS.

var login_date = OS.get_date()
if login_date.day > latest_reward.day:
	login_date = latest_reward

Then gift the user 100 coins.

Thank you very much I will try to support myself with the code

RubRub | 2021-10-25 00:14

but can you explain me somehow since this variable storage is new to me?

RubRub | 2021-10-25 00:32