VGA Planets

Introduction

How The Website Works

Races

Dashboard

Starmap

Planets

Starships

General Information

Guides

Contributions

Searchable Documentation

API - Create Custom Game


Main Documentation —> Website —> API —> API /account/createcustomgame

This page is a work in progress. It is incomplete and probably contains errors.

Overview of /account/createcustomgame API call

The /account/createcustomgame API call is used to create a new custom game.

The data returned by this call is fairly limited, but it does include a list of gameids that matches the search pattern. These gameids can then be used to collect more information with other calls as needed.

This is a secured API call and requires an apikey.

Data sent

Data Description
apikey This is the API Key that is returned from the /account/login API.
settings This is a Settings object, as described below.

Notes

Data returned

Data Description

Settings Object

These values are being shown in the order that they're listed in the game creation process. The order of the parameters in the API call doesn't matter. Parameters that are not currently part of the game creation screen are listed at the end.

Settings Object Description
name Game short name.
description This is the long description for the game. It should contain any special rules that the hosting player wishes to be followed in the game. The <br> tag can be used to force a line break, and two of them can be used to force a blank line. This string is limited to 1024 characters.
wincondition
1      Diplomatic planets
2 Total planets
3 Military score
4 Fixed turn
5 All planets
minrank Minimum officer rank to join.
0      None
1 Midshipman
2 Ensign
3 Sub-Lieutenant
4 Lieutenant
5 Lieutenant Commander
6 Commander
7 Captain
8 Commodore
9 Read Admiral
10 Vice Admiral
11 Admiral
12 Fleet Admiral
13 Supreme Commander
14 Emperor (retired)
15 Emperor
maxrank Maximum officer rank to join. The value table is the same as for minrank.
mintenacity Minimum tenacity to join.
hostdays Days on which the game will host, after the fast start completes. This is a string based on "SMTWTFS" (represents the days of the week, starting with Sunday, and ending with Saturday), with the days on which the game will not host replaced by an underscore ("_").
hosttime Time host will run (in UTC ). One or two digits are used to indicate the hour of the day (0-23), followed by a colon, then two digits to indicate the minute. An example of this is "18:19"
faststart Turns at fast start (once per day) e.g. 15
campaignmode
true      the Campaign advantages are to be enabled for this game.
false the Campaign advantages are to be disabled for this game.
maxadvantage The number of advantage points that a player is allowed to use in a Campaign game. It is ignored in non-Campaign games.
fascistdoublebeams
true      the 2X Faster Beams advantage is to be enabled for Fury players in this game.
false the 2X Faster Beams advantage is to be disabled in this game.
superspyadvanced
true      the Super Spy Advanced advantage is to be enabled for Bird players in this game.
false the Super Spy Advanced advantage is to be disabled in this game.
starbasefightertransfer
true      the Starbase Fighter Transfer advantage is to be enabled for Empire players in this game.
false the Starbase Fighter Transfer advantage is to be disabled in this game.
cloakandintercept
true      the Cloak and Intercept advantage is to be enabled for Bird players in this game.
false the Cloak and Intercept advantage is to be disabled in this game.
shiplimittype
0      The ship limit will be global - one overall limit will apply to all players.
1 The ship limit will be per-player, and will be based on the number of planets the player controls, depending on the following three settings. The actual ship limit for a player is the greater of the minimum ship limit (plsminships) and the calculated ship limit ( TRUNC ( (player planets) * plsshipsperplanet + plsextraships ) ). It should be noted that this PLS (Planets Limits Ships) ship limit only applies to ship acquisitions (builds, captures and gifts). NOTE: When PLS is enabled, the Admins have advised that "fcodesmustmatchgsx" be set to "true" and that "cloningenabled" be set to "false".
plsminships This is the number of ships any empire can support, regardless of how many planets they control.
plsshipsperplanet The number of starships that each planet can support. This value is normally between 1.0 and 2.0.
plsextraships Each empire can support this many ships in addition to the ships received for the planets controlled.
productionqueue
true      the newer Production Queue is to be used for starship builds in this game.
false the classic Priority Queue is to be used for starship builds in this game.
productioncost The number of Priority Points that are added to the mass cost of a starship for Priority builds. This value is only used when the Production Queue is in use.
productionvalue The number of Priority Points that a starbase generates when it is selected for a build, but has no starship build queued. This value is only used when the Production Queue is in use.
productionreward The maximum number of Priority Points that a player could receive if they destroy an enemy starbase. The actual number of Priority Points received will never be more than the player has. This value is only used when the Production Queue is in use.
killrace
true      the KillRace mechanism is to be enabled in this game.
false the KillRace mechanism is to be disabled in this game.
fightorfail The minimum number of planets for Fight or Fail in this game. Setting this value to "0" will disable fixed Fight or Fail.
fofincrement The number of turns for an increase in the Fight or Fail limit. When this value is set to a value other than "0" Incremental Fight or Fail is enabled and the Fixed Fight or Fail value will be ignored.
stealth
true      the Stealth mechanism is to be enabled in this game.
false the Stealth mechanism is to be disabled in this game.
combatrng
0      the Classic Random Number Generator Tables are to be used for combat in this game.
1 the Extended Random Number Generator Tables are to be used for combat in this game.
cloningenabled
true      Cloning may occur as normal.
false All Cloning, including Advanced Cloning, is disabled.
emorkslegacy
true      the Emork's Legacy game extension is to be enabled in this game. This may only be done in Public games.
false the "Emork's Legacy" game extension is to be disabled in this game.
fcodesmustmatchgsx
true      both the starship being given away with the GSx Friendly Code and the starship receiving the gift have the same, case sensitive, Friendly Code.
false only the starship being given away with the GSx Friendly Code needs to have the code.
fcodesextraalchemy
true      the extended Alchemy Friendly Codes ( NAD , NAT and NAM ) are to be enabled in this game.
false the extended Alchemy Friendly Codes are to be disabled in this game.
fcodesbdx
true      the BD# Friendly code is to be enabled in the game.
false the BD# Friendly code is to be disabled in the game.
crystalwebimmunity This feature is in development. The value for this parameter should always be "0".
isprivate
true      this is to be a private game.
false this is to be a public game.
password This is the game password. It is required for players to enter the game.
maxallies This is the maximum number of allies that a player can have.
maxshareintel This is the maximum number of players that can have a Diplomacy setting of Share Intel or higher.
maxsafepassage This is the maximum number of players that can have a Diplomacy setting of Safe Passage or higher.
maxplayersperrace This is the maximum number of players that can be in the game with the same race.
shuffleteampositions
true      The order of the teams, and the players within the teams, will randomized prior to placement onto the Homeworlds.
false The teams and players will placed in player-slot order onto the Homeworlds.
players This is an array of Player Objects, as described below.
disallowedraces This optional parameter is a string containing a comma-separated list of the race numbers that players will not be allowed to select. It is only used when "User Choses Race" is an option for at least one player slot.
mapshape
0      Round
1    Rectangular
2 Irregular Round
mapwidth This is the width of the map in light-years.
mapheight This is the height of the map in light-years.
sphere
true      the wrap-around abilities of the map will be enabled, as described here.
false the wrap-around abilities of the map will be disabled.
homeworldlocations
1      Random Spaced
2 Circular
3 Left and Right
4 One vs. Circle - Private games only. The one player will be approximately in the center of the map. That player will occupy slot 1.
verycloseplanets This is the number of planets within 81 light-years of a Homeworld.
closeplanets This is the number of planets within 162 light-years of a Homeworld, but not within 81 light-years.
otherplanetsdist This is the minimum distance from the Homeworld to planets other than the verycloseplanets and the closeplanets .
wanderingtribescount This is the number of Super Transport Freighters that each player starts with. Each Super Transport Freighter will be equipped with TransWarp engines and will contain:
  • 1500 Clans
  • 1200 KT Neutronium
  • 200 KT Duranium
  • 200 KT Tritanium
  • 200 KT Molybdenum
  • 500 KT Supplies
  • 1000 MegaCredits
