Remove the roles_check event
This commit is contained in:
parent
d8161271c7
commit
7f875d3b33
@ -5957,8 +5957,6 @@ def start(cli, nick, chan, forced = False, restart = ""):
|
|||||||
return
|
return
|
||||||
|
|
||||||
if var.ORIGINAL_SETTINGS and not restart: # Custom settings
|
if var.ORIGINAL_SETTINGS and not restart: # Custom settings
|
||||||
event = Event("roles_check", {"addroles": addroles})
|
|
||||||
if event.dispatch(var):
|
|
||||||
need_reset = True
|
need_reset = True
|
||||||
wvs = sum(addroles[r] for r in var.WOLFCHAT_ROLES)
|
wvs = sum(addroles[r] for r in var.WOLFCHAT_ROLES)
|
||||||
if len(villagers) < (sum(addroles.values()) - sum(addroles[r] for r in var.TEMPLATE_RESTRICTIONS.keys())):
|
if len(villagers) < (sum(addroles.values()) - sum(addroles[r] for r in var.TEMPLATE_RESTRICTIONS.keys())):
|
||||||
@ -5968,6 +5966,8 @@ def start(cli, nick, chan, forced = False, restart = ""):
|
|||||||
cli.msg(chan, "There has to be at least one wolf!")
|
cli.msg(chan, "There has to be at least one wolf!")
|
||||||
elif wvs > (len(villagers) / 2):
|
elif wvs > (len(villagers) / 2):
|
||||||
cli.msg(chan, "Too many wolves.")
|
cli.msg(chan, "Too many wolves.")
|
||||||
|
elif set(addroles) != set(var.ROLE_GUIDE):
|
||||||
|
cli.msg(chan, "Error: Not all roles have defined player counts.")
|
||||||
else:
|
else:
|
||||||
need_reset = False
|
need_reset = False
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user