ReplayWML: Difference between revisions
From The Battle for Wesnoth Wiki
No edit summary |
|||
| Line 4: | Line 4: | ||
The following tags are recognized: | The following tags are recognized: | ||
* '''[move]''' the player moved a unit | * '''[start]''' is used to initialize the replay so that generated random numbers can be saved. | ||
** '''[source]''' the location the unit moved to | * '''[move]''' the player moved a unit. | ||
** '''[destination]''' the location the unit moved from | ** '''[source]''' the location the unit moved to. | ||
* '''[recruit]''' the player recruited a unit | ** '''[destination]''' the location the unit moved from. | ||
** ''value'' the index number of the recruited unit (Index numbers start at 0 and include all recruitable units in | * '''[recruit]''' the player recruited a unit. | ||
alphabetical order) | ** ''value'' the index number of the recruited unit. (Index numbers start at 0 and include all recruitable units in alphabetical order.) | ||
** ''x//,//y'' the castle tile the unit is recruited on | ** ''x//,//y'' the castle tile the unit is recruited on. | ||
* '''[recall]''' the player recalled a unit. | * '''[recall]''' the player recalled a unit. Same keys as [recruit], except that the index is in order of level, followed by required XP to advance. | ||
Same keys as [recruit], except that the index is in order of level, followed by required XP to advance. | * '''[attack]''' the player attacked. | ||
* '''[attack]''' the player attacked | ** ''weapon'' the index number of the weapon. Weapons are indexed by the unit designer. | ||
** ''weapon'' the index number of the weapon. Weapons are indexed by the unit designer | ** '''[source]''' the location of the attacking unit. | ||
** '''[source]''' the location of the attacking unit | ** '''[destination]''' the location of the defending unit. | ||
** '''[destination]''' the location of the defending unit | |||
* '''[end_turn]''' the player ended his turn. | * '''[end_turn]''' the player ended his turn. | ||
* '''[choose]''' the player was given an option by the scenario | * '''[choose]''' the player was given an option by the scenario. | ||
** ''value'' the index number of the option chosen. | ** ''value'' the index number of the option chosen. Index numbers are given by the scenario designer. | ||
Index numbers are given by the scenario designer | * '''[break]''' is used to break up deep nesting of generated random numbers. | ||
* '''[random]''' if the action required a random number, this describes the random number that was generated | * '''[random]''' if the action required a random number, this describes the random number that was generated. | ||
** ''value'' the value of the number | ** ''value'' the value of the number. | ||
** '''[results]''' used for [attack] commands. | ** '''[results]''' used for [attack] commands. Describes the results of the battle. | ||
Describes the results of the battle | *** ''chance'' the percent chance that the attack had to hit. | ||
** * ''chance'' the percent chance that the attack had to hit | *** ''damage'' the amount of damage that the attack would do if it hits. | ||
** * ''damage'' the amount of damage that the attack would do if it hits | *** ''dies'' whether the defender dies from the hit. | ||
** * ''dies'' whether the defender dies from the hit | *** ''hits'' whether the attack hits. | ||
** * ''hits'' whether the attack hits | ** '''[random]''' more than one number is generated. '''[random]''' has the same format as the first '''[random]''' and describes the other numbers that were generated. | ||
** '''[random]''' more than one number is generated. | |||
[random] has the same format as the first [random] and describes the other numbers that were generated | |||
== See Also == | == See Also == | ||
* [[SavefileWML]] | * [[SavefileWML]] | ||
* [[ReferenceWML]] | * [[ReferenceWML]] | ||
Revision as of 21:42, 12 November 2005
the [command] tag
The [command] tag is used to specify an action in a replay.
The following tags are recognized:
- [start] is used to initialize the replay so that generated random numbers can be saved.
- [move] the player moved a unit.
- [source] the location the unit moved to.
- [destination] the location the unit moved from.
- [recruit] the player recruited a unit.
- value the index number of the recruited unit. (Index numbers start at 0 and include all recruitable units in alphabetical order.)
- x//,//y the castle tile the unit is recruited on.
- [recall] the player recalled a unit. Same keys as [recruit], except that the index is in order of level, followed by required XP to advance.
- [attack] the player attacked.
- weapon the index number of the weapon. Weapons are indexed by the unit designer.
- [source] the location of the attacking unit.
- [destination] the location of the defending unit.
- [end_turn] the player ended his turn.
- [choose] the player was given an option by the scenario.
- value the index number of the option chosen. Index numbers are given by the scenario designer.
- [break] is used to break up deep nesting of generated random numbers.
- [random] if the action required a random number, this describes the random number that was generated.
- value the value of the number.
- [results] used for [attack] commands. Describes the results of the battle.
- chance the percent chance that the attack had to hit.
- damage the amount of damage that the attack would do if it hits.
- dies whether the defender dies from the hit.
- hits whether the attack hits.
- [random] more than one number is generated. [random] has the same format as the first [random] and describes the other numbers that were generated.
See Also
This page was last edited on 12 November 2005, at 21:42.