GODSBANE123456 Posted July 22, 2010 Share Posted July 22, 2010 uhh why not just find the chest in dunbarrow cave, find its script, copy it, change the name of the copy, and add it to your chest? seems to me to be a much simpler way to do this than to try to recreate it... Link to comment Share on other sites More sharing options...
smoblikat Posted July 22, 2010 Author Share Posted July 22, 2010 that was the first thing i did but it didnt work either, im begginning to believe the chest in dunbarrow cave is working by pure PFM. Link to comment Share on other sites More sharing options...
ijarofjami Posted July 22, 2010 Share Posted July 22, 2010 Okay, so what you're wanting is a chest that you can pick, open up, take out the contents, close, and it will re-lock? I've never seen the chest in Dunbarrow Cave, so I wasn't too sure what you were looking for. I'll try figuring out how to do that later on tonight when I'm on my computer with the CS on it so I can test it out. Link to comment Share on other sites More sharing options...
GODSBANE123456 Posted July 22, 2010 Share Posted July 22, 2010 Ooo i got a good one (maybe)scn whateveryouwant short chestlock BEGIN Gamemode(tab) if get.chestlock == 0(Tab)(Tab) set chestrefid.lock 80 && set chestlock to 1END Begin onactivate(Tab) if get.chestlock == 1(Tab)(Tab) set chestlock to 0END If it doesn't work, then i wouldn't be surprised, but if it does then i will get back to my scripting... Link to comment Share on other sites More sharing options...
ijarofjami Posted July 22, 2010 Share Posted July 22, 2010 Okay, I've tested this script and it works. ScriptName Chestscript begin MenuMode 1008 if GetLocked == 0Lock 80endif end Here's how you do it: First, you need to create your own chest (if you haven't already done so - just duplicate a chest that's already made and rename it). Then you need to drag your chest into the render window where you want it to be. Double click the chest in the render window, click the "Lock" tab, tick the "Lock" box, and set the difficulty to "Hard" (which is also 80). Click OK. Now, in the Object Window, find your chest, and open the properties window by double clicking on it. Add the script to the chest. Save it and you should be good to go. Let me know if that did it for you. =) Link to comment Share on other sites More sharing options...
David Brasher Posted July 22, 2010 Share Posted July 22, 2010 Here is a script I tested in-game that works: SCN AATESTRelockingChestSCRIPT ; Object script attached to a lower class chest which is not a persistant reference. Begin Gamemode If GetDistance Player <= 500 Lock 80 EndIf End I was careless and missed reading some of the comments in the thread. When you said that the script with "if GetLocked == 0" was not working I decided not to use it. Myscript also works with with no If-Endif condition but that is really piggish of system resources. As far as optimization goes, ijarofjami's script is better. Mine is always running and checking conditions (but not executing commands.) The script by ijarofjami's has a definite trigger point and only runs one time for each time it executes its command. Link to comment Share on other sites More sharing options...
smoblikat Posted July 23, 2010 Author Share Posted July 23, 2010 Okay, I've tested this script and it works. ScriptName Chestscript begin MenuMode 1008 if GetLocked == 0Lock 80endif end Here's how you do it: First, you need to create your own chest (if you haven't already done so - just duplicate a chest that's already made and rename it). Then you need to drag your chest into the render window where you want it to be. Double click the chest in the render window, click the "Lock" tab, tick the "Lock" box, and set the difficulty to "Hard" (which is also 80). Click OK. Now, in the Object Window, find your chest, and open the properties window by double clicking on it. Add the script to the chest. Save it and you should be good to go. Let me know if that did it for you. =)wow finally, thank you everyone for your answers but this one was the one that did it......THANK YOU Scripting god. Link to comment Share on other sites More sharing options...
ijarofjami Posted July 24, 2010 Share Posted July 24, 2010 No problem, glad I could help. =D Link to comment Share on other sites More sharing options...
smoblikat Posted July 24, 2010 Author Share Posted July 24, 2010 No problem, glad I could help. =DI am a dim@$$ i figured out why the other scripts didnt work,i had set cell ownership to player so nothing could be locked!! Link to comment Share on other sites More sharing options...
Recommended Posts