rawsonj / triviabot

A simple IRC trivia bot written in python using twisted.
GNU General Public License v3.0
41 stars 52 forks source link

Friendly #38

Closed edunham closed 8 years ago

edunham commented 10 years ago

Synonyms. Synonyms everywhere! Spice up those boring old win messages. Sorry about the merge; apparently moving stuff around in trivia.py makes Git unhappy?

rawsonj commented 10 years ago

Git was unhappy because we changed the wording in the last PR of that function and I did funny things with history I think.

So feedback: I'm ok with generalizing the structure of the "_winner" messages and spicing them up, but if we are going to do that it should be done in a highly configurable way so that end-users can give the bot whatever personality they want to.

The new variables "messages," "gains," and "lousy" should exist in the example configuration file and just be used in the _winner function. Users could then add to them, remove from them, or completely rewrite them as they desire.

Also, I have issues with the variable names themselves, "messages" being a bit vague if we want to start customizing more messages in the bot for other user feedback functions, and "gains" and "lousy" have both of those strings in them, which means they are also not named properly.

I would propose that "messages" be called "win_messages" or something similar, and "gains" be called "reward_verbs" or something, and "lousy" be called "single_point_messages" or something.

This disambiguates the purpose of those string lists to what they are used for in the code.

Also, there should be a "default" behavior in _winner in the case that the user has removed those variables, since making the existence of those variables in the config I don't think should be a hard requirement. If those variables exist, we should use them, else, have a simple default message that won't offend anyone.

edunham commented 10 years ago

Haven't tested yet. Please don't merge.

edunham commented 8 years ago

Closing because I'm not going to fix this up in the foreseeable future. If anybody else would like to take these commits or ideas and do stuff with them, you're welcome to.

rawsonj commented 8 years ago

Me too. I've still been in the middle of a rewrite for a couple of years now.

Someday, when I retire in 35 years, I might get to incorporating this too. Thanks for the PR to get it started.