Difference between revisions of "Info.xml"
From Serious Sam's Bogus Detour
Line 8: | Line 8: | ||
* <code>saving</code> The save mode to use. Either <code>none</code> where there are no saves at all, <code>current</code> where the current level is saved, or <code>all</code> which is like Hammerwatch, where you can go back to older levels without their progress getting reset. (Default: <code>current</code>) | * <code>saving</code> The save mode to use. Either <code>none</code> where there are no saves at all, <code>current</code> where the current level is saved, or <code>all</code> which is like Hammerwatch, where you can go back to older levels without their progress getting reset. (Default: <code>current</code>) | ||
* <code>players</code> <code>min="X" max="X"</code> The amount of players allowed to play in multiplayer. (Default: unlimited) | * <code>players</code> <code>min="X" max="X"</code> The amount of players allowed to play in multiplayer. (Default: unlimited) | ||
− | * <code>modifiers</code> | + | * <code>modifiers</code> A collection of switches for the scenario. |
− | ** <code>modifier</code> <code>forced="X" id="X" name="X" tooltip="X" locked-by="X" default-on="X" radio="X" multiplayer="X"</code> | + | ** <code>modifier</code> <code>forced="X" id="X" name="X" tooltip="X" locked-by="X" default-on="X" radio="X" multiplayer="X"</code> A modifier. |
− | ** <code>separator</code> <code>multiplayer="X"</code> | + | *** The <code>id</code> attribute is the modifier ID. When the switch is turned on, in content, a preprocessor define called <code>MOD_ID</code> is defined. For more information, see [[Preprocessor]]. |
− | ** <code>header</code> <code>text="X" tooltip="X" multiplayer="X"</code> | + | *** The <code>name</code> attribute is the visible display name for the switch. It is displayed in the switches menu. |
− | * <code>start</code> | + | *** The <code>tooltip</code> attribute defines the text for an additional tooltip that should show when hovering over the switch in the switches menu. (Default: none) |
− | ** <code>level</code> <code>name="X" lvl="X"</code> | + | *** The <code>locked-by</code> attribute defines which switches disable this one, separate by commas. (Default: none) |
+ | *** The <code>default-on</code> attribute sets this switch to be on by default. This value is either <code>true</code> or <code>false</code>. (Default: <code>false</code>) | ||
+ | *** The <code>radio</code> attribute sets whether this switch is part of a group. Setting this value together with multiple switches turns them into a "radiobox" instead of a checkbox, where only 1 switch of a group can be selected at a time. (Default: none) | ||
+ | *** The <code>forced</code> attribute defines whether this switch is always defined, and isn't listed in the switches menu. This value is either <code>true</code> or <code>false</code>. If you set this to true, the only other attribute you need to set is <code>id</code>. (Default: <code>false</code>) | ||
+ | *** The <code>multiplayer</code> attribute defines whether this switch is only available in multiplayer. This value is either <code>true</code> or <code>false</code>. (Default: <code>false</code>) | ||
+ | ** <code>separator</code> <code>multiplayer="X"</code> A separator line for the switch menu. The <code>multiplayer</code> attribute is the same as for the <code>modifier</code> tag. | ||
+ | ** <code>header</code> <code>text="X" tooltip="X" multiplayer="X"</code> A header text for the switch menu. The <code>multiplayer</code> attribute is the same as for the <code>modifier</code> tag. | ||
+ | * <code>start</code> A collection of levels that the player will be able to start from. | ||
+ | ** <code>level</code> <code>name="X" lvl="X"</code> A level that the player will be able to start from. The <code>name</code> attribute is the name displayed in the list of levels, and the <code>lvl</code> attribute is the filename to the level. | ||
* <code>classmaps</code> | * <code>classmaps</code> | ||
** <code>behavior</code> <code>from="X" to="X"</code> | ** <code>behavior</code> <code>from="X" to="X"</code> |
Revision as of 17:03, 20 June 2017
This XML file describes a scenario. All tags listed below must be within an <info></info>
block.
Tags
-
name
The name of the scenario that will show up in the scenario list. -
description
The full description of the scenario that will show up when selecting the scenario in the scenario list. -
tag
A short tagline description of the scenario, which is shown above the description. -
multiplayer
Whether the scenario is multiplayer-only or not. Eithertrue
orfalse
. (Default:false
) -
saving
The save mode to use. Eithernone
where there are no saves at all,current
where the current level is saved, orall
which is like Hammerwatch, where you can go back to older levels without their progress getting reset. (Default:current
) -
players
min="X" max="X"
The amount of players allowed to play in multiplayer. (Default: unlimited) -
modifiers
A collection of switches for the scenario.-
modifier
forced="X" id="X" name="X" tooltip="X" locked-by="X" default-on="X" radio="X" multiplayer="X"
A modifier.- The
id
attribute is the modifier ID. When the switch is turned on, in content, a preprocessor define calledMOD_ID
is defined. For more information, see Preprocessor. - The
name
attribute is the visible display name for the switch. It is displayed in the switches menu. - The
tooltip
attribute defines the text for an additional tooltip that should show when hovering over the switch in the switches menu. (Default: none) - The
locked-by
attribute defines which switches disable this one, separate by commas. (Default: none) - The
default-on
attribute sets this switch to be on by default. This value is eithertrue
orfalse
. (Default:false
) - The
radio
attribute sets whether this switch is part of a group. Setting this value together with multiple switches turns them into a "radiobox" instead of a checkbox, where only 1 switch of a group can be selected at a time. (Default: none) - The
forced
attribute defines whether this switch is always defined, and isn't listed in the switches menu. This value is eithertrue
orfalse
. If you set this to true, the only other attribute you need to set isid
. (Default:false
) - The
multiplayer
attribute defines whether this switch is only available in multiplayer. This value is eithertrue
orfalse
. (Default:false
)
- The
-
separator
multiplayer="X"
A separator line for the switch menu. Themultiplayer
attribute is the same as for themodifier
tag. -
header
text="X" tooltip="X" multiplayer="X"
A header text for the switch menu. Themultiplayer
attribute is the same as for themodifier
tag.
-
-
start
A collection of levels that the player will be able to start from.-
level
name="X" lvl="X"
A level that the player will be able to start from. Thename
attribute is the name displayed in the list of levels, and thelvl
attribute is the filename to the level.
-
-
classmaps
-
behavior
from="X" to="X"
-
script
from="X" to="X"
-
gamemode
from="X" to="X"
-
-
disable-include
-
includes
-
include
modifiers="X" levels="X" classmaps="X" final="X"
-
Example
Below is the info.xml file for the Payload gamemode on the Workshop:
<info> <name>Payload</name> <description>Bring the payload to the other side.</description> <multiplayer>true</multiplayer> <players min="2" max="12" /> <start> <level name="Over the Mountain" lvl="levels/payload01.lvl" /> <level name="That belongs in a Museum" lvl="levels/payload02.lvl" /> </start> <modifiers> <modifier forced="true" id="VERSUS" /> <modifier forced="true" id="PICKUP_RESPAWN" /> </modifiers> </info>