Editing userdata

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

Moderators: Forum Moderators, Developers

Editing userdata

Postby Smok » May 11th, 2017, 12:26 pm

I want to delete some attributes from wml tag config object aka vconfig aka userdata aka WML object, but it is protected from editing. I tried to make table copy of it using ipairs(), but this way i only get subtags and i can't get attibutes.
Smok
 
Posts: 49
Joined: June 14th, 2016, 11:52 am

Re: Editing userdata

Postby gfgtdf » May 11th, 2017, 2:10 pm

you can use the helper.parsed ot helper.literal functions to copy a vconfig intoa regular config lua 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.
gfgtdf
Developer
 
Posts: 910
Joined: February 10th, 2013, 2:25 pm

Re: Editing userdata

Postby Smok » May 12th, 2017, 12:45 pm

Tried this today. Works perfectly, thanks. I'm a big step further in creation of the most complex wml tag ever. ;)
Smok
 
Posts: 49
Joined: June 14th, 2016, 11:52 am


Return to Lua Labs

Who is online

Users browsing this forum: No registered users and 1 guest