1878 Commits

Author SHA1 Message Date
Mike Mueller
b489a4752b Only allow join if a game is running. 2012-03-27 22:57:54 -07:00
Mike Mueller
2fb7a3954b Fix regression in WordChain games.
Somehow I took out the code that handles public messages during a game.
2012-03-27 01:46:44 -07:00
Mike Mueller
e63a36b2c1 Turn debug mode off.
Did't mean to leave this on.
2012-03-27 01:39:55 -07:00
Mike Mueller
8eed3d5b52 Add technical setup note to README. 2012-03-27 01:27:42 -07:00
Mike Mueller
94ec34d5a6 General improvements to Worddle gameplay.
Added support for broadcasting messages in one shot if the IRC server
supports multiple targets. (Inspircd only right now, need to add support for
more servers.)  This will hopefully reduce flood issues and latency.

Cleaned up messages, improved use of color, added join notifications,
added a 'get ready' state 5 seconds before game starts.

Some code cleanup and refactoring.
2012-03-27 01:16:34 -07:00
Mike Mueller
353b5109dc Add a new game: Worddle
This is a clone of a famous game involving a 4x4 grid of random letters.
It uses Plugin's inFilter to filter out private messages to the bot during
the game, so that they are not treated as commands.  You can still send
commands to the bot using the command character during this period.  When
the game ends, the filter puts things back to normal.

Also implemented a new command when DEBUG is True, wordsolve, which shows
the solution to the current wordgame.
2012-03-26 16:39:37 -07:00
Mike Mueller
4bc4c0d858 Make _start_game arguments generic.
It shouldn't need to know what specific parameters the game will take.
(And its "length" parameter was out of date since the games currently
use "difficulty".)
2012-03-24 15:20:03 -07:00
skizzhg
d4e5e0ba4c Update l10n-it. 2012-03-16 18:28:05 +01:00
Valentin Lorentz
1d04fd547e Update all plugin .pot files. 2012-03-11 21:06:19 +00:00
Mike Mueller
d820ab1f1c Remove some useless checks.
Some solution length logic was previously moved to handle_message.  Some of
the code in _valid_solution became nonsensical (not broken, just weird).

Cleaned up.
2012-03-04 22:57:10 -08:00
Mike Mueller
943b0c2adf More README updates. 2012-03-04 15:26:32 -08:00
Mike Mueller
60c7fd09e7 Update the command help in README. 2012-03-04 14:05:17 -08:00
Mike Mueller
b69967628a Change default dictionary and improve configurability.
Now defaults to the /usr/share/dict/american-english dictionary which is
probably found on many Linux systems today (avoiding the need to dig up a word
file on the interwebs).  On Debian/Ubuntu, you can 'apt-get install wamerican'.

Added a configurable regexp to filter the word list down to reasonable words.
Defaults to allow lowercase a-z only, therefore filtering out proper names,
hyphenations, contractions, and words with accented characters like "adiós".
(But hopefully still supporting non-English users by allowing this to be
changed.)
2012-03-04 13:46:46 -08:00
Mike Mueller
82e4665a82 Minor wording fix. 2012-03-03 14:42:58 -08:00
Mike Mueller
029ba10906 Oops, handle missing word file gracefully.
Apparently I backed out the previous change that handled this.
2012-03-03 14:41:00 -08:00
Mike Mueller
844723d28a Filter duplicate words in puzzles.
Was occasionally generating a puzzle foo > --- > --- > foo.  Oops.
2012-03-02 17:23:31 -08:00
Mike Mueller
a443d66473 Fix a performance issue in _find_solutions.
WordTwist successors can take you in circles (scare > stare > scare),
so check for this condition to avoid generating overly many potential
solutions.
2012-03-02 17:04:21 -08:00
Mike Mueller
17d1f91f8c Revise game difficulty settings.
Instead of taking lengths, the games now take easy|medium|hard|evil.
These values correspond to a range of puzzle lengths, word lengths, and
number of possible solutions.  I attempted to tune them to reasonable
values, but I could see them changing.

Also did a little more code clean-up.
2012-03-02 16:46:54 -08:00
Mike Mueller
b519259f54 Update copyright information. 2012-03-02 15:25:44 -08:00
Valentin Lorentz
b42d8a3e5f BadWords: Fix commit 123c17663732e0130fcf2b3fb53e949667aca4cf. 2012-02-25 14:02:02 +01:00
Mike Mueller
51ca3bedfd Improve WordShrink's is_trivial definition.
No substrings should occur in any word of any solution (not just two
successive words).  This is really going to narrow down the set of puzzles,
hopefully it doesn't churn or get repetitive.
2012-02-24 20:18:36 -08:00
Mike Mueller
5e570f61c1 Refactor, optimize, clean-up.
The two games have a lot in common, so factored out a base class called
WordChain that implements most of the logic.  The game-specific behaviors
are implemented in the (now smaller) WordTwist and WordShrink classes.

