ensure player is added to var.PLAYERS upon midgame join in maelstrom

fixes wolfchat / !simple / maybe other stuff
This commit is contained in:
jacob1 2016-04-06 22:52:45 -04:00
parent 1aa18af5cb
commit 4d480e32c6
2 changed files with 3 additions and 1 deletions

View File

@ -1190,6 +1190,8 @@ class MaelstromMode(GameMode):
var.ORIGINAL_ROLES[role].add(nick) var.ORIGINAL_ROLES[role].add(nick)
var.FINAL_ROLES[nick] = role var.FINAL_ROLES[nick] = role
var.LAST_SAID_TIME[nick] = datetime.now() var.LAST_SAID_TIME[nick] = datetime.now()
if nick in var.USERS:
var.PLAYERS[nick] = var.USERS[nick]
if role == "doctor": if role == "doctor":
lpl = len(var.list_players()) lpl = len(var.list_players())

View File

@ -6569,7 +6569,7 @@ def relay(cli, nick, chan, rest):
reply = "\u0001VERSION lykos, Python {0} -- https://github.com/lykoss/lykos\u0001".format(platform.python_version()) reply = "\u0001VERSION lykos, Python {0} -- https://github.com/lykoss/lykos\u0001".format(platform.python_version())
cli.notice(nick, reply) cli.notice(nick, reply)
return return
if var.PHASE not in ("night", "day"): if var.PHASE not in var.GAME_PHASES:
return return
pl = var.list_players() pl = var.list_players()