wanderingtribesdist This value indicates the distribution of the fleets of the players, as follows:
0      Homeworld Areas
1 Everyone at center point
2 Random - The individual starships are randomly distributed throughout the cluster
homestarbase
true      there will be a starbase at the homeworld.
false there will not be a starbase at the homeworld.
homeresources
1      Low
2 Middle
3 High
homeclans This is the number of clans that will be placed on Homeworlds when the map is created.
extraplanets This setting is for Private games only. This setting adds the specified number of colonized planets to all player slots. The additional planets will be those closest to the homeworld. For non-Horwasp players, the planets will be colonized with between 500 and 1,000 clans, and will have 50 mines, 100 factories and 20 defense posts. For Horwasp players, the planets will be colonized with 2,500 clans. If the homeworld locations value is set to One vs. Circle, and the centerextraplanets setting is supplied, this setting will not be used for the first slot.
extraships This setting is for Private games only. This setting adds the specified number of starships to all player slots. If the homeworld locations value is set to One vs. Circle, and the centerextraships setting is supplied, this setting will not be used for the first slot. Additional information on these extra starships can be found here.
centerextraplanets This setting is for Private games only. This setting may be used if the homeworld locations value is set to One vs. Circle. It adds the specified number of colonized planets to the first player slot. The additional planets will be those closest to the homeworld. For non-Horwasp players, the planets will be colonized with between 500 and 1,000 clans, and will have 50 mines, 100 factories and 20 defense posts. For Horwasp players, the planets will be colonized with 2,500 clans.
centerextraships This setting is for Private games only. This setting may be used if the homeworld locations are One vs. Circle. It adds the specified number of starships to the first player slot. Additional information on these extra starships can be found here.
shiplimit This is the maximum number of starships that can be built. Use of the Production Queue can allow more ships to be built.
planetscanrange This is the number of light-years that a star, star cluster, nebula or debris disk can be scanned at.
shipscanrange This is the number of light-years that a starship can be scanned at.
numplanets This is the number of planets that are in the map, before debris disks are created.
numstars This is the number of star clusters in the map.
numnebulas This is the number of Nebulae that will be on the map.
numdebris This is the number of planets that are to be converted to debris disks when the map is created. If other planets are very close to a newly created debris disk, they too will be converted to debris disks, but they will not be counted against this parameter.
maxionstorms This is the maximum number of Ion Storms that can exist at once in the map.
nuionstorms
true      the new Ion Storms (varying energy level within the Ion Storm) will be used in this game.
false the classic Ion Storms (same energy level throughout the Ion Storm) will be used in this game.
maxwormholes This is the maximum number of wormholes that can exist at once in the map.
wormholemix This is the percentage of Wormholes that allow travelling in both directions.
wormholescanrange This is the distance, in light-years, at which a Sensor Sweep mission will detect a Wormhole.
mineraldensity
1      Low
2 Middle
3 High
nativeprobability This is the chance that a planet will have natives.
nativegovernmentlevel
1      Low
2 Middle
3 High
nativeclansmin This is the minimum number of native clans that will exist on a planet when the map is created. This only applies to planets that have natives.
nativeclansmax This is the maximum number of native clans that will exist on a planet when the map is created. This only applies to planets that have natives.

