roland3710 Posted September 14, 2013 Posted September 14, 2013 My goal is to make it so that sleeping in a particular bed completes a quest for the player and adds a spell. Adding the spell works perfectly fine though dialog so I am pretty certain the problem lies with the script I have attached to the bed reference. While the script compiles successfully nothing happens after sleeping in the bed in-game. No quest update and no spell added. It seemed pretty straightforward but I am obviously missing something. The script is below and the script, quest and spell names have been replaced with X, Y and Z. Scriptname Z extends ObjectReference Quest Property X Auto SPELL Property Y Auto Event OnSleepStop(bool abInterrupted) X.SetStage(70) Game.GetPlayer().Addspell(Y) EndEvent At any rate I would appreciate any help anyone is willing to provide. Thanks.
IsharaMeradin Posted September 14, 2013 Posted September 14, 2013 The wiki page says you have to RegisterForSleep before you can use that event. You may also need to UnregisterForSleep as well.
roland3710 Posted September 14, 2013 Author Posted September 14, 2013 Thanks for the advice. I'll try it out.
Recommended Posts