mirror of
https://github.com/zhenxun-org/zhenxun_bot.git
synced 2025-12-15 14:22:55 +08:00
修复一点逻辑小问题
This commit is contained in:
parent
a84cab7afd
commit
9db69fa05b
@ -149,12 +149,12 @@ async def _remind(user_id: int, uid: str):
|
||||
if current_resin < max_resin:
|
||||
user_manager.remove(uid)
|
||||
user_manager.remove_overflow(uid)
|
||||
if current_resin <= max_resin - 40:
|
||||
next_time = now + timedelta(minutes=(max_resin - 40 - current_resin + 1) * 8, seconds=10)
|
||||
elif max_resin - 40 < current_resin <= max_resin - 20:
|
||||
next_time = now + timedelta(minutes=(max_resin - 20 - current_resin + 1) * 8, seconds=10)
|
||||
elif max_resin - 20 < current_resin < max_resin:
|
||||
next_time = now + timedelta(minutes=(max_resin - current_resin) * 8, seconds=10)
|
||||
if current_resin < max_resin - 40:
|
||||
next_time = now + timedelta(minutes=(max_resin - 40 - current_resin) * 8)
|
||||
elif max_resin - 40 <= current_resin < max_resin - 20:
|
||||
next_time = now + timedelta(minutes=(max_resin - 20 - current_resin) * 8)
|
||||
elif max_resin - 20 <= current_resin < max_resin:
|
||||
next_time = now + timedelta(minutes=(max_resin - current_resin) * 8)
|
||||
elif current_resin == max_resin:
|
||||
custom_overflow_resin = Config.get_config("resin_remind", "CUSTOM_RESIN_OVERFLOW_REMIND")
|
||||
if user_manager.is_overflow(uid) and custom_overflow_resin:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user