如何跟踪用户是否已收集每日奖励?

时间:2019-11-16 16:24:31

标签: flutter dart

我正在尝试为用户创建每日奖励按钮,但是我不知道如何开始,

到目前为止,我还没有代码,但这是我编写代码的过程。

Use true_time plugin to get the current time
create a variable to indicate if the reward button has been collected (counter 1 and 0?)
when onPress: check if the counter is 1 or 0, if counter = 1 then prompt success msg else prompt error msg

即使我要手动设置计数器以指示用户是否已收集奖励,我如何保持对其他用户的持久性。还有另一种方法还是必须使用数据库?

谢谢,希望你们过得愉快:)

0 个答案:

没有答案