Jump to content

Recommended Posts

Posted

I am interested in creating a LUA script that can add or delete Dialog Groups and Properties whilst i am using the properties window in the editor. Is there a way in lua script to access the grid variable from other class functions like the SetKey(key,value) function to add or delete properties based on other properties? Or does anyone have any idea how i could accomplish this?

Posted

are you asking about adding or deleting groups/properties that are already in the script and you just decide whether or not they are used or shown in properties dialog? or are you asking what i think you are asking: have a dialog property that gives you the ability to add a brand new property? seems like that would be very chicken-egg type of thing... seems easier just to add or delete whatever from the actual script itself...

Win7 64bit / Intel i7-2600 CPU @ 3.9 GHz / 16 GB DDR3 / NVIDIA GeForce GTX 590

LE / 3DWS / BMX / Hexagon

macklebee's channel

Posted

Yeah i want to add and delete properties, at the moment my object has to many properties so i want to get rid of properties that are not used, and for each instance of the model i only use a select few.

Posted

you might have better luck if you just write a basic script (or ask someone to do it for you) that contains the common properties that you use... how bout you list the common things you only want in your properties dialog...

Win7 64bit / Intel i7-2600 CPU @ 3.9 GHz / 16 GB DDR3 / NVIDIA GeForce GTX 590

LE / 3DWS / BMX / Hexagon

macklebee's channel

Posted

i think i may have confused you, i want to be able to add and delete properties using scripts, that contextually adds properties with other properties the user has selected, for instance a level designer could make an object and then choose an option form a PROPERTY_CHOICE and depending on what the user selects more options appear.

Posted

I don't think it would be possible based on my experiences of trying to update dialogue box scripts under "normal" circumstances. If you hit <CTRL>-<S> to save your script, it doesn't take effect in the editor. You have to take the file/save option from the menu. Based on this, I would assume there is something behind this that "activates" the new version of the script, and so you couldn't dynamically code new options.

All the best,

Steve Vink

Posted

Combining lua menu's is not really easy (if it is even possible). Lets say you select something in one lua menu and you want to affect another lua menu by that choice, well thats pretty difficult. Not many people have experience with this.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...