Commit Graph

1406 Commits

Author SHA1 Message Date
Vgr E.Barry
8b1315eef6 Fix error on exchange totem if harlot who visits oneself is targetted 2015-06-04 12:45:09 -04:00
skizzerz
581cda4ac3 Fix revealroles/myrole bitten messages 2015-06-03 12:12:38 -05:00
skizzerz
dadff67f74 Guardian modifications
Modify game over messages to read better
Modify win conds to remove unneeded ones and to also add in some "nobody
wins" conds that happen due to MAD or stalemates.
2015-06-03 10:56:29 -05:00
jacob1
d8bc216df4 fix !frestart not actually restarting the bot 2015-06-03 01:31:46 -04:00
skizzerz
040be2ff31 Piper/charming fixes
- Piper can now only win during daytime (this includes transition_day as
  well as chk_decision)
- There is now at most 1 piper in charming regardless of player count,
  more than 1 is simply overpowered and impossible to balance
2015-06-02 23:57:36 -05:00
Janik Kleinhoff
3f0bce320e Fix typo, blame Vgr 2015-06-03 03:28:19 +00:00
Vgr E.Barry
416ded936d Fix another faulty len() call 2015-06-01 14:39:48 -04:00
Vgr E.Barry
f75592d571 Fix error in !stats if alpha wolf is in play 2015-06-01 14:36:13 -04:00
nyuszika7h
1ac59cea78 fpull: Support git versions older than 1.9
Those versions don't support the --rebase=preserve option of git pull.
2015-06-01 20:39:06 +02:00
Emanuel Barry
24851f3c56 Fix wrong pingif tables 2015-06-01 14:25:50 -04:00
nyuszika7h
ce880950cd frestart: Look for ERROR instead of QUIT
The IRCd sends ERROR when we get disconnected, so this is more reliable.
2015-05-31 18:32:38 +02:00
Vgr E.Barry
6278f3fe29 src/wolfgame.py: Consistency fixes
- Replaced all \XX, \XXX and \xXX syntax by \uXXXX syntax
- Replaced all single-quotes messages by double-quotes ones where it
makes sense
- Replace all {} in string literals by {0} syntax (explicit over
implicit)
- Use x.startswith(("a", "e", "i", "o", "u")) instead of x[0] in ("a",
"e", "i", "o", "u")
- Remove list comprehensions where a simple generator would work
(reduces memory consumption where we can)
2015-05-30 10:29:13 -04:00
Vgr E.Barry
ced87d21ea Remove backslash in line 2015-05-30 09:28:14 -04:00
Vgr E.Barry
06a5764a42 Fix bot crashing in !frestart
This fixes the bug where bot would crash on endgame through faftergame
without sending all messages, but introduces a new bug where someone can
quit between endgame and the bot's own quit, crashing it. This is an
extremely tight race condition, and shouldn't matter most of the time.
Further explanation in the big wall of text.
2015-05-30 00:11:23 -04:00
jacob1
10a3b5b01b new game mode: charming
has piper, werekitten at 10p, and warlock at 12p
2015-05-29 21:10:41 -04:00
jacob1
403dbb2fd5 use botconfig.CMD_CHAR in !ping removal notice 2015-05-29 19:05:41 -04:00
jacob1
da63bf21f7 !wiki: give link to main page if no arguments are provided, catch timeout errors 2015-05-29 19:03:32 -04:00
jacob1
c62ab1795c remove piper simple_message, fix player list grammar with the longer one 2015-05-29 18:03:10 -04:00
nyuszika7h
e66c69cb29 Use re.search() and raw strings for all regexes
re.fullmatch() would be the best, but it's only available since Python
3.4, and re.match(r"...$") looks weird.
2015-05-29 14:27:15 +02:00
jacob1
80a366e6b9 fix is_fake_nick returning True on UIDs
there is nothing else of interest in this commit
2015-05-28 23:29:35 -04:00
jacob1
29429cad66 fix bug where people who did /nick to a bad nickname couldn't ever rejoin
probably only happened with ACCOUNTS_ONLY enabled
2015-05-28 23:07:42 -04:00
jacob1
21391f9261 don't ping alt connections of players who have joined, set() changes 2015-05-28 22:31:19 -04:00
jacob1
338f24aa66 fix bug where players in var.DISCONNECTED couldn't use any commands (like !stats) 2015-05-28 21:01:34 -04:00
Vgr E.Barry
d15fd90b1e Fix win checking to account for piper win 2015-05-28 16:09:54 -04:00
Vgr E.Barry
7d652b457d Use defaultdict in transition_day and stats 2015-05-28 15:42:57 -04:00
jacob1
590406d00a use only a single table for pingif preferences 2015-05-28 15:21:59 -04:00
jacob1
379737d4fc Log piperwins in stats
commands to convert old tables: http://pastebin.com/jheALFsE
2015-05-28 10:49:56 -04:00
Vgr E.Barry
aab1f0aaf5 Prevent pipers from winning if someone is wounded 2015-05-27 20:45:52 -04:00
nyuszika7h
00b28eba2c Properly initialize var.CHARMED 2015-05-27 21:50:23 +02:00
nyuszika7h
f054b967d9 Remove leftover reference to !ping-related commands 2015-05-27 21:45:26 +02:00
Emanuel Barry
edbe6535ad Fix !fjoin to be case-insensitive 2015-05-27 14:35:59 -04:00
Emanuel Barry
4393f3413a Allow piper to select a single target at all times
Per request from @jacob1 and some evidence from a game. It makes it easier for piper to win.
2015-05-27 14:30:40 -04:00
nyuszika7h
019a9c3b34 Suggest "!help pingif" in the !ping removal notice
It's faster to use !help, and if someone wants more information, the
help for !pingif links to the wiki page anyway.
2015-05-27 15:16:16 +02:00
nyuszika7h
c3290b2d11 s/was/has been/ in !ping removal notice
Present perfect makes more sense here.
2015-05-27 15:09:29 +02:00
nyuszika7h
8c9561bbc3 Simplify notice about removal of !ping
I originally intended to amend @Vgr255's commit to include this, but I
screwed up, so here it is now. >_>
2015-05-27 15:06:39 +02:00
nyuszika7h
f97ca2cd8b Merge branch 'ping-removal' 2015-05-27 15:05:17 +02:00
Vgr E.Barry
fe1527eb3c Remove !ping and related commands
This replaces !ping, !away and !back with a dummy command that tells
people about !pingif.
2015-05-27 15:03:00 +02:00
Vgr E.Barry
9ecb95674b Allow lover to win with piper 2015-05-27 00:18:40 -04:00
Vgr E.Barry
d8ee335d58 Add missing individual win for pipers 2015-05-27 00:13:35 -04:00
Vgr E.Barry
ca5d77fa62 Fix inconsistent bold in revealroles 2015-05-27 00:06:53 -04:00
Vgr E.Barry
04c814ea16 ♪ come, children, come out to the forest ♫
This adds the new piper role, whose goal is to charm all the other
players to win. The charmed players are told who else is charmed, every
night, and must find out the piper and lynch him to win. The piper is a
win stealer, and takes precedence over monster. They can select either
one or two targets, but unless there is exactly one person left to be
charmed, they must pick two targets.
2015-05-27 00:06:40 -04:00
Vgr E.Barry
c49c2647d8 Small tweaks to the guardian game mode 2015-05-26 14:19:19 -04:00
Vgr E.Barry
d3134643c8 Add the "guardian" game mode 2015-05-25 19:57:31 -04:00
skizzerz
dddf32134e curses!
Adds "warlock" role, which is wolf-aligned and in wolfchat. They cannot
kill, but they get to turn someone into a cursed villager each night
(the curse remains in place for the rest of the game). If they act
quickly enough, they can even impact the seer or oracle for the current
night!
2015-05-25 14:01:41 -05:00
skizzerz
d00c15e19d meow
Added werekitten role, which is seen villager by seer and is always
missed when shot (even by sharpshooter!). They can still nom tasty
villagers at night, including pesky visiting harlots.

Also fix minor bug with alpha wolf being roleswapped where night may end
prematurely due to not removing their kill selection.
2015-05-25 14:01:41 -05:00
nyuszika7h
b90a3c74ed Add wiki link to !pingif help 2015-05-25 21:01:09 +02:00
nyuszika7h
e046358a62 Check if var.AFTER_FLASTGAME is not None instead of truthy or callable
If someone sets it to something other than a function (well, callable
object) or None, it's a programming mistake and we want that to raise an
exception rather than be silently ignored.
2015-05-24 23:14:43 +02:00
nyuszika7h
0c7d5a8a53 Fix previous commit 2015-05-24 23:09:08 +02:00
nyuszika7h
8d9729cc15 Trigger !faftergame if the game was canceled because of timeout 2015-05-24 23:07:23 +02:00
Vgr E.Barry
90321582de Change function name (prevent clash with built-in) 2015-05-24 12:20:51 -04:00