!votes from non-players are now allowed, !rehash added (but it's not very useful)
This commit is contained in:
parent
2ca393da83
commit
210472dc80
14
wolfgame.py
14
wolfgame.py
@ -21,6 +21,7 @@ import re
|
|||||||
import logging
|
import logging
|
||||||
import sys
|
import sys
|
||||||
import os
|
import os
|
||||||
|
import imp
|
||||||
|
|
||||||
COMMANDS = {}
|
COMMANDS = {}
|
||||||
PM_COMMANDS = {}
|
PM_COMMANDS = {}
|
||||||
@ -208,6 +209,16 @@ def restart_program(cli, nick, chan, rest):
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@cmd("rehash", admin_only=True)
|
||||||
|
def rehash(cli, nick, chan, rest):
|
||||||
|
reset(cli)
|
||||||
|
imp.reload(var)
|
||||||
|
imp.reload(botconfig)
|
||||||
|
cli.msg(chan, "Configuration reloaded")
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@cmd("op", admin_only=True)
|
@cmd("op", admin_only=True)
|
||||||
def give_op(cli, nick, chan, rest):
|
def give_op(cli, nick, chan, rest):
|
||||||
"""OP [(person)] Makes someone or yourself a channel operator"""
|
"""OP [(person)] Makes someone or yourself a channel operator"""
|
||||||
@ -535,9 +546,6 @@ def show_votes(cli, nick, chan, rest):
|
|||||||
if var.PHASE in ("none", "join"):
|
if var.PHASE in ("none", "join"):
|
||||||
cli.notice(nick, "No game is currently running.")
|
cli.notice(nick, "No game is currently running.")
|
||||||
return
|
return
|
||||||
elif nick not in var.list_players():
|
|
||||||
cli.notice(nick, "You're not currently playing.")
|
|
||||||
return
|
|
||||||
if var.PHASE != "day":
|
if var.PHASE != "day":
|
||||||
cli.notice(nick, "Voting is only during the day.")
|
cli.notice(nick, "Voting is only during the day.")
|
||||||
return
|
return
|
||||||
|
Loading…
x
Reference in New Issue
Block a user