Jump to content

Recommended Posts

Posted

I'm asking the opinion of the expert modders.

From what I've understood AddFormToFormList function "adds the new form at the 0th index, adding 1 to the indices of the other list entries" - GECK description.

Say, if I have a List1 with items A B and C in it and I want to add List2 with D E and F via AddFormToFormList, the new List1 will be F E D A B C with F E and D being invisible in the editor, while ListAddForm will make the new List1 look like A B C D E F with D E and F being invisible in the editor.

The big question for me is, say, what will happen if I create a mod which combines List1 (A B C) with List2 (D E F) via AddFormToFormList then I re-write the same script with ListAddForm instead and reactivate the mod? How the new List1 will look like?

Thank you.

Posted (edited)

 

Say, if I have a List1 with items A B and C in it and I want to add List2 with D E and F via AddFormToFormList, the new List1 will be F E D A B C with F E and D being invisible in the editor, while ListAddForm will make the new List1 look like A B C D E F with D E and F being invisible in the editor.

 

I would think scenario 1 would look like this ... List 1( 0:list2 (D E F) 1:A 2:B 3:C ) Unless you are saying that you have seen the indices of List2 get reversed while getting an item out of the 0 indice (list2) of List 1

 

The big question for me is, say, what will happen if I create a mod which combines List1 (A B C) with List2 (D E F) via AddFormToFormList then I re-write the same script with ListAddForm instead and reactivate the mod? How the new List1 will look like?

Thank you.

 

Should look like this I think ... List1( 0:A 1:B 2:C 3:list2(D E F) ) with list2 also having 0,1,2 on the indices

 

I would think by the explanation on "ListAddForm" that you could only use references , therefore not able to add lists to lists with it ... except for the existence of "ListAddReference" which would make 1 of them redundant.

 

Hope that helped since I'm only a rookie myself.

Edited by Mktavish
Posted (edited)

Thank you for your reply.

The big problem with ListAddForm it is that is only temporary, for in-game save only - found that by trial and error plus I got some explanations from an expert modder. Once you have exit your game, it will not fire again unless you update your lists again. Which bothered my very much when I created a replica of Jury Rigging perk from NV - to get the perk working I had to update FormIdRepairLists with more than 1800 entries (!) EACH time when I reloaded my game. So, I gave up using it and I used the classic AddFormToFormList instead. There is a trade-off in using it though, AddFormToFormList gets your lists baked - they stay modified even if you uninstall the mod - not a big problem if they are modified only with vanilla items. It will not affect new playthroughs or the game saves made before activating the perk/quest etc. even if the mod was installed.

As for the order in lists, I have noticed that when you reload your game, the newly introduced items get sorted somehow - in alphabetical order - it could be only an impression.

Edited by zozoramelu
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...