CyranGE Posted August 5, 2015 Share Posted August 5, 2015 (edited) Hello, I edited an existing house mod, and it is perfect except the bathroom dont have a strip function, can anyone teacch me how to edit and/or make and/or transfer a script to my mod?by strip mod I mean, when an NPC enter the pool area/bathroom they will automatically strip :) Edited August 5, 2015 by CyranGE Link to comment Share on other sites More sharing options...
ToppDog Posted August 5, 2015 Share Posted August 5, 2015 It's been a long time since I got mine working, so I don't remember everything, but it is included in my mod, Dragons Keep, so you should be able to copy the source script, etc. & add them into your mod. When I did it, I looked at house mods that had it included to get an idea, such as Mammoth Manor, along.with a tutorial & DL version of a similar script, Bathing Suit in a pool Script and files by Jet4571. Hope that helps. Link to comment Share on other sites More sharing options...
CyranGE Posted August 5, 2015 Author Share Posted August 5, 2015 ty ty ty :) Link to comment Share on other sites More sharing options...
jpitner Posted August 5, 2015 Share Posted August 5, 2015 I forget where I got this but here goes: 1 - Create a new magic effect and call it LVENakedEffect change the following:Effect Archetype: ScriptCasting Type: Constant EffectAssoc. Item 1: NoneFX Persist: (check this box)Hide in UI: (check this box)Now when those are right hit ok, Then edit the object to pull up the same window you just hit ok on. You should now be able to add scripts so click "add" atthe bottom right and create a new script called "LVEnakedeffectscript" and add the following as its source__________________________________________________________________Scriptname LVEnakedeffectscript extends activemagiceffectarmor property JewelryRingGold autoEvent OnEffectStart(Actor akTarget, Actor akCaster);debug.notification("effect script: adding effect")akTarget.unequipall()endEventEvent OnEffectFinish(Actor akTarget, Actor akCaster);debug.notification("effect script: removing effect")akTarget.additem(jewelryringgold,1,true)akTarget.equipitem(jewelryringgold,false,true)akTarget.removeitem(jewelryringgold,1,true)endEvent__________________________________________________________________Make sure you auto-fill it's properties as well.(edit the script source and save it again, this should enable you to use auto-fill.)2 - Go to spells and make a new spell called "LVENakedSpell" then change the following:Casting: Constant EffectIgnore resistance: (check this box)Auto-Calculate: (uncheck this box)then add a new effect and make that effect "LVENakedEffect" and set it's duration to a very long time, like 10000 seconds. Hit ok on this window and on the spell window.3 - add a "defaultActivateSelfTRIG" object to each location you want people to take off their clothes. Edit each instance and remove the default script. Then createa new script, call it LVENakedActivator then add this code as it's source.__________________________________________________________________Scriptname LVENakedActivator extends ObjectReferencespell property LVENakedSpell autoEvent OnTriggerEnter(ObjectReference triggerRef);debug.notification("found something!")Actor akactionRef = triggerRef as Actorif (akActionRef != game.getplayer() && !akActionRef.isincombat());debug.notification("effect applied")LVENakedSpell.cast(akactionref,akactionref)endifendEventEvent OnTriggerLeave(ObjectReference triggerRef)Actor akactionRef = triggerRef as Actorif (akActionRef != game.getplayer());debug.notification("effect removed")akActionRef.dispelspell(LVENakedSpell)endifendEvent__________________________________________________________________make sure to auto fill the properties of each instance. Link to comment Share on other sites More sharing options...
kchez Posted June 2, 2016 Share Posted June 2, 2016 I forget where I got this but here goes: 1 - Create a new magic effect and call it LVENakedEffect change the following: Effect Archetype: ScriptCasting Type: Constant EffectAssoc. Item 1: NoneFX Persist: (check this box)Hide in UI: (check this box) Now when those are right hit ok, Then edit the object to pull up the same window you just hit ok on. You should now be able to add scripts so click "add" atthe bottom right and create a new script called "LVEnakedeffectscript" and add the following as its source __________________________________________________________________Scriptname LVEnakedeffectscript extends activemagiceffect armor property JewelryRingGold auto Event OnEffectStart(Actor akTarget, Actor akCaster);debug.notification("effect script: adding effect")akTarget.unequipall()endEvent Event OnEffectFinish(Actor akTarget, Actor akCaster);debug.notification("effect script: removing effect")akTarget.additem(jewelryringgold,1,true)akTarget.equipitem(jewelryringgold,false,true)akTarget.removeitem(jewelryringgold,1,true)endEvent__________________________________________________________________Make sure you auto-fill it's properties as well.(edit the script source and save it again, this should enable you to use auto-fill.) 2 - Go to spells and make a new spell called "LVENakedSpell" then change the following:Casting: Constant EffectIgnore resistance: (check this box)Auto-Calculate: (uncheck this box)then add a new effect and make that effect "LVENakedEffect" and set it's duration to a very long time, like 10000 seconds. Hit ok on this window and on the spell window. 3 - add a "defaultActivateSelfTRIG" object to each location you want people to take off their clothes. Edit each instance and remove the default script. Then createa new script, call it LVENakedActivator then add this code as it's source. __________________________________________________________________Scriptname LVENakedActivator extends ObjectReference spell property LVENakedSpell auto Event OnTriggerEnter(ObjectReference triggerRef);debug.notification("found something!")Actor akactionRef = triggerRef as Actorif (akActionRef != game.getplayer() && !akActionRef.isincombat());debug.notification("effect applied")LVENakedSpell.cast(akactionref,akactionref)endifendEvent Event OnTriggerLeave(ObjectReference triggerRef)Actor akactionRef = triggerRef as Actorif (akActionRef != game.getplayer());debug.notification("effect removed")akActionRef.dispelspell(LVENakedSpell)endifendEvent__________________________________________________________________make sure to auto fill the properties of each instance.Hi there. I've followed this vebatim with the exception of the name, instead is LVE I've gone with DD in all instances. As far as I can tell this shouldn't make any difference. For some reason though, it doesn't want to work for me. My character enters the areas as clad as ever. Is anything missing from this discription by any chance? Link to comment Share on other sites More sharing options...
RogueReverie Posted May 16, 2021 Share Posted May 16, 2021 I forget where I got this but here goes: 1 - Create a new magic effect and call it LVENakedEffect change the following: Effect Archetype: ScriptCasting Type: Constant EffectAssoc. Item 1: NoneFX Persist: (check this box)Hide in UI: (check this box) Now when those are right hit ok, Then edit the object to pull up the same window you just hit ok on. You should now be able to add scripts so click "add" atthe bottom right and create a new script called "LVEnakedeffectscript" and add the following as its source __________________________________________________________________Scriptname LVEnakedeffectscript extends activemagiceffect armor property JewelryRingGold auto Event OnEffectStart(Actor akTarget, Actor akCaster);debug.notification("effect script: adding effect")akTarget.unequipall()endEvent Event OnEffectFinish(Actor akTarget, Actor akCaster);debug.notification("effect script: removing effect")akTarget.additem(jewelryringgold,1,true)akTarget.equipitem(jewelryringgold,false,true)akTarget.removeitem(jewelryringgold,1,true)endEvent__________________________________________________________________Make sure you auto-fill it's properties as well.(edit the script source and save it again, this should enable you to use auto-fill.) 2 - Go to spells and make a new spell called "LVENakedSpell" then change the following:Casting: Constant EffectIgnore resistance: (check this box)Auto-Calculate: (uncheck this box)then add a new effect and make that effect "LVENakedEffect" and set it's duration to a very long time, like 10000 seconds. Hit ok on this window and on the spell window. 3 - add a "defaultActivateSelfTRIG" object to each location you want people to take off their clothes. Edit each instance and remove the default script. Then createa new script, call it LVENakedActivator then add this code as it's source. __________________________________________________________________Scriptname LVENakedActivator extends ObjectReference spell property LVENakedSpell auto Event OnTriggerEnter(ObjectReference triggerRef);debug.notification("found something!")Actor akactionRef = triggerRef as Actorif (akActionRef != game.getplayer() && !akActionRef.isincombat());debug.notification("effect applied")LVENakedSpell.cast(akactionref,akactionref)endifendEvent Event OnTriggerLeave(ObjectReference triggerRef)Actor akactionRef = triggerRef as Actorif (akActionRef != game.getplayer());debug.notification("effect removed")akActionRef.dispelspell(LVENakedSpell)endifendEvent__________________________________________________________________make sure to auto fill the properties of each instance.Hi there. I've followed this vebatim with the exception of the name, instead is LVE I've gone with DD in all instances. As far as I can tell this shouldn't make any difference. For some reason though, it doesn't want to work for me. My character enters the areas as clad as ever. Is anything missing from this discription by any chance? Hey I just made this work in Skyrim SE, and essentially it works the same way. I had a couple of mistakes at first but you have to be careful to follow each instruction and make sure that whatever you name your spells and effects is updated in the script part as well. For example, the fact that you used "DD" instead of "LVE" needs to be updated in the block of code you are adding to the scripts. Also make sure you edit the magic effect part as well as the object activator. I missed the part at first where you are supposed to add a script block to the magic effect as well as the script activator. Link to comment Share on other sites More sharing options...
aonach Posted October 2, 2021 Share Posted October 2, 2021 I forget where I got this but here goes: 1 - Create a new magic effect and call it LVENakedEffect change the following: Effect Archetype: ScriptCasting Type: Constant EffectAssoc. Item 1: NoneFX Persist: (check this box)Hide in UI: (check this box) Now when those are right hit ok, Then edit the object to pull up the same window you just hit ok on. You should now be able to add scripts so click "add" atthe bottom right and create a new script called "LVEnakedeffectscript" and add the following as its source __________________________________________________________________Scriptname LVEnakedeffectscript extends activemagiceffect armor property JewelryRingGold auto Event OnEffectStart(Actor akTarget, Actor akCaster);debug.notification("effect script: adding effect")akTarget.unequipall()endEvent Event OnEffectFinish(Actor akTarget, Actor akCaster);debug.notification("effect script: removing effect")akTarget.additem(jewelryringgold,1,true)akTarget.equipitem(jewelryringgold,false,true)akTarget.removeitem(jewelryringgold,1,true)endEvent__________________________________________________________________Make sure you auto-fill it's properties as well.(edit the script source and save it again, this should enable you to use auto-fill.) 2 - Go to spells and make a new spell called "LVENakedSpell" then change the following:Casting: Constant EffectIgnore resistance: (check this box)Auto-Calculate: (uncheck this box)then add a new effect and make that effect "LVENakedEffect" and set it's duration to a very long time, like 10000 seconds. Hit ok on this window and on the spell window. 3 - add a "defaultActivateSelfTRIG" object to each location you want people to take off their clothes. Edit each instance and remove the default script. Then createa new script, call it LVENakedActivator then add this code as it's source. __________________________________________________________________Scriptname LVENakedActivator extends ObjectReference spell property LVENakedSpell auto Event OnTriggerEnter(ObjectReference triggerRef);debug.notification("found something!")Actor akactionRef = triggerRef as Actorif (akActionRef != game.getplayer() && !akActionRef.isincombat());debug.notification("effect applied")LVENakedSpell.cast(akactionref,akactionref)endifendEvent Event OnTriggerLeave(ObjectReference triggerRef)Actor akactionRef = triggerRef as Actorif (akActionRef != game.getplayer());debug.notification("effect removed")akActionRef.dispelspell(LVENakedSpell)endifendEvent__________________________________________________________________make sure to auto fill the properties of each instance. In following these instructions, I'm running into an issue- neither of the scripts will auto-fill the properties. I've taken the normal steps- resaving and recompiling the scripts, restarting CK. Any ideas what the reason might be? Even if someone can give me pointers on how to set them manually, I think that would help. Thank you for the help. Link to comment Share on other sites More sharing options...
RobAntWar Posted October 6, 2021 Share Posted October 6, 2021 I struggled trying to get auto strip to work for a long time . After seeing this post from jpitner I used a mod from the Nexus called 'Springwood Estate - Player Home' . I checked the following items carefully - Activation Trigger , Spell . Magic Effect and Armor (Gold Ring) . Auto fill didn't work for me either but if you have all the correct values in place then it will appear in the drop down menus . If it appears to not work try getting the npc to enter and leave the trigger area a couple of times . I know very little about scripting but this is how I got it to work . I am still trying to figure out hope to auto strip player . Hope this helps . Link to comment Share on other sites More sharing options...
Recommended Posts