enclave's Lua thread

Discussion of Lua and LuaWML support, development, and ideas.

Moderators: Forum Moderators, Developers

Post Reply
gfgtdf
Developer
Posts: 1184
Joined: February 10th, 2013, 2:25 pm

Re: enclave's Lua thread

Post by gfgtdf » February 19th, 2019, 7:09 pm

Instead of using register_wml_action, you just define a function in the wesnoth.wml_actions table.
Scenario with Robots SP scenario (1.11/1.12), allows you to build your units with components, PYR No preperation turn 1.12 mp-mod that allows you to select your units immideately after the game begins.

User avatar
josteph
Developer
Posts: 729
Joined: August 19th, 2017, 6:58 pm

Re: enclave's Lua thread

Post by josteph » February 19th, 2019, 8:24 pm

By the way, in 1.12.6 register_wml_action had a compatibility wrapper available:

https://github.com/wesnoth/wesnoth/blob ... ua#L32-L37

which is consistent with the deprecation policy:

https://wiki.wesnoth.org/CompatibilityS ... d_features

So, an easy workaround here is to copy that wrapper into the addon.

Post Reply