Optimized to build a map of word relationships first and then derive all game
behavior from that map.  This could probably be improved even more, but for
the moment it is working nicely.
2012-02-24 19:17:05 -08:00
Mike Mueller
25136ae926 Fix a bug in error reporting. 2012-02-24 01:04:10 -08:00
Mike Mueller
e74ca803fe Restrict input snarfing a bit.
Only attempt to validate responses that look like words.
2012-02-24 00:33:14 -08:00
Mike Mueller
180252e826 Handle missing wordfile gracefully. 2012-02-24 03:21:45 -05:00
Mike Mueller
4afb3cbe3e Initial commit! 2012-02-24 00:10:33 -08:00
nyuszika7h
8a1a1a1ddb BadWords: Make configuration variable requireWordBoundaries channel-specific 2012-02-18 19:37:55 +08:00
skizzhg
38413b2fe5 Coffee & Trivia: Add l10n-it. 2011-11-07 19:41:16 +01:00
Florian Besser
46abd9603e Trivia: Add l10n-de 2011-11-01 19:47:57 +01:00
Florian Besser
016e07dceb Trivia: internationalize 2011-11-01 19:47:25 +01:00
Mika Suomalainen
a8384339c3 BadWords: fixed more typos. 2011-08-16 17:17:34 +03:00
Mika Suomalainen
0122fcbb92 BadWords: fixed typos in l10n-fi. 2011-08-16 16:54:10 +03:00
skizzhg
92aa57f043 Update l10n-it for many plugins. 2011-08-07 11:16:04 +02:00
Mika Suomalainen
8c0f8fe8fe BadWords: updated l18n-fi 2011-07-16 22:55:27 +03:00
Valentin Lorentz
d1fd70c94f BadWord & ChannelStats & Owner: update l10n-fr. 2011-06-30 13:31:45 +02:00
Valentin Lorentz
95e8cf3dc8 AutoMode & BadWord & Config & Format & Karma & Later & Web: Add/update l10n-it. 2011-06-30 09:56:25 +02:00
Valentin Lorentz
f4659b86ba Trivia: edit __init__.py 2011-03-02 15:29:21 +01:00
Valentin Lorentz
baf95b1d19 Trivia: enhance code, and testStartStop() 2011-03-02 15:19:14 +01:00
Valentin Lorentz
27c46ee1e6 Trivia: import from quantumlemur repository. 2011-03-02 11:10:44 +01:00
Mika Suomalainen
61e04a4b1f Admin & Alias & Anonymous & AutoMode & BadWord & Channel & ChannelLogger: update/create Finnish translation 2011-02-28 16:45:53 +01:00
Valentin Lorentz
9b9be73cf9 BadWord & Channel: add Finish translation 2011-02-28 09:47:00 +01:00
Valentin Lorentz
c9ee7bc4ef (Re)generate all plugin's .pot file 2011-02-26 10:40:50 +01:00
SpiderDave
267911143f Adding Uno plugin 2011-02-22 01:42:50 -05:00
Valentin Lorentz
c986dcfe2f Update BadWord's .pot and fr.po 2011-01-29 11:52:14 +01:00
Daniel Folkinshteyn
00d6438cac BadWords: improve help for requireWordBoundaries config.
Make a note that the plugin requires restart or the words set updating,
for changes to this setting to take effect.
2011-01-29 11:47:23 +01:00
Daniel Folkinshteyn
ef8db55695 Badwords: add plugin docstring, and fix/standardize some method docstrings. 2011-01-29 11:46:14 +01:00
quantumlemur
242f6057ff Fixed infinite throw-back loop 2011-01-06 19:03:48 -05:00
quantumlemur
4588caae9f Fixed infinite throw-back loop 2011-01-06 18:56:16 -05:00
Valentin Lorentz
1344f2897d Localize AutoMode, BadWords, and Channel into French 2010-10-25 17:56:17 +02:00
Valentin Lorentz
64f6c734f5 Internationalize Alias, Anonymous, AutoMode, and BadWord 2010-10-16 18:54:18 +02:00