PDA

View Full Version : Can you use windowlist for a static list?



celestian
March 23rd, 2017, 00:28
I'm making some tweaks to the ruleset and I was just about to start a mass of copy paste when I thought... surely I can do this with windowlist.

I am setting up a pop/details window to allow players to modifier their stats. Base/Modifier and Temp Modifier (also adding fields to be used later for items/effects to set stat or adjust it).... I've got the functions setup to setup watches/etc based on the <target>intelligence</target> and it's working fine. However instead of having a entry for each I figured I could use a windowlist... but I can't seem to figure out if windowlist can be fed just a static list of items like this.

Short version, I'd like to have a windowlist that runs on "strength|dexterity|constitution|intelligence|wisdo m|charisma" so that for each item it's created list of names/numbers pulled from the templates/lua code.

Something like this:
https://i.imgur.com/MAfHY6A.png


Is it possible or do I just need to do it the old fashion way?

Moon Wizard
March 23rd, 2017, 00:34
You would have to use a sourceless windowlist, and use createWindow with the correct window class and data path for each ability.

You can do it, but I found that shoehorning this type of data into a windowlist, instead of copy/paste the specific fields, usually isn't worth the gyrations to do it that way. Plus it involves a lot more Lua script, instead of letting the FG engine handle automatically through the XML definitions.

But, yes, I've had the same thought before...

Cheers,
JPG

celestian
March 23rd, 2017, 01:23
You would have to use a sourceless windowlist, and use createWindow with the correct window class and data path for each ability.

You can do it, but I found that shoehorning this type of data into a windowlist, instead of copy/paste the specific fields, usually isn't worth the gyrations to do it that way. Plus it involves a lot more Lua script, instead of letting the FG engine handle automatically through the XML definitions.

But, yes, I've had the same thought before...

Cheers,
JPG

Thanks for the advice. I'll take it!