PHP 클래스 Slackwolf\Game\GameManager

파일 보기 프로젝트 열기: chrisgillis/slackwolf 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$optionsManager OptionsManager

공개 메소드들

메소드 설명
__construct ( RealTimeClient $client, array $commandBindings ) Defines the GameManager constructor.
changeGameState ( $gameId, $newGameState )
endGame ( $id, null $enderUserId = null )
getGame ( $id ) : Game | boolean
hasGame ( $id ) : boolean
input ( Message $message ) : boolean
newGame ( $id, array $users, $roleStrategy )
sendMessageToChannel ( Game $game, $msg ) Sends a message to a game.
startGame ( $id )
vote ( Game $game, $voterId, $voteForId )

비공개 메소드들

메소드 설명
addGame ( Game $game )
onDay ( Game $game )
onFirstNight ( Game $game )
onGameOver ( Game $game )
onNight ( Game $game )
onNightEnd ( Game $game )

메소드 상세

__construct() 공개 메소드

Defines the GameManager constructor.
public __construct ( RealTimeClient $client, array $commandBindings )
$client Slack\RealTimeClient
$commandBindings array

changeGameState() 공개 메소드

public changeGameState ( $gameId, $newGameState )
$gameId
$newGameState

endGame() 공개 메소드

public endGame ( $id, null $enderUserId = null )
$id
$enderUserId null

getGame() 공개 메소드

public getGame ( $id ) : Game | boolean
$id
리턴 Game | boolean

hasGame() 공개 메소드

public hasGame ( $id ) : boolean
$id
리턴 boolean

input() 공개 메소드

public input ( Message $message ) : boolean
$message Slackwolf\Message\Message
리턴 boolean

newGame() 공개 메소드

public newGame ( $id, array $users, $roleStrategy )
$id
$users array
$roleStrategy

sendMessageToChannel() 공개 메소드

Sends a message to a game.
public sendMessageToChannel ( Game $game, $msg )
$game Game The game to send the message.
$msg The message.

startGame() 공개 메소드

public startGame ( $id )
$id

vote() 공개 메소드

public vote ( Game $game, $voterId, $voteForId )
$game Game
$voterId
$voteForId

프로퍼티 상세

$optionsManager 공개적으로 프로퍼티

public OptionsManager,Slackwolf\Game $optionsManager
리턴 OptionsManager