Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

📌 Bots Feedback Thread! #44

Open
ShrimpCryptid opened this issue Apr 14, 2023 · 14 comments
Open

📌 Bots Feedback Thread! #44

ShrimpCryptid opened this issue Apr 14, 2023 · 14 comments

Comments

@ShrimpCryptid
Copy link
Owner

ShrimpCryptid commented Apr 14, 2023

Hello! I've had more free time than usual lately (read: I was laid off 🥲), so I've been able to dedicate more time to fixing up Secret Hitler Online between job applications. Besides some stability and maintenance improvements, I added bot players to the game!

image

They can now sub in when lobbies have 1-4 players, and you can test it out by creating a lobby and pressing 'Start Game' with less than five players.

This is an experimental feature, so any feedback is appreciated!

I'm specifically looking for feedback on:

  1. Are bots stable? (does the game stall or crash?)
  2. Do the bots behave predictably? (do they help or hinder your team significantly?)
  3. Does anything else behave strangely when bots are enabled? (animation jitter, etc.)

If providing feedback on bot behavior, please also describe 1) what was happening in the game up until that point, 2) what the role of the bot was (if known), and 3) what the bot did that was unexpected.

Thanks so much, and happy playing!
-Shrimp


Quick Q&A:

Can we add more than 4 bots to a lobby? (games of 5+ bots)
Not currently! This is because the bots are, frankly, not very good at the game, and Secret Hitler is the most fun when you can read into player actions. If this is a popular feature request, I may reconsider it :)

How good are the bots at the game?
I need to collect more statistics on the backend to really analyze this in depth. From simulated games I've run with just bots, liberals win about 28% of the time and fascists the other 72%. (This is largely due to Hitler winning chancellor elections.) I'm not sure yet how they'll do in lobbies with players, though.

How do the bots work?
The bots assign every other player a reputation score. It goes up and down in response to player actions, like passing legislation, or by abilities, like the Investigation presidential power. This score is used to weight a random number generator for other actions, like selecting chancellor nominees or investigation targets. This decision-making changes based on the game progression and the role of the bot.

This means that a bot with the Liberal role will be less likely to nominate a player that has repeatedly passed fascist policies ((and more likely to use the Execution power on them instead lol)). Bots are also slightly more likely to choose users (you!) as chancellor or for other active roles, to prevent them from monopolizing game actions.

@ShrimpCryptid ShrimpCryptid self-assigned this Apr 14, 2023
@ShrimpCryptid ShrimpCryptid pinned this issue Apr 14, 2023
@pwclark12
Copy link

Bots seem to be automatically getting added to a 7-player game making it an 8-player game. This ruined a handful of games my Discord was playing since they play so poorly, especially in large groups. There was no way to remove the bot. Additionally, it may have been bad rng, but the bot was fascist 3 games in a row.

@ShrimpCryptid
Copy link
Owner Author

ShrimpCryptid commented Jul 31, 2023

Bots seem to be automatically getting added to a 7-player game making it an 8-player game. This ruined a handful of games my Discord was playing since they play so poorly, especially in large groups. There was no way to remove the bot. Additionally, it may have been bad rng, but the bot was fascist 3 games in a row.

Thanks for the feedback, I'll look into this. Bots should only be added to lobby sizes of four or less so it's strange that one was getting added. I can also confirm that Bot roles are assigned randomly, though it's unfortunate that it got assigned the same role three times in a row.

Could you also verify that it was a bot and not a player pretending to be one? Bots should have no player icon and will make decisions instantaneously.

@ShrimpCryptid
Copy link
Owner Author

Okay, I think I see the issue, actually. I wrote part of the code when I had assumed that bots would be added to lobbies of any size, rather than to just reach the minimum. Someone might have connected and disconnected, causing the lobby to set its size to 8 players and backfill with bots.

I'll issue a fix when I have time to sit down with the code in the next day or two. Thank you again for leaving a note!

@ShrimpCryptid ShrimpCryptid removed their assignment Sep 30, 2023
@sharkavx
Copy link

sharkavx commented Feb 8, 2024

Love the game and your design is very fluid and easy to use. As well the art is great, unique, while still reflecting the original game.

I've attached a screenshot from me trying the game, me and some friends are going to play tonight and I was curious how the bots behaved, we won't need them but still thought I'd try.

There were 2 issues, one was with the bot behaviour and the other was with roles assignment.

Only 1 Fascist policy got passed, which seemed fine at this low of player count. But then when the game ended it showed that all 4 of the bots were Fascists, and none of them was Hitler. Also this means that the Fascist bots won the game by themselves. The last 2 policies passed were done entirely by bots.

Screenshot 2024-02-08 131713

