Set unique user properly.

This commit is contained in:
dngfx 2018-09-08 11:54:06 +01:00 committed by dongfix
parent 95712e5520
commit 82a20a209a

View file

@ -96,11 +96,10 @@ class Module(object):
return return
user = event["user"] user = event["user"]
hostname = user.hostname
game = channel.games["ducks"] game = channel.games["ducks"]
if hostname not in game["unique_nicks"]: if user not in game["unique_nicks"]:
game["unique_nicks"].append(hostname) game["unique_nicks"].append(user)
if game["current_unique_nicks"] > 0: if game["current_unique_nicks"] > 0:
game["current_unique_nicks"] = game["current_unique_nicks"] - 1 game["current_unique_nicks"] = game["current_unique_nicks"] - 1
@ -112,3 +111,5 @@ class Module(object):
if game["current_active_delay"] > 0: if game["current_active_delay"] > 0:
game["current_active_delay"] = game["current_active_delay"] \ game["current_active_delay"] = game["current_active_delay"] \
- DELAY_REDUCE - DELAY_REDUCE
print(game)