Go to the first, previous, next, last section, table of contents.

Scorekeeper Bodies

The forms in the body (the do property) of the scorekeeper may be any of the forms listed here.

ScorekeeperForm: last-side-wins

If supplied as the only symbol in the body, then the scorekeeper implements the usual "last side left in the game wins" behavior.

ScorekeeperForm: if test action

If the test evaluates to true or any nonzero number, then the action will be done.

ScorekeeperForm: cond (test actions...) ...

This is like Lisp's cond.

ScorekeeperForm: stop [message]

This stops the game immediately, with a draw for all sides.

ScorekeeperForm: win [sides] [own-message] [other-message]

ScorekeeperForm: lose [sides] [own-message] [other-message]

ScorekeeperForm: end [message]

This scorekeeper action ends the game immediately.

ScorekeeperForm: add exp [side]

This adds the result of evaluating exp to the score of the given side. The value may be a negative number.


Go to the first, previous, next, last section, table of contents.