Jump to content
IGNORED

Need Advice in making a patch for Sexlab Sex Slaves


Recommended Posts

I am trying to make a small update to scripts for Sex Slaves (AKA, Mia's Lair), but I am completely new to editing scripts (and scripting in general), so I am in need of some advice on how to proceed. First off, I did ask the original modder for permission to make changes. It was quite a while ago, but he made it clear that he had no problem with people modifying the mod. :3

 

Second, I guess I'll summarize the changes I want to make.

 

  1. I want to remove the gender lock on new slave training. In the original mod, only male player-characters can start training a new slave. Female players can train existing or purchased slaves, but only a male can bring a female follower to the dungeon and turn them into a Sex Slave. This seems like a pretty arbitrary restriction, so it ought to be a fairly straightforward fix if I can find the right thing to change!
  2. I want to allow the mod to choose from a wider variety of animations. In the original, there are many events which call for a very specific animation, instead of choosing from a full list of appropriate animations. For example, when a sex slave is ordered to go go down on a female PC they will only ever use the old Arrok Lesbian animation, or a male PC will only get the AP Kneeling Blowjob. Even if you have dozens more animations of the same type installed. This is an important thing to update, because there is a game-breaking glitch which might force you to reload your last save if you happen to not have the specific animation it wants.
  3. I want the mod to look for the Sexlab-designated gender when determining which animations to use. Currently, there is no love in Sex Slaves for dickgirl PCs. If a domme dickgirl wants her cock sucked, she's out of luck. This is a grotesque injustice, and it shall not stand!

 

I think that covers all the changes I feel are important! I love this mod a lot, but the arbitrary restrictions on gender and animations are an unfortunate blemish on its quality. But with that said... I have no idea how to accomplish it. Okay, that's not quite true. I have a very rough idea of how to accomplish some of it, but it would be great if someone with more experience could help me out!

 

Here's the script file which governs all of these things, in case its needed for reference: SexSlaveFramework.psc

 

Let's start with the variety of animations, since I know where to find them! Here's the first example, starting on Line 556 of SexSlaveFramework.psc.

 

Spoiler

Function OralSex(Actor victim, Actor theMaster)

 

    Actor[] sexActors = new Actor[2]


    if(theMaster.GetLeveledActorBase().GetSex() == 1)
        sexActors[1] = victim
        sexActors[0] = theMaster
    else
        sexActors[0] = victim
        sexActors[1] = theMaster
    endif

 

    ;sexActors = SexLab.SortActors(sexActors)
    sslBaseAnimation[] anims = new sslBaseAnimation[1]
    ;sslBaseAnimation[] anims = SexLab.GetAnimationsByTag(2, "BlowJob", Tag2 = "Aggressive")

 

    if(theMaster.GetLeveledActorBase().GetSex() == 1)
        anims[0] =  SexLab.GetAnimationByName("Arrok Lesbian")
    else
        anims = SexLab.GetAnimationsByTag(2, "Blowjob")
        ;anims[0] =  SexLab.GetAnimationByName("AP Kneeling Blowjob")
    endif
    int id = SexLab.StartSex(sexActors, anims, allowBed=false)
endFunction

 

That block of code is, I think, the event that happens when the PC tells his or her sex slave to perform oral sex. At the moment, it will always result in either Arrok Lesbian or AP Kneeling Blowjob, depending on whether the PC is male or female. And I'm super confused about that, because it looks like there are lines relating to finding animations based on tags...

 

Edit: Alright, so its not quite as black-and-white as I thought. I decided to get through the main quest of Sex Slaves, so I would be able to test any changes I make to the script. It turns out that there are some events in the mod that already do allow for a wider variety of animations, while others are restricted to a single specific animation. I'll need to make a list of which event does which, and look for differences in how they're scripted. So for now, I'll focus on trying to figure out how to use the Sexlab gender designation.

 

This part looks like its determining whether the PC is male or female, so its a good place to start:

Spoiler

   Actor[] sexActors = new Actor[2]


    if(theMaster.GetLeveledActorBase().GetSex() == 1)
        sexActors[1] = victim
        sexActors[0] = theMaster
    else
        sexActors[0] = victim
        sexActors[1] = theMaster
    endif

 

I am thinking that "GetSex" is the function that determines whether the character's base gender is male or female. In order for it to look for the SexLab gender, it will have to be replaced. Other mods do it, so it must be possible here... I just have no idea what to replace it with. So there's my first question: What script command is used to call for the Sexlab gender?

 

Link to comment

Progress Report:

 

1) I still don't have any idea how to set it up for using the Sexlab gender. I don't know where to find that kind of information myself, so I really need someone to tell me. :c

 