After that I played a couple more times and did not have any of the behaviour issues or roles assignment, it was just that first one.

@ShrimpCryptid
Copy link
Owner Author

Love the game and your design is very fluid and easy to use. As well the art is great, unique, while still reflecting the original game.

I've attached a screenshot from me trying the game, me and some friends are going to play tonight and I was curious how the bots behaved, we won't need them but still thought I'd try.

There were 2 issues, one was with the bot behaviour and the other was with roles assignment.

Only 1 Fascist policy got passed, which seemed fine at this low of player count. But then when the game ended it showed that all 4 of the bots were Fascists, and none of them was Hitler. Also this means that the Fascist bots won the game by themselves. The last 2 policies passed were done entirely by bots.

Screenshot 2024-02-08 131713

After that I played a couple more times and did not have any of the behaviour issues or roles assignment, it was just that first one.

That's super weird, thank you for the bug report! My guess is that the issue was the server revealing roles incorrectly, rather than the bots having all-Fascist roles assigned. I'll take a look and update here if I find a fix.

@JamesGames7
Copy link

About bot behaviours…I was playing a “solo” 5 person game, with me as a fascist. Hitler obviously knew who I was (as a bot, bc it’s 5 players). However, they decided to execute me for some reason. I don’t know what the logic is…I think I’d enacted 1 fascist policy total at that point with the others by them?

@ShrimpCryptid
Copy link
Owner Author

About bot behaviours…I was playing a “solo” 5 person game, with me as a fascist. Hitler obviously knew who I was (as a bot, bc it’s 5 players). However, they decided to execute me for some reason. I don’t know what the logic is…I think I’d enacted 1 fascist policy total at that point with the others by them?

BETRAYAL....
I'll take a look at the logic when I get the chance. Some of the Hitler bot's logic tries to copy Liberal roles in order to "pass" as one more effectively, so it's possible that I let that slip into the code that decides targeting for the execution action. Thanks for the feedback!

@ShrimpCryptid
Copy link
Owner Author

About bot behaviours…I was playing a “solo” 5 person game, with me as a fascist. Hitler obviously knew who I was (as a bot, bc it’s 5 players). However, they decided to execute me for some reason. I don’t know what the logic is…I think I’d enacted 1 fascist policy total at that point with the others by them?

Okay, update! I found where this is happening in the code. Here's the statement that bots with the fascist/hitler role are using to choose players:

selectedPlayer = chooseRandomPlayerWeighted(playerList, 0.5f, 0, 1f, 0);

So what this statement does is choose a player for the execution action with weighting for different roles. In this case, fascist roles are given a weight of 0.5, the hitler role is given a weight of 0, and liberal players are given a weight of 1.0. (The last 0 means that no particular weight is given to players vs. bots.)

I'll adjust this a bit so fascist roles are given less weight (and thus will be less likely to be chosen), though I do intend that bots with the fascist roles can turn on each other for sheer unpredictability/to gain player trust.

@Elishah007
Copy link

hello
Is there a part to buy in this game that will create more possibilities?

@Elishah007
Copy link

hello
I enjoy this program, thank you for your time.
If there is a paid part with more features, I will be happy to guide you.

@ShrimpCryptid
Copy link
Owner Author

hello I enjoy this program, thank you for your time. If there is a paid part with more features, I will be happy to guide you.

Aw, thank you, that's sweet of you! I'm unable to take donations due to the copyright license on this project, but hearing positive feedback really makes my day. See here for more details: #19.

I'm open to code contributions, though the project is in the middle of a big code overhaul that's been on hiatus for a few months. For now, my focus is just on maintaining it and keeping it running :')

@furrykef
Copy link

I suggest giving the bots names like "Elsa [BOT]", "Franz [BOT]", etc. When I'm playing with 4 bots, it's harder to remember a number than a name. "Wait, was Bot 3 president and Bot 1 chancellor when that happened, or was it the other way around? Or was one of them someone else?" The names kind of all blend together in my memory.

@ShrimpCryptid
Copy link
Owner Author

I suggest giving the bots names like "Elsa [BOT]", "Franz [BOT]", etc. When I'm playing with 4 bots, it's harder to remember a number than a name. "Wait, was Bot 3 president and Bot 1 chancellor when that happened, or was it the other way around? Or was one of them someone else?" The names kind of all blend together in my memory.

Interesting, I like this idea! Now, would you want the [BOT] label to be just part of the name or a special icon/indicator? Currently there's nothing stopping a player from naming themselves "Eli [BOT]" or something similar.

@furrykef
Copy link

A special icon or indicator would be better, I think, but making it part of the name works too. I don't think players would have anything to gain by untruthfully claiming to be a bot, but I could be wrong.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants