Cristobot Posted December 23, 2020 Share Posted December 23, 2020 I've seen this done with Relationship Dialogue Overhaul, Amazing Follower Tweaks, Better Vampires, and many others... I want to have a spell added to the player's spell list when the mod loads. (I think I need a quest? But I'm not quite sure how to do this.) I have the Magic Effect and Spell created, but how can I automatically add it to the Player inventory? If there is a reference on this somewhere please point me to it. Thanks in advance! Link to comment Share on other sites More sharing options...
maxarturo Posted December 23, 2020 Share Posted December 23, 2020 https://www.creationkit.com/index.php?title=OnPlayerLoadGame_-_Actorhttps://www.creationkit.com/index.php?title=OnInithttps://www.creationkit.com/index.php?title=AddSpell_-_Actor * I don't know how the mods you mentioned work, i've never looked at them and some i don't know them. Merry christmas. Link to comment Share on other sites More sharing options...
dylbill Posted December 23, 2020 Share Posted December 23, 2020 How I do it, is put a script on a new quest that's start game enabled. Scriptname MyInitScript extends Quest Actor Property PlayerRef Auto Spell Property MySpell Auto Event OnInit() Utility.Wait(1) PlayerRef.AddSpell(MySpell) Utility.Wait(1) self.Stop() ;stops this quest EndEventName the script something more unique. Happy Modding! Link to comment Share on other sites More sharing options...
Cristobot Posted December 23, 2020 Author Share Posted December 23, 2020 How I do it, is put a script on a new quest that's start game enabled. Scriptname MyInitScript extends Quest Actor Property PlayerRef Auto Spell Property MySpell Auto Event OnInit() Utility.Wait(1) PlayerRef.AddSpell(MySpell) Utility.Wait(1) self.Stop() ;stops this quest EndEventName the script something more unique. Happy Modding! I did as instructed and this worked in running on loading my mod! However, it didn't add my spell?Is anything wrong with this? Scriptname crbtAddEditNPCSpell extends Quest {Automatically adds spell on mod load} Actor Property PlayerRef Auto Spell Property crbtEditNPCInfo Auto Event OnInit() Utility.Wait(1) PlayerRef.AddSpell(crbtEditNPCInfo) Utility.Wait(1) self.Stop() ; stops this quest debug.messageBox("Added Edit NPC Info to Illusion list") EndEvent Link to comment Share on other sites More sharing options...
dylbill Posted December 23, 2020 Share Posted December 23, 2020 Make sure you filled your properties. After attaching the script, click on properties and Auto Fill All, if your properties are named the same in the script as in the creation kit, they should be automatically filled. Link to comment Share on other sites More sharing options...
Cristobot Posted December 23, 2020 Author Share Posted December 23, 2020 Thanks!It was my properties! Learning everyday! Link to comment Share on other sites More sharing options...
dylbill Posted December 23, 2020 Share Posted December 23, 2020 No problem, happy modding! Link to comment Share on other sites More sharing options...
Recommended Posts