Libsaki
Core library of Pancake Mahjong
Classes | Public Types | Public Member Functions | List of all members
saki::Choices Class Reference

Choice set of one player. More...

#include <choices.h>

Collaboration diagram for saki::Choices:
Collaboration graph
[legend]

Classes

struct  ModeBark
 
struct  ModeDrawn
 
struct  ModeEnd
 
struct  ModeIrsCheck
 

Public Types

enum  Mode {
  WATCH, IRS_CHECK, DICE, DRAWN,
  BARK, END
}
 

Public Member Functions

bool any () const
 
Mode mode () const
 
bool can (ActCode act) const
 Check ablity without nonce. More...
 
bool canRiichi () const
 
bool spinOnly () const
 
Action timeout () const
 Provide a fallback action in this choices. Typically used as a placeholder on network timeout.
 
const ModeIrsCheckirsCheck () const
 
const ModeDrawndrawn () const
 
const ModeBarkbark () const
 
void setWatch ()
 
void setIrsCheck (const ModeIrsCheck &irsCheck)
 allow to set all items disabled, without switching mode to 'watch'
 
void setDice ()
 
void setDrawn (const ModeDrawn &mode)
 
void setBark (const ModeBark &mode)
 
void setEnd (const ModeEnd &mode)
 
void setIrsClick (const Choices &from)
 
void filter (const ChoiceFilter &f)
 

Detailed Description

Choice set of one player.

Member Function Documentation

◆ can()

bool saki::Choices::can ( ActCode  act) const

Check ablity without nonce.

Returns
true if the action in in the choice set

The documentation for this class was generated from the following files: