Difference between revisions of "UsefulWMLFragments"
Prometheus (talk | contribs) m (→Useful WML Fragments) |
Prometheus (talk | contribs) (→Useful WML Fragments) |
||
Line 9: | Line 9: | ||
[[MoveExistingUnit]]: Move a unit from one place to another, displaying its movement. Move Unit 1. Move Unit 2. Move Unit 3. | [[MoveExistingUnit]]: Move a unit from one place to another, displaying its movement. Move Unit 1. Move Unit 2. Move Unit 3. | ||
− | [[WML Utilities]]: Macros to assist other macros. | + | [[WML Utilities]]: Macros to assist other macros. Test Value of Variable. Store Unit Attribute. Filter by Terrain. Iterate. Overlay with Filter. Determine Opposite Coordinates. |
[[ProgrammingMacros]]: Definitions for some low-level macros to make it easier to write program-like WML. | [[ProgrammingMacros]]: Definitions for some low-level macros to make it easier to write program-like WML. | ||
− | |||
− | |||
[[Victory Conditions]]: Number of Villages, Amount of Gold. Suitable for multiplayer scenarios. | [[Victory Conditions]]: Number of Villages, Amount of Gold. Suitable for multiplayer scenarios. | ||
Line 20: | Line 18: | ||
[[WML Buildings]]: Generic Buildings, Light House/Dark Tower, Wishing Well #1, Wishing Well #2. | [[WML Buildings]]: Generic Buildings, Light House/Dark Tower, Wishing Well #1, Wishing Well #2. | ||
+ | |||
+ | [[RandomTraitUnit]]: Create a unit with two random traits. | ||
[[DroppableItem]]: Generic item that a unit can carry, and is left on the ground when the unit dies. | [[DroppableItem]]: Generic item that a unit can carry, and is left on the ground when the unit dies. |
Revision as of 01:47, 15 August 2006
Useful WML Fragments
Most of the things found here are macros (see PreprocessorRef) that must be copied into a scenario file or another file included first by the campaign, and then used in the scenario (or multiplayer map). Remember that a macro cannot be used at a point before it is defined.
WML Templates: Generic campaign, scenario and unit templates.
WML Scenario Tools: Macros directly useful in a scenario. Modify unit. Return Unit to Recall List. Trap Unit. Change Keep Terrain. Hero die message. Item effect.
MoveExistingUnit: Move a unit from one place to another, displaying its movement. Move Unit 1. Move Unit 2. Move Unit 3.
WML Utilities: Macros to assist other macros. Test Value of Variable. Store Unit Attribute. Filter by Terrain. Iterate. Overlay with Filter. Determine Opposite Coordinates.
ProgrammingMacros: Definitions for some low-level macros to make it easier to write program-like WML.
Victory Conditions: Number of Villages, Amount of Gold. Suitable for multiplayer scenarios.
WML Abilities: Knockback. Charm. Bloodlust. Abilities cannot currently be incorporated in the unit type definitions themselves, but must be included in the scenario file.
WML Buildings: Generic Buildings, Light House/Dark Tower, Wishing Well #1, Wishing Well #2.
RandomTraitUnit: Create a unit with two random traits.
DroppableItem: Generic item that a unit can carry, and is left on the ground when the unit dies.
A Shop Like Thing: How to add even more RPG elements to your scenarios.
PseudoRandom: A replacement for {RANDOM} in multiplayer, where {RANDOM} is buggy.
Rain effect: Creating an overlay of rain in a scenario.
Advanced WML: Branch on Village Type. Recruit from a Ship. Point Rotation Scheme.