Follow-up Comment #4, bug #22774 (project wesnoth):
Changing the implementation of [insert_tag] is unlikeley since it will cause
incompabilities while the gain isn't that big.
Also note, that [insert_tag] is not a part of action wml but rather a part of
wml substitution. This means is doesn't only work inside [event], it should
also work whenever we allow variable substitution.
That also why the current behaviour is stronggly connected to the varibale
substitution implementation so changing it it quite difficult.
What you can very easiliy do is writing your own tag in lua for example call
it [do_tag] that works in the way you desciribe, but can only be used inside
an event like other actionwml tags.
like this:
local helper = wesnoth.require "lua/helper.lua"
function wesnoth.wml_actions.do_tag(cfg)
local name = cfg.name or helper.wml_error "[do_tag] expects an name=
attribute."
local varname = cfg.variable or helper.wml_error "[do_tag] expects an
variable= attribute."
local vartable = helper.get_variable_array(varname)
for k,v in ipairs(vartable) do
wesnoth.wml_actions[name](v)
end
end
_______________________________________________________
Reply to this item at:
<http://gna.org/bugs/?22774>
_______________________________________________
Nachricht gesendet von/durch Gna!
http://gna.org/
_______________________________________________
Wesnoth-bugs mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-bugs