dizietemblesssma Posted August 30, 2020 Share Posted August 30, 2020 Before I go insane, can someone confirm or deny my suspicion that I can't add to a formlist in a script, if that formlist is defined but not added as a property in the CK? I have about 60 formlists in 6 arrays and i wish to script filling them, but I can only get this to work so far if I create an empty formlist and set that as a property in the CK, and set the array element equal to that property in the script. Unless there is something I am missing this means 60 formlists as properties in the script and 60 corresponding empty formlists in the CK. I've tried AddForm(), SKSE AddForms(), even powerofthrees' AddAllItemsToList() from Papyrus Extender. Am I doomed to the long road? diziet Link to comment Share on other sites More sharing options...
IsharaMeradin Posted August 30, 2020 Share Posted August 30, 2020 Unlike Arrays, Formlists cannot simply exist in memory. You need to have the empty record in the plugin and have it referenced as a property on at least one object that retains persistence for the duration that the formlist is needed. Consider whether you need a formlist or if an array will work instead. Link to comment Share on other sites More sharing options...
dizietemblesssma Posted August 31, 2020 Author Share Posted August 31, 2020 Unlike Arrays, Formlists cannot simply exist in memory. You need to have the empty record in the plugin and have it referenced as a property on at least one object that retains persistence for the duration that the formlist is needed. Consider whether you need a formlist or if an array will work instead.Well, that's clear, at least I can stop trying the impossible now. Thankyou. As for arrays, these are formlists in arrays:)Can one have a formlist of arrays?If forced to have 60/70 formlists declared as properties then I might ust as well have 60 odd arrays declared seperately in the script instead. diziet Link to comment Share on other sites More sharing options...
IsharaMeradin Posted September 1, 2020 Share Posted September 1, 2020 You cannot have a formlist of arrays. If your lists do not need to contain multiple object types and are not needed beyond the current script, an array would work fine. I am curious as to why you need that many lists to begin with. Link to comment Share on other sites More sharing options...
maxarturo Posted September 1, 2020 Share Posted September 1, 2020 Like IsharaMeradin, i'm also curious...... ???....?? Link to comment Share on other sites More sharing options...
Evangela Posted September 2, 2020 Share Posted September 2, 2020 You can have nested formlists though, but you can't access the other lower ones with HasForm() because limitations. Keep in mind, formlists are much slower than arrays so be mindful of how many you want to work with. Link to comment Share on other sites More sharing options...
dizietemblesssma Posted September 3, 2020 Author Share Posted September 3, 2020 You cannot have a formlist of arrays. If your lists do not need to contain multiple object types and are not needed beyond the current script, an array would work fine. I am curious as to why you need that many lists to begin with.10 MCM pages (one NPC each), 6/7 lists per page, 60/70 lists:) I was using arrays to construct the entries in the MCM config, which meant using formlists to hold the lists. Each array was declared as a property so another script could access the stored formlists.I was thinking that the fewer things that were properties in the script, the better for savefile bloat. diziet Link to comment Share on other sites More sharing options...
Recommended Posts