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

Allow custom cards and bots simultaneously #550

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

lhvy
Copy link
Contributor

@lhvy lhvy commented Nov 21, 2023

Resolves #548

Updates the draw functions to ignore blank cards if the player drawing is a bot.

@@ -560,47 +585,6 @@ startGameProblems shared wrap wrapLobby users model remote =
|> Maybe.justIf (humanPlayerCount < 1)
]

disableRandoConfig =
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if I should bring this back but check for "blank white cards only" instead to fix the above comment? And then I guess I'd need to hide the above error message I added in that case too...

const result = this.cards.splice(0, toDraw);
const result = this.cards
.splice(0, toDraw)
.filter((card) => card.source.source !== "Custom");
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This may mean that blank cards aren't being discarded properly when picked up by the bot. Not sure?

Comment on lines +458 to +470
-- Catch the case where "only blank white cards" is enabled.
numberOfNonBlankResponses =
case hr.comedyWriter of
Just { exclusive } ->
if exclusive then
0

else
summaries .responses

Nothing ->
summaries .responses

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need some feedback on this. Is this reasonable?

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

Successfully merging this pull request may close these issues.

blank white cards + rando cardrissian in the same game
1 participant