2) I found a bunch of typos in SexSlaveFramework.psc. In one instance, "GetAnimationsByTag" was typed as "GetAnimationsByTags". There were also many, many places where this line, SexLab.GetAnimationsByTag(2, "BlowJob", Tag2 = "Aggressive"), was written as SexLab.GetAnimationsByTag(2, "BowJob", Tag2 = "Aggressive"). Fixing those typos will probably fix... well, something. I'm not entirely sure what that will do, but I'm sure it will help! ^_^

 

I'll keep an eye out for more typos while I'm working on this, an fix them when I can.

 

That said, I think I'm ready to try converting this .psc file to a .pex. I'm not sure how to do that, so I'm going to look it up and give it a try!

 

Edit: Well, it's been two days and no replies from... anyone. I've already reached the limits of what I know how to do, so it looks like this patch will never happen. Maybe a more experienced modder will someday make a similiar attempt, with more success.

Link to comment
  • 1 year later...

Okay, so as far as i understand how it works and in my own limited testing. You are able to use the pronouns mod on the nexus to force the quest as well as the rest of the game to view your character as male. https://www.nexusmods.com/skyrimspecialedition/mods/43816?tab=files

 

It does not seem to change the animations for the player character bonding to the slaves, however it does change the rest of the quests associated with mias lair and allow you to give the dremora dude a female follower.

 

Hope this helps the next person looking for a solution

Link to comment
On 5/13/2021 at 4:54 PM, lomg hong said:

Okay, so as far as i understand how it works and in my own limited testing. You are able to use the pronouns mod on the nexus to force the quest as well as the rest of the game to view your character as male. https://www.nexusmods.com/skyrimspecialedition/mods/43816?tab=files

 

It does not seem to change the animations for the player character bonding to the slaves, however it does change the rest of the quests associated with mias lair and allow you to give the dremora dude a female follower.

 

Hope this helps the next person looking for a solution

Actually, SL gender is handled differently than game gender - use the function SexLab.getGender(Actor akActor) to get the correct gender for animations.

You can also correct the animation issue by re-writing them as such:
 

    ;sexActors = SexLab.SortActors(sexActors)
    ;sslBaseAnimation[] anims = new sslBaseAnimation[1]
    sslBaseAnimation[] anims = SexLab.GetAnimationsByGenderTags(2, "BlowJob, Aggressive", none, true)

    ;if(theMaster.GetLeveledActorBase().GetSex() == 1)
    ;    anims[0] =  SexLab.GetAnimationByName("Arrok Lesbian")
    ;else
    ;   anims = SexLab.GetAnimationsByTag(2, "Blowjob")
    ;anims[0] =  SexLab.GetAnimationByName("AP Kneeling Blowjob")
    ;endif

Not sure why but the original mod author explicitly excluded all the rest of the animations in the registry. ¯\_(ツ)_/¯

You can fix a lot of the issues by using SexLab.getGender() instead of GetLeveledActorBase(), and most of the animations are fixable since they're hardcoded for some reason. You could probably remove the requirement for training new slaves as well, but I'm too lazy to go through all that mess. Honestly the whole script needs to be reworked desperately, that's a scripting nightmare for script-intensive playthroughs.

 

Lastly compiling scripts into .pex files is pretty simple with the CK, just make sure you have the necessary files for SL and SLA:

Anyway hope this helps somebody, I know this is a total necropost but I figured this'll help someone later on.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...