Lumina Posted June 12, 2015 Share Posted June 12, 2015 Hello, I know how to add a drop to a monster prefabs but is there a cleanest way to add a drop to an existing monster ? (Like Warg, in my example)Like putting some code in "modmain" instead of a prefab ? (Because i suppose that if i call the "warg" prefabs it could conflict with another mod modifying the prefabs too ?) Link to comment Share on other sites More sharing options...
Fancy_Fox_Pers Posted June 12, 2015 Share Posted June 12, 2015 @Lumina, A PrefabPostInit in you modmain modifying the right functions of the right prefabs should work pretty well while avoiding compatibility issues. Link to comment Share on other sites More sharing options...
Lumina Posted June 12, 2015 Author Share Posted June 12, 2015 Ok, it seems to work well.Thanks Link to comment Share on other sites More sharing options...
Kzisor Posted June 12, 2015 Share Posted June 12, 2015 @Lumina, example:local function WargPostInit( inst ) if not TheWorld.ismsatersim then return inst end if inst.components.lootdropper then inst.components.lootdropper:AddChanceLoot("warg", 1) end return instendAddPrefabPostInit( "warg", WargPostInit) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now