sedoacsltwwloqrddi Posted August 25 Posted August 25 (edited) INTRODUCTION This is a set of scripts and mods which emulate player captivity / enslavement after defeat. What does it do? These scripts: Leash the player if they're the victim of aggressive sex Set the player's factions so that most intelligent enemies won't then immediately murder them Doesn't interfere with anything else Is escapable by simply removing (you have to drop, not just unequip) their collar - with the caveat that doing so will immediately make your captors enemies again unless you're wearing some other heavy restraints. Requirements Leash Framework a defeat mod (I use Defeat (the BaneMaster edition) (Optional) a mod to handle any interactions while captive (I use deviously enslaved and the player whore dialogue options from Notice Me Senpai) Installation Add the two .sltscript files to your SKSE\Plugins\sl_triggers\commands folder In SLTriggers config, add: Helpless.sltscript -> on player equipment change (at 100%) LeashPlayer.sltscript -> on sexlab start with player victim (at whatever % you want depending on how frequently you want to be held captive, with whatever limitations to aggressors fit your taste) How can I escape? Drop (don't unequip) the collar. If something else is preventing you from doing so (for example, an armbinder), get rid of that first. What might go wrong? It messes with enemy factions, so there's the potential that it'll make some of them angry at you in ways that could interfere with normal game functionality (for example, if there's a quest that relies on one of the listed factions being friendly) As a side effect, anytime you're wearing heavy bondage you will be set as friendly to most enemy factions (the ones in the list in helpless.sltscript). How can I customize this? The easy one is factions. They're set in a list. Add any more you want to (for example, if you want regular creatures to become nonhostile, add that faction. If you want giants to still invite you to fly the friendly skies while captive, remove that faction). You can also set your events to trigger on things other than what I've expected. Potentially this could also be set up to affect NPCs, but without a lot of careful thought I expect that will end in an experiment that would make a budding epidemiologist proud. Make sure to add any problematic factions to the denylist in LeashPlayer.sltscript. These factions won't leash your player (because e.g. guards leashing your player while you're in jail could be problematic). Will this crash my game? Possibly. However: These scripts are intended only run on relatively uncommon events: Equip and starting scenes. They're written to handle most of their processing up front, and quickly close out if the circumstances don't suit their logic. They're mostly written to be idempotent. There's a denylist for problematic factions As usual, I recommend not using this on a long-running save you care about until you've tested it for a while with your setup and understand its behavior and limitations. There will be bugs. Taking people captive and abusing them is immoral. Correct. I recommend never doing so in real life. Where are the scripts? In the below spoiler tag: Spoiler Helpless.sltscript ;set $global.playerIsHelpless false ; INTENDED FOR USE ON SLTR CORE -> PLAYER EQUIPMENT CHANGE (100%) ; NOTE: THIS DOES NOT START ANY SEX EVENTS ITSELF. USE SOMETHING LIKE: ; -- DEVIOUSLY ENSLAVED ; -- DEVIOUSLY CURSED (LOOT) ; -- SOME OTHER AUTOMATION FRAMEWORK ; to handle starting scenes if you want them. ; --- Check if the Faction Map needs initialization --- if $global.factionsInitialized ; Map is already set up, skip initialization block else ; --- Populate the Map (Only runs the first time) --- set $global.factionMap{BanditAllyFaction} true set $global.factionMap{DraugrAllyFaction} true set $global.factionMap{ForswornFaction} true set $global.factionMap{FalmerFaction} true set $global.factionMap{WarlockFaction} true set $global.factionMap{VampireFaction} true set $global.factionMap{CreatureFaction} true set $global.factionMap{GiantFaction} true set $global.factionMap{HagFaction} true set $global.factionMap{SprigganFaction} true set $global.factionMap{DragonFaction} true set $global.factionMap{UndeadFaction} true set $global.factionMap{DwarvenAutomatonFaction} true set $global.factionMap{DremoraFaction} true set $global.factionMap{AtronachFaction} true ; Set our global tracker flags on first run set $global.factionsInitialized true set $global.playerIsHelpless false endif set $actorName resultfrom actor_name $system.player set $DDI1 resultfrom actor_wornhaskeyword $system.player "zad_DeviousHeavyBondage" set $DDI2 resultfrom actor_isaffectedby $system.player "zad_effHeavyBondage" set $isWearingLeash resultfrom actor_wornhaskeyword $system.player "lf_leash" set $isLeashed resultfrom leash_isleashed $system.player set $leash_item "Leash_neck_chain" ; if you'd prefer a different chain, set its editorID here. Rope is "Leash_neck", for example. string[] $factionList set $factionList resultfrom mapkeys $global.factionMap ; --- Setup Loop Variables --- set $counter 0 set $totalFactions resultfrom listcount $factionList ; Check if the player is helpless (wearing heavy bondage or a leash) set $DDI false if $DDI2 set $DDI true endif if $DDI1 set $DDI true endif if $isWearingLeash set $DDI true else if $isLeashed msg_notify $"You break your leash!" set $leashHolder resultfrom leash_getleashholder $system.player leash_disconnectleash $leashHolder $system.player item_remove $system.player $leash_item 1 false none endif endif ; Track if state needs an update loop set $changeHelplessState false ; If the player is helpless, set them as helpless and add them to enemy factions if $DDI if $global.playerIsHelpless ;msg_console $"[HELPLESS DEBUG] Branch A: player is already helpless." else ;msg_console $"[HELPLESS DEBUG] Branch B: Transitioning from FREE to HELPLESS for {$actorName}." set $factionValue 1000 set $global.playerIsHelpless true set $changeHelplessState true endif else ;If the player is no longer helpless, remove them from enemy factions if $global.playerIsHelpless ;msg_console $"[HELPLESS DEBUG] Branch C: Transitioning from HELPLESS to FREE for {$actorName}." set $factionValue -1 set $global.playerIsHelpless false set $changeHelplessState true else ;msg_console $"[HELPLESS DEBUG] Branch D: player is already free." endif endif ;msg_console $"[HELPLESS DEBUG] changeHelplessState flag is: {$changeHelplessState} | Total Factions to loop: {$totalFactions}" ; If the helpless state has changed, update factions if $changeHelplessState while $counter < $totalFactions set $currentFaction $factionList[$counter] msg_console $"updating {$currentFaction} for player" actor_setfactionrank $system.player $currentFaction $factionValue inc $counter 1 endwhile endif LeashPlayer.sltscript ; INTENDED FOR USE ON SLTR SEXLAB: SEXLAB START + PLAYER VICTIM (partner male + humanoid only optional) ; I use DEFEAT, which is why this doesn't use the Prisoner faction. ; get variables set $actorName resultfrom actor_name $system.player set $partnerName resultfrom actor_name $system.partner set $isWearingLeash resultfrom actor_wornhaskeyword $system.player "lf_leash" set $isLeashed resultfrom leash_isleashed $system.player set $leash_item "Leash_neck_chain" ; --- Check if the Denylist Faction Map needs initialization --- if $global.denylistFactionsInitialized ; Map is already set up, skip initialization block else ; --- Populate the Map (Only runs the first time) --- set $global.denylistFactionMap{GuardFaction} true ; Set our global tracker flags on first run set $global.denylistFactionsInitialized true set $global.playerIsHelpless false endif string[] $factionList set $factionList resultfrom mapkeys $global.denylistFactionMap ; --- Setup Loop Variables --- set $counter 0 set $totalFactions resultfrom listcount $factionList while $counter < $totalFactions set $currentFaction $factionList[$counter] msg_console $"updating {$currentFaction} for player" set $isDenylisted resultfrom actor_infaction $system.partner $currentFaction if $isDenyListed msg_console $"{$partnerName} not eligible to leash {$playerName}." endif inc $counter 1 endwhile ; if the player's not wearing a leash, put one on. if $isWearingLeash else msg_notify $"{$partnerName} collars you. You're just a pet now..." item_equip $system.player $leash_item true false endif ; if the player's not leashed, leash them. if $isLeashed else actor_doaction $system.partner StopCombat item_equip $system.player $leash_item true false msg_notify $"{$partnerName} takes hold of your leash." leash_applyleash $system.partner $system.player "NPC Spine2 [Spn2]" "Leash1" 150.0 300.0 true endif Troubleshooting The global helplessness variable they set to achieve the optimization in #2) can get out of sync. If that's the case, add Quote set $global.playerIsHelpless false to the top of the 'helpless' script, save the script, unequip all your devices, then remove it from the script and save again and it should start working again. Updating the denylist It may be problematic for some NPCs to leash your player. If you find one, add their faction to the denylist. For example, if I have a mod that adds Mr. Beeblebrox, President of the Universe to my game, but if he leashes my character they end up going on adventures in space instead of Skyrim, I can click him in console, check his factions, and add one to the denylist on a new line below the existing one in LeashPlayer.sltscript, like so: Quote ; --- Populate the Map (Only runs the first time) --- set $global.denylistFactionMap{GuardFaction} true set $global.denylistFactionMap{BeeblebroxFaction} true This doesn't work for me Sorry about that. Please feel free to edit the scripts so that they do. License TLDR: Do what you like, but let others do the same, keep it on the site, and don't blame me if something goes wrong. Details In the below spoiler tag: Spoiler Consider these scripts under a slightly modfiied MIT license, which reads: Quote Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), without limitation the rights to use, copy, or modify copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. Permission is not granted to redistribute or rebundle the software on any other site for any reason without explicit permission of its creator. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. Edited August 26 by sedoacsltwwloqrddi Simplify 1
Recommended Posts