Jump to content

Category:WML

From Rosetta Code
Revision as of 19:42, 25 November 2011 by rosettacode>Kernigh (I searched for "Wesnoth" and found nothing. This page introduces Rosetta Code to Wesnoth Markup Language.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Language
WML
This programming language may be used to instruct a computer to perform a task.
Official website
Lang tag(s): wml


Listed below are all of the tasks on Rosetta Code which have been solved using WML.

Wesnoth Markup Language or WML is the configuration format for its computer game, the Battle for Wesnoth. WML files are plain text and consist of tags; and tags can contain key-value pairs and nested tags. WML describes parts of the game, such as units (like Elvish Fighters and Orcish Grunts) that do battle, and scenarios where armies must fight.

ActionWML responds to events during a scenario. ActionWML qualifies WML as a scripting language. The actions include modifying units, displaying message boxes, accessing variables, using [if] and [while] control structures, and so on.

WML also includes a few sub-languages:

  • WML Preprocessor allows macros in WML files. Macros are good for brevity, because a one-line macro might expand to a multi-line tag. Wesnoth also has many predefined macros.
  • FormulaAI is a pure functional language. Its purpose is to customize AI of armies under computer control, but it can also do arithmetic and define functions.
  • LuaWML embeds Lua inside WML. This is also the only way to define a custom WML tag.

Subcategories

This category has the following 3 subcategories, out of 3 total.

Cookies help us deliver our services. By using our services, you agree to our use of cookies.