Rattlerx5150 Posted February 11, 2013 Share Posted February 11, 2013 I need a script,, since im so bad at skyrim scripting I have a room in my mod house that I call my vault,, its got 3 doors protecting it I would like to make a "lock doors" button, that when pressed willl close, and lock all 3 doors can this be dont, , can you post the script here, and I can do the rest Thank you all in advance Link to comment Share on other sites More sharing options...
Woverdude Posted February 11, 2013 Share Posted February 11, 2013 What level of lock do you want? Easy, hard, requires key, etc.? Link to comment Share on other sites More sharing options...
Rattlerx5150 Posted February 11, 2013 Author Share Posted February 11, 2013 MASTER , I just want a means of closing and locking all doors at once Link to comment Share on other sites More sharing options...
Woverdude Posted February 11, 2013 Share Posted February 11, 2013 Locking them is pretty easy with a script. I'm not sure how closing them would be done. Technically, that is an animation. You might be able to get around this by "Activating" the doors to close them, then locking them. However, if any of the doors were already closed, then doing this would actually open them. Does anyone else reading this post know how to check whether a door is in the "Open" state? Link to comment Share on other sites More sharing options...
Ghaunadaur Posted February 11, 2013 Share Posted February 11, 2013 GetOpenState SetOpen SetLockLevel Lock Link to comment Share on other sites More sharing options...
Ghaunadaur Posted February 12, 2013 Share Posted February 12, 2013 (edited) Put this script on the button you want to use and fill the script properies with the door references. Scriptname YourScriptName extends ObjectReference ObjectReference Property Door01 Auto ObjectReference Property Door02 Auto ObjectReference Property Door03 Auto Event OnActivate(ObjectReference akActionRef) if Door01.GetOpenState() <= 2 Door01.Setopen(false) Door02.Setopen(false) Door03.Setopen(false) Door01.SetLockLevel(100) Door02.SetLockLevel(100) Door03.SetLockLevel(100) Door01.Lock() Door02.Lock() Door03.Lock() else Door01.SetLockLevel(100) Door02.SetLockLevel(100) Door03.SetLockLevel(100) Door01.Lock() Door02.Lock() Door03.Lock() endif EndEvent Edited February 12, 2013 by Ghaunadaur Link to comment Share on other sites More sharing options...
Rattlerx5150 Posted February 12, 2013 Author Share Posted February 12, 2013 I tried this script in 2 different buttons, the script compiled fine Dwebutton01and Impbutton01 nothing happens am I missing something Link to comment Share on other sites More sharing options...
Ghaunadaur Posted February 12, 2013 Share Posted February 12, 2013 Have the properties actually been filled correctly? Also, what doors are you using? Link to comment Share on other sites More sharing options...
Rattlerx5150 Posted February 12, 2013 Author Share Posted February 12, 2013 I set the properties 2 doors are SERuinsDoor011 is DweDoorLarge01 Link to comment Share on other sites More sharing options...
Rattlerx5150 Posted February 12, 2013 Author Share Posted February 12, 2013 Im thinking...Would it be easier to have a script in the doors themselves that will automatically lock themselves when each door is closed manually Link to comment Share on other sites More sharing options...
Recommended Posts