Difference between revisions of "HowTo:Edit Systems:Milkyway"
(→gasgiantlist) |
(→XML Schema Description: added code tags + some fixes + links) |
||
Line 7: | Line 7: | ||
=XML Schema Description= | =XML Schema Description= | ||
− | * <galaxy> ... </galaxy> -- Marks the beginning and end of the XML file. | + | * <code><'''galaxy'''> ... </galaxy></code> -- Marks the beginning and end of the XML file. |
− | ** <systems> ... </systems> -- You need it but I don't know why. | + | ** <code><'''systems'''> ... </systems></code> -- You need it but I don't know why. |
− | *** <sector ... > ... </sector> -- (repeatable) A sector containg a group of systems. | + | *** <code><'''sector''' ... > ... </sector></code> -- (repeatable) A sector containg a group of systems. |
− | **** name -- the name of the sector. For, enigma_sector. | + | **** <code>name</code> -- the name of the sector. For, enigma_sector. |
− | **** < var ... /> -- (repeatable) The default variables for the entire sector (var tag to be described later) | + | **** <code>< var ... /></code> -- (repeatable) The default variables for the entire sector (var tag to be described later) |
− | **** <sector ... > ... </sector> -- (repeatable) A system (to be a system it must be inside another sector tag). | + | **** <code><'''sector''' ... > ... </sector></code> -- (repeatable) A system (to be a system it must be inside another sector tag). |
− | ***** name -- the name of the system, for example, heavens_gate. | + | ***** <code>name</code> -- the name of the system, for example, heavens_gate. |
− | ***** < var ... /> -- (repeatable) To be described later | + | ***** <code>< var ... /></code> -- (repeatable) To be described later |
==Variables== | ==Variables== | ||
− | The < var name="" value="" /> tag | + | The <code>< var name="" value="" /></code> tag |
Here is a list of all of the possible names and their values so far. If these variables are not set inside any of the sector tags (innermost overrides) the system will randomly use a number between the corresponding values of the unknown_sector/min and max "systems" | Here is a list of all of the possible names and their values so far. If these variables are not set inside any of the sector tags (innermost overrides) the system will randomly use a number between the corresponding values of the unknown_sector/min and max "systems" | ||
===Variable Types=== | ===Variable Types=== | ||
− | * BOOL = boolean value = "true" or "false" | + | * <code>BOOL</code> = boolean value = "<code>true</code>" or "<code>false</code>" |
− | * INT = integer | + | * <code>INT</code> = integer |
− | * FLOAT = decimal number | + | * <code>FLOAT</code> = decimal number |
− | * FILENAME = the name of a file inside the universe directory. | + | * <code>FILENAME</code> = the name of a file inside the universe directory. |
===Sun / Stars=== | ===Sun / Stars=== | ||
====num_stars==== | ====num_stars==== | ||
− | * Type: INT | + | * [[#Variable_Types|Type]]: <code>INT</code> |
* Description: The number of suns in the system (to make binary systems). | * Description: The number of suns in the system (to make binary systems). | ||
* Example: | * Example: | ||
Line 37: | Line 37: | ||
====sun_radius==== | ====sun_radius==== | ||
− | * Type: FLOAT | + | * [[#Variable_Types|Type]]: <code>FLOAT</code> |
* Description: The radius of the sun in the system. | * Description: The radius of the sun in the system. | ||
* Example: | * Example: | ||
Line 45: | Line 45: | ||
====starlist==== | ====starlist==== | ||
− | * Type: FILENAME | + | * [[#Variable_Types|Type]]: <code>FILENAME</code> |
* Description: A file with a list of colors/textures/sprites for different sizes of stars: | * Description: A file with a list of colors/textures/sprites for different sizes of stars: | ||
* Example | * Example | ||
Line 52: | Line 52: | ||
</pre> | </pre> | ||
* Contents of Stars.txt | * Contents of Stars.txt | ||
− | ** "0 .3 1 .3 .1 stars/white_star.png" | + | ** "<code>0 .3 1 .3 .1 stars/white_star.png</code>" |
− | ** "1000 .5 .5 1 .1 stars/white_star.png" | + | ** "<code>1000 .5 .5 1 .1 stars/white_star.png</code>" |
− | ** ... means, "if the radius of the star is greater than or equal to 0 but less than 1000, then use RGB color (.3,1,.3), variance (?) of .1 and a texture/sprite filename of "stars/white_star.png". The same goes for 1000, etc. | + | ** ... means, "if the radius of the star is greater than or equal to 0 but less than 1000, then use RGB color (.3,1,.3), variance (?) of .1 and a texture/sprite filename of "<code>stars/white_star.png</code>". The same goes for 1000, etc. |
===Planets=== | ===Planets=== | ||
====num_gas_giants==== | ====num_gas_giants==== | ||
− | * Type: INT | + | * [[#Variable_Types|Type]]: <code>INT</code> |
* Description: The number of gas giant planets. | * Description: The number of gas giant planets. | ||
* Example: | * Example: | ||
Line 66: | Line 66: | ||
====num_planets==== | ====num_planets==== | ||
− | * Type: INT | + | * [[#Variable_Types|Type]]: <code>INT</code> |
* Description: The total number of inhabited(?) planets (not including gas giants). | * Description: The total number of inhabited(?) planets (not including gas giants). | ||
* Example: | * Example: | ||
Line 74: | Line 74: | ||
====num_moons==== | ====num_moons==== | ||
− | * Type: INT | + | * [[#Variable_Types|Type]]: <code>INT</code> |
* Description: The number of moons orbiting any planet. | * Description: The number of moons orbiting any planet. | ||
* Example: | * Example: | ||
Line 82: | Line 82: | ||
====asteroids==== | ====asteroids==== | ||
− | * Type: BOOL | + | * [[#Variable_Types|Type]]: <code>BOOL</code> |
* Description: Whether there are asteroids or not. | * Description: Whether there are asteroids or not. | ||
* Example: | * Example: | ||
Line 90: | Line 90: | ||
====nebulae==== | ====nebulae==== | ||
− | * Type: BOOL | + | * [[#Variable_Types|Type]]: <code>BOOL</code> |
* Description: Whether there are nebulae or not. | * Description: Whether there are nebulae or not. | ||
* Example: | * Example: | ||
Line 98: | Line 98: | ||
====num_natural_phenomena==== | ====num_natural_phenomena==== | ||
− | * Type: INT | + | * [[#Variable_Types|Type]]: <code>INT</code> |
* Description: How many asteroids/nebulae/? there are in the system. | * Description: How many asteroids/nebulae/? there are in the system. | ||
* Example: | * Example: | ||
Line 106: | Line 106: | ||
====namelist==== | ====namelist==== | ||
− | * Type: FILENAME | + | * [[#Variable_Types|Type]]: <code>FILENAME</code> |
* Description: a file containing a list of planet names to use. | * Description: a file containing a list of planet names to use. | ||
* Example: | * Example: | ||
Line 114: | Line 114: | ||
====gasgiantlist==== | ====gasgiantlist==== | ||
− | * Type: FILENAME | + | * [[#Variable_Types|Type]]: <code>FILENAME</code> |
− | * Description: A list of possible textures for gas giants. If a "''" follows the filename, then it will have atmosphere. If a "^" and another filename follows the first filename then the next texture will be used for lights. | + | * Description: A list of possible textures for gas giants. If a "<code>''</code>" follows the filename, then it will have atmosphere. If a "<code>^</code>" and another filename follows the first filename then the next texture will be used for lights. |
* Example: | * Example: | ||
<pre> | <pre> | ||
Line 122: | Line 122: | ||
====planetlist==== | ====planetlist==== | ||
− | * Type: FILENAME | + | * [[#Variable_Types|Type]]: <code>FILENAME</code> |
* Description: A list of possible textures for non-gas-giant planets with the same rules as above. | * Description: A list of possible textures for non-gas-giant planets with the same rules as above. | ||
* Example: | * Example: | ||
Line 130: | Line 130: | ||
====moonlist==== | ====moonlist==== | ||
− | * Type: FILENAME | + | * [[#Variable_Types|Type]]: <code>FILENAME</code> |
* Description: A list of possible textures for moons with the same rules as above. | * Description: A list of possible textures for moons with the same rules as above. | ||
* Example: | * Example: | ||
Line 138: | Line 138: | ||
====ringlist==== | ====ringlist==== | ||
− | * Type: FILENAME | + | * [[#Variable_Types|Type]]: <code>FILENAME</code> |
* Description: A list of textures of planetary rings. | * Description: A list of textures of planetary rings. | ||
* Example: | * Example: | ||
Line 145: | Line 145: | ||
====asteroidlist==== | ====asteroidlist==== | ||
− | * Type: FILENAME | + | * [[#Variable_Types|Type]]: <code>FILENAME</code> |
* Description: A list of distances and units with the same format as unitlist. | * Description: A list of distances and units with the same format as unitlist. | ||
* Example: | * Example: | ||
Line 152: | Line 152: | ||
====nebulalist==== | ====nebulalist==== | ||
− | * Type: FILENAME | + | * [[#Variable_Types|Type]]: <code>FILENAME</code> |
* Description: A list of distances and units with the same format as unitlist. | * Description: A list of distances and units with the same format as unitlist. | ||
* Example: | * Example: | ||
Line 162: | Line 162: | ||
===General=== | ===General=== | ||
====data==== | ====data==== | ||
− | * Type: INT | + | * [[#Variable_Types|Type]]: <code>INT</code> |
* Description: The random number seed that is used to generate the system. This number ensures that the same system is generated each time. | * Description: The random number seed that is used to generate the system. This number ensures that the same system is generated each time. | ||
* Example: | * Example: | ||
Line 170: | Line 170: | ||
====compactness==== | ====compactness==== | ||
− | * Type: FLOAT | + | * [[#Variable_Types|Type]]: <code>FLOAT</code> |
* Description: The scale of the star system. | * Description: The scale of the star system. | ||
* Example: | * Example: | ||
Line 178: | Line 178: | ||
====faction==== | ====faction==== | ||
− | * Type: FACTION NAME | + | * [[#Variable_Types|Type]]: <code>FACTION NAME</code> |
− | * Description: The name of the faction that owns the system. | + | * Description: The name of the [[Factions|faction]] that owns the system. |
* Example: | * Example: | ||
<pre> | <pre> | ||
Line 186: | Line 186: | ||
====backgroundlist==== | ====backgroundlist==== | ||
− | * Type: FILENAME | + | * [[#Variable_Types|Type]]: <code>FILENAME</code> |
− | * Description: A list of background spheremaps/cubemaps without the extension (.png,.jpg,etc.). | + | * Description: A list of background spheremaps/cubemaps without the extension (<code>.png</code>, <code>.jpg</code>, etc... ). |
* Example: | * Example: | ||
<pre> | <pre> | ||
Line 194: | Line 194: | ||
====force==== | ====force==== | ||
− | * Type: BOOL | + | * [[#Variable_Types|Type]]: <code>BOOL</code> |
− | * Description: If this is not true, then the system will clamp to the corresponding value of the unknown_sector/minlimit or maxlimit "system__ | + | * Description: If this is not <code>true</code>, then the system will clamp to the corresponding value of the <code>unknown_sector/minlimit</code> or maxlimit "system__ {{Fixme}} ''What's meant here exactly ??'' |
* Example: | * Example: | ||
<pre> | <pre> | ||
Line 202: | Line 202: | ||
===Units=== | ===Units=== | ||
====num_starbases==== | ====num_starbases==== | ||
− | * Type: INT | + | * [[#Variable_Types|Type]]: <code>INT</code> |
* Description: how many bases there will be (may be changed around with dynamic universe) | * Description: how many bases there will be (may be changed around with dynamic universe) | ||
* Example: | * Example: | ||
Line 210: | Line 210: | ||
====unitlist==== | ====unitlist==== | ||
− | * Type: FILENAME | + | * [[#Variable_Types|Type]]: <code>FILENAME</code> |
* Description: A list of distances and units with the following format: | * Description: A list of distances and units with the following format: | ||
* Example: | * Example: | ||
Line 216: | Line 216: | ||
<var name="unitlist" value="smallunits.txt"/> | <var name="unitlist" value="smallunits.txt"/> | ||
</pre> | </pre> | ||
− | * Contents of smallunits.txt | + | * Contents of <code>smallunits.txt</code> |
− | ** Example: "U800^MiningBase U800^MiningBase A8480^AFieldBaseSparse&U400^MiningBase" | + | ** Example: <code>"U800^MiningBase U800^MiningBase A8480^AFieldBaseSparse&U400^MiningBase"</code> |
− | ** Format: "U"|"E"|"B"|"A"|"N"|"gas"|"jump"|"planet" distance-from-orbiting-planet "^" unit-name | + | ** Format: <code>"U"|"E"|"B"|"A"|"N"|"gas"|"jump"|"planet" distance-from-orbiting-planet "^" unit-name</code> |
− | *** Description | + | *** Description of the Format |
− | **** U = Unit | + | **** <code>U</code> = Unit |
− | **** N = Nebula | + | **** <code>N</code> = Nebula |
− | **** B = Building | + | **** <code>B</code> = Building |
− | **** E = Enhancement | + | **** <code>E</code> = Enhancement |
− | **** A = Asteroid. | + | **** <code>A</code> = Asteroid. |
− | ***You can have another object at the same coordinates by putting a "&" and another of these unit-distance pairs with no white space in between. | + | ***You can have another object at the same coordinates by putting a "<code>&</code>" and another of these unit-distance pairs with no white space in between. |
====num_jump==== | ====num_jump==== | ||
− | * Type: INT | + | * [[#Variable_Types|Type]]: <code>INT</code> |
* Description: The number of jump points to other systems there are. | * Description: The number of jump points to other systems there are. | ||
* Example: | * Example: | ||
Line 236: | Line 236: | ||
====jumps==== | ====jumps==== | ||
− | * Type: ?? | + | * [[#Variable_Types|Type]]: ?? {{Fixme}} |
− | * Type: INT | + | * [[#Variable_Types|Type]]: <code>INT</code> |
* Description: List of systems that this system jump points connect to. | * Description: List of systems that this system jump points connect to. | ||
* Example: | * Example: |
Revision as of 18:01, 8 April 2005
Edit Systems |
Contents
Autogenerated system files
Since they are autogenerated, these systems must have some rules so that the generator knows what to make. The rules are inside of the XML file universe/milky_way.xml.
XML Schema Description
-
<galaxy> ... </galaxy>
-- Marks the beginning and end of the XML file.-
<systems> ... </systems>
-- You need it but I don't know why.-
<sector ... > ... </sector>
-- (repeatable) A sector containg a group of systems.-
name
-- the name of the sector. For, enigma_sector. -
< var ... />
-- (repeatable) The default variables for the entire sector (var tag to be described later) -
<sector ... > ... </sector>
-- (repeatable) A system (to be a system it must be inside another sector tag).-
name
-- the name of the system, for example, heavens_gate. -
< var ... />
-- (repeatable) To be described later
-
-
-
-
Variables
The < var name="" value="" />
tag
Here is a list of all of the possible names and their values so far. If these variables are not set inside any of the sector tags (innermost overrides) the system will randomly use a number between the corresponding values of the unknown_sector/min and max "systems"
Variable Types
-
BOOL
= boolean value = "true
" or "false
" -
INT
= integer -
FLOAT
= decimal number -
FILENAME
= the name of a file inside the universe directory.
Sun / Stars
num_stars
- Type:
INT
- Description: The number of suns in the system (to make binary systems).
- Example:
<var name="num_stars" value="2"/>
sun_radius
- Type:
FLOAT
- Description: The radius of the sun in the system.
- Example:
<var name="sun_radius" value="26000"/>
starlist
- Type:
FILENAME
- Description: A file with a list of colors/textures/sprites for different sizes of stars:
- Example
<var name="starlist" value="stars.txt"/>
- Contents of Stars.txt
- "
0 .3 1 .3 .1 stars/white_star.png
" - "
1000 .5 .5 1 .1 stars/white_star.png
" - ... means, "if the radius of the star is greater than or equal to 0 but less than 1000, then use RGB color (.3,1,.3), variance (?) of .1 and a texture/sprite filename of "
stars/white_star.png
". The same goes for 1000, etc.
- "
Planets
num_gas_giants
- Type:
INT
- Description: The number of gas giant planets.
- Example:
<var name="num_gas_giants" value="3"/>
num_planets
- Type:
INT
- Description: The total number of inhabited(?) planets (not including gas giants).
- Example:
<var name="num_planets" value="8"/>
num_moons
- Type:
INT
- Description: The number of moons orbiting any planet.
- Example:
<var name="num_moons" value="2"/>
asteroids
- Type:
BOOL
- Description: Whether there are asteroids or not.
- Example:
<var name="asteroids" value="true"/>
nebulae
- Type:
BOOL
- Description: Whether there are nebulae or not.
- Example:
<var name="nebulae" value="true"/>
num_natural_phenomena
- Type:
INT
- Description: How many asteroids/nebulae/? there are in the system.
- Example:
<var name="num_natural_phenomena" value="2"/>
namelist
- Type:
FILENAME
- Description: a file containing a list of planet names to use.
- Example:
<var name="planetlist" value="planets.txt"/>
gasgiantlist
- Type:
FILENAME
- Description: A list of possible textures for gas giants. If a "
" follows the filename, then it will have atmosphere. If a "
^
" and another filename follows the first filename then the next texture will be used for lights. - Example:
<var name="gasgiantlist" value="gas_giants.txt"/>
planetlist
- Type:
FILENAME
- Description: A list of possible textures for non-gas-giant planets with the same rules as above.
- Example:
<var name="planetlist" value="planets.aera.txt"/>
moonlist
- Type:
FILENAME
- Description: A list of possible textures for moons with the same rules as above.
- Example:
<var name="moonlist" value="moons.txt"/>
ringlist
- Type:
FILENAME
- Description: A list of textures of planetary rings.
- Example:
asteroidlist
- Type:
FILENAME
- Description: A list of distances and units with the same format as unitlist.
- Example:
nebulalist
- Type:
FILENAME
- Description: A list of distances and units with the same format as unitlist.
- Example:
<var name="asteroidlist" value="asteroids.txt"/>
General
data
- Type:
INT
- Description: The random number seed that is used to generate the system. This number ensures that the same system is generated each time.
- Example:
<var name="data" value="1039"/>
compactness
- Type:
FLOAT
- Description: The scale of the star system.
- Example:
<var name="compactness" value="5.8"/>
faction
<var name="faction" value="aera"/>
backgroundlist
- Type:
FILENAME
- Description: A list of background spheremaps/cubemaps without the extension (
.png
,.jpg
, etc... ). - Example:
<var name="backgroundlist" value="background.txt"/>
force
- Type:
BOOL
- Description: If this is not
true
, then the system will clamp to the corresponding value of theunknown_sector/minlimit
or maxlimit "system__ FIXME What's meant here exactly ?? - Example:
Units
num_starbases
- Type:
INT
- Description: how many bases there will be (may be changed around with dynamic universe)
- Example:
<var name="num_starbases" value="0"/>
unitlist
- Type:
FILENAME
- Description: A list of distances and units with the following format:
- Example:
<var name="unitlist" value="smallunits.txt"/>
- Contents of
smallunits.txt
- Example:
"U800^MiningBase U800^MiningBase A8480^AFieldBaseSparse&U400^MiningBase"
- Format:
"U"|"E"|"B"|"A"|"N"|"gas"|"jump"|"planet" distance-from-orbiting-planet "^" unit-name
- Description of the Format
-
U
= Unit -
N
= Nebula -
B
= Building -
E
= Enhancement -
A
= Asteroid.
-
- You can have another object at the same coordinates by putting a "
&
" and another of these unit-distance pairs with no white space in between.
- Description of the Format
- Example:
num_jump
- Type:
INT
- Description: The number of jump points to other systems there are.
- Example:
<var name="num_jump" value="4"/>
jumps
- Type: ?? FIXME
- Type:
INT
- Description: List of systems that this system jump points connect to.
- Example:
<var name="jumps" value="enigma_sector/harrison enigma_sector/repleetah enigma_sector/mccaffrey enigma_sector/wetland"/>
Examples
(parts of milky_way.xml)
<galaxy> <systems> ... ... <sector name="enigma_sector"> <var name="faction" value="confed"/> <var name="namelist" value="names.txt"/> ... ... <sector name="shelton"> <var name="sun_radius" value="26000"/> <var name="faction" value="aera"/> <var name="planetlist" value="planets.aera.txt"/> <var name="compactness" value="5.8"/> <var name="num_stars" value="1"/> <var name="num_gas_giants" value="3"/> <var name="num_planets" value="8"/> <var name="num_moons" value="2"/> <var name="nebulae" value="true"/> <var name="asteroids" value="true"/> <var name="jumps" value="enigma_sector/harrison enigma_sector/repleetah enigma_sector/mccaffrey enigma_sector/wetland"/> <var name="num_natural_phenomena" value="2"/> <var name="num_starbases" value="0"/> <var name="data" value="1039"/> </sector> ... ... </sector> ... ... </systems> </galaxy>