Sides Policy

Sides Policy is part of the sheet policy avaiable in the Settings sidebar. It is held in a JSON text string..

Example Sides Policy:

{
    "name": "Wellington Premier Interclub",
    "sidesOf": 3,
    "forfeit": "0-10",
    "poolPlay": {
        "fields": ["matchPoints","gamesFor","shotsFor","shotsAg"],
        "matchPoints": {
            "gameScope": [[11,99,8],[1,10,7],[0,0,4],[-2,-1,1]],
            "matchScope": []
        }
    },
    "livesPlay": {
        "fields": ["gamesFor"]
    }
}

The indenting and spacing is not important. You would paste this in Settings as:

{"name":"Wellington Premier Interclub","sidesOf":3,"forfeit":"0-10","poolPlay":{"fields": ["matchPoints","gamesFor","shotsFor","shotsAg"],"matchPoints":{"gameScope":[[11,99,8],[1,10,7],[0,0,4],[-2,-1,1]],"matchScope":[]}},"livesPlay":{"fields":["gamesFor"]}}

Note that the syntax is important. You must verify that your string is valid JSON before Saving the Settings. Chartroom does not check this for you, and sides play will not work if it is not valid. If stumped see Getting Help.


name

For documentation purposes only. Optional.

sidesOf

How many teams per side.

forfeit

The score to be used for a forfeited game.


poolPlay

Policy to say what fields you want written to the hidden columns, and how to determine the match result.

fields

This is a list of fields to be derived from the sides score. The first field in the list (in this case matchPoints) is used to determine the result, i.e. win, loss, or draw. The fields are then used in sheet formulas to calculate the sides' ranks within the pool, and later used for sorting.

Allowable fields are: ["matchPoints","matchWld","gamesFor","gamesAg","shotsFor","shotsAg"]

But only "matchPoints", "gamesFor", or "shotsFor" can be first in the list.

matchPoints at game scope

This is a list of 3-item arrays saying how matchPoints are calculated from the score in each of the games.

[11,99,8] says a win by 11 to 99 shots is worth 8 match points.
[1,10,7] says a win by 1 to 10 shots is worth 7
[0,0,4] says a draw is worth 4
[-2,-1,1] says a loss by 1 or 2 shots is worth 1 point

matchPoints at match scope

Is a similar list of 3-item arrays saying how matchPoints are calculated from the aggregate score of all games. In this example there are no matchPoints at match scope so the list is empty.


livesPlay

Policy to say how the match result is determined. Can be the same as poolPolicy.

Unless you specifically want to allow draws (and Chartroom supports draws in lives play) you should write livesPolicy that is guaranteed to find a winner for all possible game scores. Luckily that is not hard.

fields

"fields": ["gamesFor"] says that the side winning the most games will win the match. This is the simplest policy when sidesOf is odd.

"bestOf":true is another way to specify the same thing.