Mafia Bot

This forum is for discussion related to the game.
User avatar
Narninian
Narninian
Contracts STDs
User avatar
User avatar
Narninian
Contracts STDs
Contracts STDs
Posts: 1653
Joined: March 11, 2004
Location: Santa Barbara, California

Mafia Bot

Post Post #0 (ISO) » Mon Apr 26, 2004 8:40 pm

Post by Narninian »

I've programmed a bot that will send out roles for 2 player (confrontation) 3 player (endgame) and 4+5 player(lyncher) mafia.

Its an AIM bot - so it would would require AIM names to use it.

How it works: The user says a command (currently newlynchergame) to start the process - they then start inputting names, and say /done when all the names are put in. The bot will determine which game is being played (confrontation, endgame, or lyncher) mafia and send Instant messages to the people with randomly distributed roles.

I didn't have the chance to playtest it yet - so I'm hoping some of you people with AIM SNs will help me with that (if you dont have AIM you should get it anyway!) tommorow.

The reason I made it - was so we could play with 1 more person (no need for a mod - the mafia would just IM who they killed and that person would reveal their own role). One flaw I can think of is it rely's on the honor system for the lyncher - but i don't see that as a problem with the people who chat on mafiascum - plus I might be able to figure out how to log it somehow. If the IM thing works - I will try to get the bot to work with AIM Chat - so to join a game players simply have to say /in, and the bot records those users until somebody says /done.

What do you guys think - Is this a worthy project? It seems like we're always short a couple people in chat - this would help out the process. Thoughts? Comment? Suggestions?
The extra in is for /in
User avatar
shadyforce
shadyforce
U-S-E_T-H-E_F-O-R-C-E
User avatar
User avatar
shadyforce
U-S-E_T-H-E_F-O-R-C-E
U-S-E_T-H-E_F-O-R-C-E
Posts: 951
Joined: August 21, 2003
Location: Dublin

Post Post #1 (ISO) » Tue Apr 27, 2004 4:51 am

Post by shadyforce »

Well, you already know how I feel. I'll playtest it with you at the next opportunity.
[size=75][color=darkblue]I'm never wrong... well I was wrong once but that was when I thought I'd made a mistake but hadn't.[/color][/size]
User avatar
Narninian
Narninian
Contracts STDs
User avatar
User avatar
Narninian
Contracts STDs
Contracts STDs
Posts: 1653
Joined: March 11, 2004
Location: Santa Barbara, California

Post Post #2 (ISO) » Tue Apr 27, 2004 4:59 am

Post by Narninian »

wheeee! I'm online now and I need playtesters! AIM: Narninian if you want to help me play test.

Trail 1: FAILED - User blocked
Trail 2: Succeeded with 2 player mafia with my own screennames
Trail 3: AIM express user blocked, doesnt work with Shadyfours
Trail 4: Succeeded with 2 player mafia with another AIM User, 3 player mafia sends out a message to one person and then stops.
Trial 5: Making Progress, Message sent to player 1 and player 2 - error for player 3 message

Trail 6: SUCCESS!!!! Thank you Nanookthewolf, Willows_Weep, and Shadyforce for testing up to this point. 2 player and 3 player mafia now work - Getting 4 player and 5 player to work should be a cynch.


currently coding 4 player mafia.
The extra in is for /in
User avatar
jeep
jeep
Cappo Bastone
User avatar
User avatar
jeep
Cappo Bastone
Cappo Bastone
Posts: 747
Joined: April 21, 2002
Location: Portland, OR

Post Post #3 (ISO) » Tue May 04, 2004 12:05 am

Post by jeep »

