maverick.players.FoldBot

maverick.players.FoldBot#

class maverick.players.FoldBot(*, uid: str | None = None, name: str, state: PlayerState | dict | None = None, **kwargs)[source]#

A passive bot that always folds when possible.

__init__(*, uid: str | None = None, name: str, state: PlayerState | dict | None = None, **kwargs)#

Methods

__init__(*[, uid, state])

decide_action(*, valid_actions, **_)

Always call or check if possible, otherwise fold.

get_by_uid(uid)

Get a player class by its unique identifier.

on_event(event, game)

Optional hook called when a game event occurs.

to_dict()

Serialize the player to a dictionary.

Attributes

cls_uid

id

use uid instead.

register

decide_action(*, valid_actions: list[ActionType], **_) PlayerAction[source]#

Always call or check if possible, otherwise fold.