FutureWML
From Wesnoth
The Developers would like to see these features added to WML, but they haven't been coded or the idea hasn't been fully developed yet. For a list of current WML, see the ReferenceWML page.
Contents |
Ideas that are fairly sound
New Actions
- [harm_unit] - harms a unit(s) then saves the amount as $harm_amount
- [filter]
- amount
- damage_type
- alignment
- [allow_undo] {contents} - perform {contents} when move is undone
- [end_turn] - ends the current side turn
- [chat] - sends a message to MP chat
- message
New Events
- [event] name="move" - triggers when unit moves over a hex
may interrupt movement unless [allow_undo] ?
Game Information
- [query_location] - queries a location from the user
- variable
- [filter_location]
Regarding [query_location]: this could use a better name. Suggestions are welcome --Sapient
- [find_path] - finds the shortest path from a unit to a location
- DISCUSSION: here
- [traveler] - SUF
- [destination] - SLF
- variable (default "path")
- allow_multiple_turns (default "no")
- ignore_ambush (default "no")
- $side_info - auto-stored side information
- $game_info - auto-stored game information
- $map_info - auto-stored map information
Advanced Manipulation
- [set_function] - creates a new tag for direct action WML
Ideas that need major revision
- [set_function] extensions
- information stored in $functions.function_name
- active - if the function will be evaluated when a tag with its name is found, will be stored information stored in $functions.function_name.active
- information stored in $functions.function_name.default_params
- information stored in $functions.function_name.do/command
- [unknown_action_name] - if an unknown action is found, the engine will look for $functions.unknown_action_name.active, if true it will evaluate the function here
- all tags and attributes will be stored in $param.item_name
- not implemented yet: instead of using $functions.function_name directly, it will be copied into $current_function - if you specify mulitple [command] tags, they will be evaluated one by one, and by e.g. calling $current_function.command[1] in the first command, you can modify the next command(needed for inserting tags, maybe there's a better way?)
Regarding [set_function] extensions and [unknown_action_name]: this is just a restatement of set_function with some extra variable manipulations going on. Defining such an implementation at this point seems a bit restrictive and premature with regard to the actual needs. I'd rather take this one step at a time. Get set_function working without this harness and then see what the WML author is missing from their toolset. My belief is that these additional variable manipulations aren't needed and would just complicate an otherwise simple idea. --Sapient
