Korodic Posted March 22, 2019 Share Posted March 22, 2019 Was looking over Automatron, wanted to know whether or not it was possible to modify robots via script to give specific add-ons. Kind of hard trying to figure out the existing workbench system. Found this post: https://www.reddit.com/r/FalloutCK/comments/8ucu4u/how_to_spawn_a_weapon_with_specific_mods_attached/ Guess I need to see if it's possible to spawn a robot and then modify it post-spawn. Could probably use leveled lists to create randomization of parts. Link to comment Share on other sites More sharing options...
SandMouseAnarchy Posted March 22, 2019 Share Posted March 22, 2019 (edited) Definitely possible mate! :) Look on the ck wiki for "AttachMod" and "AttachModToInvintoryItem" they will be the main parts of your code.(in one of the AttachMod wiki pages they give a robot a mod as an example script - that would be a great place to start looking)Other than that, for every "mod" you want on your robot - the (armo) armor record for that robots Base body part (eg, torso, Larm, etc) will need attachpoints (ap) ((these will be the categories that show in the menu)) and the armor record will also need a (ma_) mod association keyword.Then every mod you want to have will need an (OMod) object mod, and that object mod will need a corresponding (misc) misc item and a (CObj) constructible object. Inside each OMod place in one the ma keyword that is in armor record and place in the ap keyword so that the mod appears in that category. And that's it really :) Note - the ap category keyword must be named or no category will show, and the OMod must be named or no option will show in the workbench.The same name for the ap category keyword you put in your OMod and armor record need to match the name of a child connect point (CPT) in the mods nif (if any), and that same ap name needs to be in a (CPA) parent attach point in the armor record's nif Edited March 22, 2019 by SandMouseAnarchy Link to comment Share on other sites More sharing options...
Korodic Posted March 22, 2019 Author Share Posted March 22, 2019 Definitely possible mate! :smile: Look on the ck wiki for "AttachMod" and "AttachModToInvintoryItem" they will be the main parts of your code.(in one of the AttachMod wiki pages they give a robot a mod as an example script - that would be a great place to start looking)Other than that, for every "mod" you want on your robot - the (armo) armor record for that robots Base body part (eg, torso, Larm, etc) will need attachpoints (ap) ((these will be the categories that show in the menu)) and the armor record will also need a (ma_) mod association keyword.Then every mod you want to have will need an (OMod) object mod, and that object mod will need a corresponding (misc) misc item and a (CObj) constructible object. Inside each OMod place in one the ma keyword that is in armor record and place in the ap keyword so that the mod appears in that category. And that's it really :smile: Note - the ap category keyword must be named or no category will show, and the OMod must be named or no option will show in the workbench.The same name for the ap category keyword you put in your OMod and armor record need to match the name of a child connect point (CPT) in the mods nif (if any), and that same ap name needs to be in a (CPA) parent attach point in the armor record's nif Thanks for the tip, I'll definitely be playing around w/ this. Link to comment Share on other sites More sharing options...
BlahBlahDEEBlahBlah Posted March 22, 2019 Share Posted March 22, 2019 Another tip is that OMOD adds/removed from actors via script do not always show right away, if 3D loaded.Sure way to force the change is to disable the actor then enable the actor again after doing the adds/removes. Link to comment Share on other sites More sharing options...
SandMouseAnarchy Posted March 22, 2019 Share Posted March 22, 2019 Ah, nice tip BlahblahDeeBlahBlah! With too many OMods being equipped/unequipped at the same time can cause the mod to still show up after it's removed, I think it's got something to do with the game not actually checking if a mod has been equipped or not before doing another operation. Not everything disappears straight away when it's disabled, so disabling and then re-enabling the item might circumvent the 3d unloading and reloading - will have to test ^.^ Link to comment Share on other sites More sharing options...
Korodic Posted April 7, 2019 Author Share Posted April 7, 2019 So I notice 3D loads, however, when attaching a weapon it doesn't seem to add the weapon to the inventory of the robot. Does anyone know if I'm doing something wrong or if this is a limitation of this command? I did give ammo directly to the inventory of the robots, so it isn't that. If I add the weapons manually then they will use them. Link to comment Share on other sites More sharing options...
Recommended Posts