Dourgrim's wish list with markup and additions:
  • Mod should be able to set a custom list of names (list of people who are alive in the game, names must
    not
    be limited to the SMs of the players since so many players have such hard-to-type SNs) with which the bot will tally votes automatically. It should be easy for the Mod to remove names from that list as players die, etc.
    /assign <alias> <playername>;; I also think it can match the beginning unique string in a name...
  • Bot reads votes and on lynch publishes lynchee's role
    /vote <name|alias|abbreviation>
    /unvote
  • Mod should be able to tell the bot to publish a votecount to the channel with a simple IM command.
    /votecount [full]
  • Mod should be able to set a deadline and have the bot enforce it via a timer of some sort. (If the bot could send regular reminders as to time remaining before deadline too, that'd be ultra-cool!)
    /deadline <minutes> ??
  • Mod should be able to easily remove names from the "alive" list (after processing a Night, for example).
    /kill <name>
  • Bot should be able to publish to the channel a list of alive/dead players (with role names. even?) with a simple IM'd command from the Mod.
    /setup [display|<preconfigured>|<setupstring>]
    <setupstring> = Mafia=>#, Townie=>#, <sanity>Cop=>#, Doc=>#
    <sanity> = Sane|Insane|Naive|Paranoid (cap letters are required, rest optional)
    <preconfigured> = Groza|Dethy|...
  • Bot reads commands for in
    /in
  • Bot randomizes roles and sends them out
  • Handle night actions?
User avatar
jeep
jeep
Cappo Bastone
User avatar
User avatar
jeep
Cappo Bastone
Cappo Bastone
Posts: 747
Joined: April 21, 2002
Location: Portland, OR

Post Post #4 (ISO) » Wed May 05, 2004 10:59 pm

Post by jeep »

Give me pre-defined setups:

Code: Select all

Dethy:
    Players: 5
        1 Sane_cop
        1 Insane_cop
        1 Paranoid_cop
        1 Naive_Cop
        1 Mafia1
    Special rules: cop head start
DoubleDeth
    Players: 10
        2 Sane_cop
        2 Insane_cop
        2 Paranoid_cop
        2 Naive_Cop
        2 Mafia1
Groza
    Players 12
        2 Sane_cop
        2 Insane_cop
        2 Paranoid_cop
        2 Naive_Cop
        1 Retired Cop (takes sanity of replacement)
        3 Mafia1
User avatar
cuban smoker
cuban smoker
An Acquired Taste
User avatar
User avatar
cuban smoker
An Acquired Taste
An Acquired Taste
Posts: 493
Joined: August 19, 2002
Location: Kitchener, Ontario

Post Post #5 (ISO) » Thu May 06, 2004 8:12 am

Post by cuban smoker »

Can you have doctors? lynchers? other roles?
User avatar
jeep
jeep
Cappo Bastone
User avatar
User avatar
jeep
Cappo Bastone
Cappo Bastone
Posts: 747
Joined: April 21, 2002
Location: Portland, OR

Post Post #6 (ISO) » Thu May 06, 2004 8:47 am

Post by jeep »

Sure... We want these to be the "common" set ups that people will want to replay (try to get a set up for all ranges 4-10) and will eventually be modded by the bot.

I would also like a set of rules for random setups... so we have 8 players, but don't want to play a "known" set up..

I was thinking something like:
  • 20-30% mafia (minimum 1)
    Remaining players get assigned a random role of:

  • 30% chance of being Cop (even chance of Sane, Insane, Paranoid, Naive)
  • 20% chance at being Doctor
  • Else: Townie
If I do that, I want to be in the game with all mafia and Doctors.
User avatar
mathcam
mathcam
Captain Observant
User avatar
User avatar
mathcam
Captain Observant
Captain Observant
Posts: 6116
Joined: November 22, 2002

Post Post #7 (ISO) » Thu May 06, 2004 9:39 am

Post by mathcam »

We often played IRL mafia with a whole deck of cards filled with roles and each player got one at random. The bot could have 60 or so roles to randomly distribute. I'm not sure how well this would work if we didn't add in the distinction between motives and roles, though.

Cam
User avatar
cuban smoker
cuban smoker
An Acquired Taste
User avatar
User avatar
cuban smoker
An Acquired Taste
An Acquired Taste
Posts: 493
Joined: August 19, 2002
Location: Kitchener, Ontario

Post Post #8 (ISO) » Fri May 07, 2004 1:57 am

Post by cuban smoker »

Well, 6 player dethy tosses in a doctor to the setup, and starts at night.

Lynhcer is simple: 1 mafia, 1 lyncher, 3 townies.
User avatar
jeep
jeep
Cappo Bastone
User avatar
User avatar
jeep
Cappo Bastone
Cappo Bastone
Posts: 747
Joined: April 21, 2002
Location: Portland, OR

Post Post #9 (ISO) » Fri May 07, 2004 7:08 am

Post by jeep »

6 player dethy with doctor is way unfair to mafia... The best case for mafia in 5 player is to get to 3 player end game with one cop knowing he's mafia. It makes it a 50/50 shot for him. And it requires a little luck in who/what you claim.

With 6 player you have confirmed innocent Day 1. (If Doc has counter claim, then you lynch the two docs day 1 and 2 and town wins.

-JEEP
User avatar
Flying Dutchman
Flying Dutchman
I never think
User avatar
User avatar
Flying Dutchman
I never think
I never think
Posts: 1941
Joined: November 21, 2003
Location: The land of clogs, tulips, mills, and cheese!

Post Post #10 (ISO) » Fri May 07, 2004 7:35 am

Post by Flying Dutchman »

Standard newbie setup should be in that list too.....

And newbie setup with 8 players and a vig.
User avatar
Wacky
Wacky
Goon
User avatar
User avatar
Wacky
Goon
Goon
Posts: 866
Joined: July 16, 2003
Location: Sydney, Australia

Post Post #11 (ISO) » Fri May 07, 2004 6:03 pm

Post by Wacky »

Let's not get ahead of ourselves here..

We should have Darth Vader and Flying Pumpkins and Lion King Mafia and ....

Is it possible for a bot to work with the mafiascum forum? Cos that would be
really
neat.
...whatever remains, however improbable, must be the truth.
User avatar
jeep
jeep
Cappo Bastone
User avatar
User avatar
jeep
Cappo Bastone
Cappo Bastone
Posts: 747
Joined: April 21, 2002
Location: Portland, OR

Post Post #12 (ISO) » Fri May 07, 2004 7:07 pm

Post by jeep »

Is it possible for a bot to work with the mafiascum forum? Cos that would be really neat.
How so? I'm using the same classes for JEEPbot, but that is going to be more difficult.

-JEEP
User avatar
Wacky
Wacky
Goon
User avatar
User avatar
Wacky
Goon
Goon
Posts: 866
Joined: July 16, 2003
Location: Sydney, Australia

Post Post #13 (ISO) » Mon May 10, 2004 8:45 pm

Post by Wacky »

Well, it would be neat becuase then you could possibly have automatically run games. No more vote counting. Possibly even have balanced game setups generated from a pool of roles with approximate points value to town...
...whatever remains, however improbable, must be the truth.
User avatar
jeep
jeep
Cappo Bastone
User avatar
User avatar
jeep
Cappo Bastone
Cappo Bastone
Posts: 747
Joined: April 21, 2002
Location: Portland, OR

Post Post #14 (ISO) » Mon May 10, 2004 10:46 pm

Post by jeep »

I actually started working on that... This bot, will not interface with the forum, however I will probably reuse the same classes.

-JEEP
User avatar
mith
mith
Godfather
User avatar
User avatar
mith
Godfather
Godfather
Posts: 9267
Joined: March 27, 2002
Location: McKinney, TX
Contact:

Post Post #15 (ISO) » Tue May 11, 2004 12:34 am

Post by mith »

There's already a mafia bot somewhere (Hy and JD and possibly someone else made it?); but it looks like you guys are doing just fine from scratch. :)
User avatar
jeep
jeep
Cappo Bastone
User avatar
User avatar
jeep
Cappo Bastone
Cappo Bastone
Posts: 747
Joined: April 21, 2002
Location: Portland, OR

Post Post #16 (ISO) » Tue May 11, 2004 7:58 am

Post by jeep »

point me to it! It's pretty straightforwards stuff, actually. Just getting the handlers correct.

-JEEP
User avatar
PolarBoy
PolarBoy
Sir Not-Appearing-In-This-Mafia
User avatar
User avatar
PolarBoy
Sir Not-Appearing-In-This-Mafia
Sir Not-Appearing-In-This-Mafia
Posts: 358
Joined: February 28, 2003

Post Post #17 (ISO) » Wed May 12, 2004 4:07 am

Post by PolarBoy »

Wacky wrote:We should have Darth Vader and Flying Pumpkins and Lion King Mafia and ....
For the last stinkin' time: Lion King Mafia was a theoretical exercise in BAD theme design.

As far as the bot is concerned, coolness. If I were able to use AIM I would be all over that. A forum bot would be neat. A "mixed theme" mode could be hilarious. The bot would have a gigantic pool of themed roles to pull from, and randomly grab them for the players. That could be awesome.
MUNSCM Delegate for the United Kingdom
Check out the [url=http://www.mafiascum.net/cgi-bin/wiki.pl?HomePage]ScumWiki[/url], and while you're at it, check out [url=http://www.mafiascum.net/cgi-bin/wiki.pl?DocumentModeMafia]DocumentModeMafia[/url]
User avatar
shadyforce
shadyforce
U-S-E_T-H-E_F-O-R-C-E
User avatar
User avatar
shadyforce
U-S-E_T-H-E_F-O-R-C-E
U-S-E_T-H-E_F-O-R-C-E
Posts: 951
Joined: August 21, 2003
Location: Dublin

Post Post #18 (ISO) » Wed May 12, 2004 5:13 am

Post by shadyforce »

Well, it would be a cool idea, but is it really that useful? It seems to me on this site (looking at the mini mod queues) that there is an abundance of mods, not players, unlike other gaming sites.
[size=75][color=darkblue]I'm never wrong... well I was wrong once but that was when I thought I'd made a mistake but hadn't.[/color][/size]
User avatar
PolarBoy
PolarBoy
Sir Not-Appearing-In-This-Mafia
User avatar
User avatar
PolarBoy
Sir Not-Appearing-In-This-Mafia
Sir Not-Appearing-In-This-Mafia
Posts: 358
Joined: February 28, 2003

Post Post #19 (ISO) » Wed May 12, 2004 6:14 am

Post by PolarBoy »

yeah, I was mainly thinking for AIM. I think most people would rather play chat games than mod them. I also think that a chat mixed theme game could be a good change of pace from the highly theoretical open setup games that we usually do.
MUNSCM Delegate for the United Kingdom
Check out the [url=http://www.mafiascum.net/cgi-bin/wiki.pl?HomePage]ScumWiki[/url], and while you're at it, check out [url=http://www.mafiascum.net/cgi-bin/wiki.pl?DocumentModeMafia]DocumentModeMafia[/url]
User avatar
jeep
jeep
Cappo Bastone
User avatar
User avatar
jeep
Cappo Bastone
Cappo Bastone
Posts: 747
Joined: April 21, 2002
Location: Portland, OR

Post Post #20 (ISO) » Wed May 12, 2004 6:46 am

Post by jeep »

The problem really is that we often have five people, which doesn't leave us enough to play (lyncher still needs some work). Also, it's primary function will be to track votes. It's difficult to keep track in a large game.

-JEEP
User avatar
shadyforce
shadyforce
U-S-E_T-H-E_F-O-R-C-E
User avatar
User avatar
shadyforce
U-S-E_T-H-E_F-O-R-C-E
U-S-E_T-H-E_F-O-R-C-E
Posts: 951
Joined: August 21, 2003
Location: Dublin

Post Post #21 (ISO) » Wed May 12, 2004 7:58 am

Post by shadyforce »

Oh yeah, I'm all for it in a chatroom situation, it's just for forums, I think it'll have limited use.
[size=75][color=darkblue]I'm never wrong... well I was wrong once but that was when I thought I'd made a mistake but hadn't.[/color][/size]
User avatar
jeep
jeep
Cappo Bastone
User avatar
User avatar
jeep
Cappo Bastone
Cappo Bastone
Posts: 747
Joined: April 21, 2002
Location: Portland, OR

Post Post #22 (ISO) » Wed May 12, 2004 10:04 am

Post by jeep »

Its an AIM bot - so it would would require AIM names to use it.
-JEEP
User avatar
shadyforce
shadyforce
U-S-E_T-H-E_F-O-R-C-E
User avatar
User avatar
shadyforce
U-S-E_T-H-E_F-O-R-C-E
U-S-E_T-H-E_F-O-R-C-E
Posts: 951
Joined: August 21, 2003
Location: Dublin

Post Post #23 (ISO) » Thu May 13, 2004 1:36 am

Post by shadyforce »

Ok, never mind. I thought someone had said somewhere to make a forum bot.
[size=75][color=darkblue]I'm never wrong... well I was wrong once but that was when I thought I'd made a mistake but hadn't.[/color][/size]
Post Reply

Return to “Mafia Discussion”