didisaan Posted November 3, 2017 Share Posted November 3, 2017 Hi I am wondering if it is possible to make a script, that goes through a mod file and lists all weapons in it in an array? Yes, I have locked at the documentation for geck/nvse scripts. Link to comment Share on other sites More sharing options...
DoctaSax Posted November 4, 2017 Share Posted November 4, 2017 Use a combination of GetModIndex and GetLoadedTypeArray with type code 40 array_var aWeapons int iIndex let iIndex := GetModIndex "TheMod.esp" let aWeapons := GetLoadedTypeArray 40, iIndex Link to comment Share on other sites More sharing options...
didisaan Posted November 4, 2017 Author Share Posted November 4, 2017 Use a combination of GetModIndex and GetLoadedTypeArray with type code 40 array_var aWeapons int iIndex let iIndex := GetModIndex "TheMod.esp" let aWeapons := GetLoadedTypeArray 40, iIndex I'll try that... Thank you! Link to comment Share on other sites More sharing options...
didisaan Posted November 5, 2017 Author Share Posted November 5, 2017 I'm trying to create a script that takes all the weapons from a formlist and gets their name and repair list, and prints them out to the console (for testing purposes).It gets the name but not the repair list.Someone please help :) array_var Entry ref rForm string_var sWeaponName ref rRepairList Begin Gamemode If (GetGameLoaded || GetGameRestarted) foreach Entry <- (GetListForms aaaWeaponList) let rForm := *Entry let sWeaponName := GetName rForm let rRepairList := GetRepairList rForm Print "Name: " + $sWeaponName + " Repair List: " + $rRepairList loop endif End Link to comment Share on other sites More sharing options...
Recommended Posts