Laser Squad Nemesis Tournament Administrator System

 

INFORMATIONAL FUNCTIONS

There are a number of calls which provide xml data in the http response.

CURRENT GAMES

Call this url, with your admin_id, to get a list of your games still in progress:

http://codo-linux1.bytemark.co.uk/GameAdmin/CurrentGames

You will get an xml list of games in progress, with data for game_id and current game turn. You must check for errors, as with the start game call.

sample xml response:

<current_games>
  <admin_id>OK</admin_id>
  <ip_check>OK</ip_check>
  <errors>0</errors>
  <game>
    <id>1001274 </id>
    <turn>12</turn>
  </game>
  <game>
    <id>1002467</id>
    <turn>8</turn>
  </game>
</current_games>

FINISHED GAMES

Call this url, with your admin_id, to get a list of your finished games:

http://codo-linux1.bytemark.co.uk/GameAdmin/FinishedGames

You will get an xml list of finished games, with data for game_id and winner. The winner is '1' for player 1, '2' for player 2 or 'd' for drawn. You must check for errors, as with the start game call.

sample xml response:

<finished_games>
  <admin_id>OK</admin_id>
  <ip_check>OK</ip_check>
  <errors>0</errors>
  <game>
    <id>1005847</id>
    <winner>1</winner>
  </game>
  <game>
    <id>1007866</id>
    <winner>d</winner>
  </game>
</finished_games>

MAP LIST

You can call a url to obtain a current list of maps. You should check the map list for valid map names before initiating each game.

The maps available for your tournament include all maps in the official pool, plus maps which have been tagged as 'tournament only'. In order to upload your own maps and make them available for your tournament you will need map administrator status. You should apply for this when you need it.

Call this url, with your admin_id, to get a list of all available maps:

http://codo-linux1.bytemark.co.uk/GameAdmin/Maps

sample xml response:

<maps>
  <admin_id>OK</admin_id>
  <ip_check>OK</ip_check>
  <errors>0</errors>
  <map>
    <name>Crossroads</name>
    <x_size>50</x_size>
    <y_size>50</y_size>
    <tournament_only>1</tournament_only>
    <random_pool>0</random_pool>
  </game>
  <map>
    <name>Front Line</name>
    <x_size>60</x_size>
    <y_size>60</y_size>
    <tournament_only>0</tournament_only>
    <random_pool>1</random_pool>
  </game>
</maps>

'tournament_only' is '1' if the map is reserved for tournament games and not in the general pool. 'random_pool' is '1' if the map is included in random map selections for games.

CALLBACK FAILURES

You can check a list of callback failures to your callback url for aborted or finished games. Call this url with your admin_id:

http://codo-linux1.bytemark.co.uk/GameAdmin/CallbackFailures

Sample xml response:

<callback_failures>
  <admin_id>OK</admin_id>
  <ip_check>OK</ip_check>
  <errors>0</errors>
  <total_failures>2</total_failures>
  <failure>
    <data_type>game_over</data_type>
    <game_id>1002784</game_id>
    <winner>1</winner>
    <win_type>normal</win_type>
  </failure>
  <failure>
    <data_type>start_abort</data_type>
    <game_id>1008793</game_id>
    <player1>1</player1>
    <player2>0</player2>
  </failure>
</callback_failures>