资源说明:A liar's dice server written in ruby.
Liard
Liard is a tcp server to host a game of liar's dice.
Running the server is as simple as:
gem install liard
liard start
The server runs by default on port 9001.
The simplest client is a human connecting with a tool like telnet:
telnet localhost 9001
Welcome to Liard!!!
> HELP
-- Commands from client
HELP [] Lists these commands, or command specific help if a command is given
*SETNAME Set a unique name to identify the connection
UNREADY Set client status to "not ready" for restart
READY Set client status to "ready" for restart
BID Creates a bid of (e.g. four 3's)
CHALLENGE Challenges last bid (if one exists)
CHAT Sends a message to all clients
WHO [ ...] Request a list of PLAYER responses from the server
WHOSETURN Request a CURRENTTURN response from server
-- Commands from server
BID Indicates a bid from of (e.g. eight 5's)
CHALLENGE Indicates a challenge from
CHAT : Indicates a chat message from
CURRENTTURN Indicates whose turn it is and how much time before they timeout
LOSEDICE Indicates that lost number of dice
LOSEDICEALL Indicates that all remaining players, except , lose one die each
PLAYER Indicates how many remaining dice a player has
RESULT <#> [<#> ...] Reveals another person's roll (after a challenge)
ROLL <#> [<#> ...] Your roll for the round
MESSAGE Precedes any general communication from the server
ERROR Precedes any error communications from the server
STARTING Indicates a restart in 15 seconds or when all clients report ready (whichever occurs first)
*Must be called before other commands and within 15 seconds of connecting.
>
本源码包内暂不包含可直接显示的源代码文件,请下载源码包。
English
