diff --git a/modules/coins.py b/modules/coins.py index 765ebdc8..550b11e9 100644 --- a/modules/coins.py +++ b/modules/coins.py @@ -5,6 +5,8 @@ SIDES = {"heads": 0, "tails": 1} DEFAULT_REDEEM_DELAY = 600 # 600 seconds, 10 minutes DEFAULT_REDEEM_AMOUNT = 100 DEFAULT_INTEREST_RATE = 0.01 +INTEREST_INTERVAL = 60*60 # 1 hour + class Module(object): def __init__(self, bot): @@ -27,7 +29,7 @@ class Module(object): until_next_hour += ((60-(now.minute+1))*60) bot.events.on("timer").on("coin-interest").hook(self.interest) - bot.add_timer("coin-interest", 10, persist=False, + bot.add_timer("coin-interest", INTEREST_INTERVAL, persist=False, next_due=time.time()+until_next_hour) def coins(self, event):