Player Object

These values are being shown in the order that they're listed in the game creation process. The order of the parameters in the API call doesn't matter.

Player Object Description
id The numeric slot number that this player is to occupy.
raceid
0    The player chooses the race.
1 The player will play as the Federation.
2 The player will play as the Lizards.
3 The player will play as the Birds.
4 The player will play as the Fury.
5 The player will play as the Privateers.
6 The player will play as the Cyborg.
7 The player will play as the Crystals.
8 The player will play as the Empire.
9 The player will play as the Robots.
10 The player will play as the Rebels.
11 The player will play as the Colonies.
12 The player will play as the Horwasp.
100 The computer will play as a random race.
101 The computer will play as the Federation.
102 The computer will play as the Lizards.
103 The computer will play as the Birds.
104 The computer will play as the Fury.
105 The computer will play as the Privateers.
106 The computer will play as the Cyborg.
107 The computer will play as the Crystals.
108 The computer will play as the Empire.
109 The computer will play as the Robots.
110 The computer will play as the Rebels.
111 The computer will play as the Colonies.
112 The computer will play as the Horwasp.
teamid The team number that the player is to be assigned to. This is required to be present if there are to be preset teams, and it must not be present if there are no preset teams. The teamid values start at "1", and there can be no missing values in the sequence (e.g. 1, 2, 3 is valid, but 1, 3 isn't).

Failures

{"success":false,"error":"Game Ids in incorrect format"}

Back