Jump to content

SexLab Framework Development


Recommended Posts

Version 1.13:

Weird bug with 3P animations; all actors are teleported away and then get teleported back. They also randomly don't undress. If the player is involved in a 3P animation the player is usually teleported high into the air (with a loading screen during the teleportation) and then is teleported back; however sometimes the teleport back doesn't happens quickly enough so you hit the ground and die.

I've already fixed this in my version of v1.13, which I'm working on finalizing for full release.

 

Suggestions:

- A function that returns the hook string that was used when the animation was started with the StartSex() function.

Sure, I'll add it.

 

- An additional optional argument for the StartSex() function: int "sex type" or something similar; 1 = Foreplay, 2 = Sex, 3 = Aggressive Sex. If this argument is set SexLab starts an animation of said group even if the actor victim argument is set (in case of 1 and 2) or not (in case of 3).

What I try to achieve here is to be able to define a "victim" even during masturbation, foreplay or sex animations; this would be very helpful to e.g. let a spell like "Orgasm" from a Succubus be handled differently than a "meditation" through masturbation.

This can already be done via animation selection. Just select the animations you want using the right functions, and set your victim.

 

Victim scenes are only restricted to aggressive animations IF the mod in question doesn't select it's own animations. StartSex will use whatever animations you pass it, regardless of it's other arguments. Unless you pass it no animations at all, in which case it will attempt to select appropriate animations itself, which is where the the aggressive animations restricted to victim animations comes in.

 

 

actor[] sexActors = new actor[1]
sexActors[0] = TargetRef
sslBaseAnimation[] anims = SexLabGetAnimationsByTag(1, "Masturbation")
SexLab.StartSex(sexActors, anims, TargetRef)

Would accomplish exactly what you mentioned. Masturbation animation, with the actor as the victim.

Link to comment

This can already be done via animation selection. Just select the animations you want using the right functions, and set your victim.

 

Victim scenes are only restricted to aggressive animations IF the mod in question doesn't select it's own animations. StartSex will use whatever animations you pass it, regardless of it's other arguments. Unless you pass it no animations at all, in which case it will attempt to select appropriate animations itself, which is where the the aggressive animations restricted to victim animations comes in.

 

 

actor[] sexActors = new actor[1]
sexActors[0] = TargetRef
sslBaseAnimation[] anims = SexLabGetAnimationsByTag(1, "Masturbation")
SexLab.StartSex(sexActors, anims, TargetRef)
Would accomplish exactly what you mentioned. Masturbation animation, with the actor as the victim.

 

My goal is to find out if I hook an animation which returns a non-empty victim actor if it was meant to be a rape or a seduce.

 

So, when I have no information about how someone has started an animation I could find out with the following code

if SexLab.HookAnimation(string argString).HasTag(aggressive animation)
;   Rape
else
;   Seduce
endIf
if it's a rape or a seduce?

 

Hm, I guess to find out more about the tags I have to read through the source code of SexLab Framework? I can't find anything about them on the wiki.

Link to comment

 

This can already be done via animation selection. Just select the animations you want using the right functions, and set your victim.

 

Victim scenes are only restricted to aggressive animations IF the mod in question doesn't select it's own animations. StartSex will use whatever animations you pass it, regardless of it's other arguments. Unless you pass it no animations at all, in which case it will attempt to select appropriate animations itself, which is where the the aggressive animations restricted to victim animations comes in.

Yeap, but you can't distinguish if a sex act was meant to be a rape or not with the current SexLab functions, at least not easily and fail-proof.

With said additional variable you could e.g. easily distinguish between a rape victim and a "victim" that has been seduced.

 

 

There is no distinction to make. SexLab makes no claim if something was rape or not. Merely if there was a "victim" or not, and if so then everybody else must be the "aggressors" These words were specifically chosen over "raped" and "rapist", one because I deplore rape, and two because I don't want the system limited to any one mindset.

 

There is no difference between a "victim" and a "rape victim" in the eyes of a sexlab, that's up to individual modders own interpretation of victim & aggressor. 

 

If you want to treat an actor as the "seduced victim" than simply interpret them that way after getting them using SexLabFramework.HookVictim() or sslThreadModel.GetVictim()

Link to comment

Oh, a suggestion I forgot earlier:

 

- A function which returns the currently set length of an animation stage: .GetStage_1Length(), .GetStage_2Length() etc.

Reason is I want to add damage over time to a SexLab animation and to properly do so I need to know how long the animation is.

Link to comment

Oh, a suggestion I forgot earlier:

 

- A function which returns the currently set length of an animation stage: .GetStage_1Length(), .GetStage_2Length() etc.

Reason is I want to add damage over time to a SexLab animation and to properly do so I need to know how long the animation is.

 

You can already do that.

You can set the individual stage lengths in the MCM menu.

Link to comment

 

You can already do that.

You can set the individual stage lengths in the MCM menu.

Get, not Set.

I want a function that returns what you have set as the stage length in your MCM menu.

 

 

You can set the timers with the function sslThreadModel.SetTimers(float[] timers)

 

As for getting you can get them from the Timers property on sslThreadModel. Which returns the current used timer.

 

And you can get the total amount of time that's elapsed since animation start with the sslThreadController.GetTime() function.

Link to comment

 

As for getting you can get them from the Timers property on sslThreadModel. Which returns the current used timer.

Found it. I'm assuming the array contains the length of stage 1 in [0], stage 2 in [1] an so forth?!

 

 

Yes, up until the last one. For example, if the returned timer had a length of 6

 

[0] is stage 1

[1] is stage 2

[2] is stage 3

[3] is stage 4

[4] is stage 5+

[5] is Orgasm/Animation End

 

It will keep using the next element for a stage, so long as there is a next one, up until it get to the LAST element, the last element is reserved for the animation's orgasm stage, and any  excess stages will use the element before it, in this case a stage 8 would use [4], assuming there was another stage after stage 8.

Link to comment

Yes, up until the last one. For example, if the returned timer had a length of 6

 

[0] is stage 1

[1] is stage 2

[2] is stage 3

[3] is stage 4

[4] is stage 5+

[5] is Orgasm/Animation End

 

It will keep using the next element for a stage, so long as there is a next one, up until it get to the LAST element, the last element is reserved for the animation's orgasm stage, and any  excess stages will use the element before it, in this case a stage 8 would use [4], assuming there was another stage after stage 8.

So, the maximal length of said array can be 6, and if an animation has more than 5 plus one orgasm stages the time for stages 5, 6, 7 etc. are added up and stored in [4]?

Or is the length of the array unlimited?

Link to comment

 

Yes, up until the last one. For example, if the returned timer had a length of 6

 

[0] is stage 1

[1] is stage 2

[2] is stage 3

[3] is stage 4

[4] is stage 5+

[5] is Orgasm/Animation End

 

It will keep using the next element for a stage, so long as there is a next one, up until it get to the LAST element, the last element is reserved for the animation's orgasm stage, and any  excess stages will use the element before it, in this case a stage 8 would use [4], assuming there was another stage after stage 8.

So, the maximal length of said array can be 6, and if an animation has more than 5 plus one orgasm stages the time for stages 5, 6, 7 etc. are added up and stored in [4]?

Or is the length of the array unlimited?

 

 

 

The array can be any size, that's just how it interprets the array.

Link to comment

Holy crap this mod is amazing! :heart: Far better than anything on the skyrim nexus!

After toying with it for a little, I noticed when I was with Ysolda(Whiterun) and another in 3 way, she would sometimes bug and put her clothes back on during the animation. (v 1.14)

Link to comment

For Animating and Aligning the Bodies Together to work More Efficient do you Use Points of the Skeleton to designate where the male is Entering or do you just Place were it seems best on Models? 

 

I am just Curious on this Because i Plan on Animating After i can Successfully Create and import Models back and From Skyrim.

Link to comment

Updated first post with current major plans for v1.2 and various related notes. Which are as follows:

  • Allow other mods to register a stat to be displayed in the Sex Diary/Journal page
  • Creature support using FNIS 4.0
    • Would each creature need a unique "peniled" model that is swapped in for the creature performing the animation?
  • Investigate various methods of finding good clear spots to center animation on
    • Current idea under investigation involves spawning a dummy actor with placeatme that will find place nearest player it can fit, then centering the actors on that dummies location.
  • Investigate various methods of making the actors walk to each other to begin animation instead of warping
    • Current idea under investigation involves spawning a marker at the actors initial starting offset location, pathing to actor to the marker, and then starting their animation; removing the need to warp them at all at the start.
    • Unsure of how well such an idea would work in conjunction with previous listed idea of spawning dummy actor for center to find clear spots.
  • Investigate new ways to store animation scripts instead of requiring a new script for everyone
    • Possible idea includes single storage script that work off of mod events, create an event for each animation that stores information about it's stages and tags, then store each event name in a string array to be used to with SendModEvent for triggering each animation.
      • Each animation event would work similar to SexLab hook events, it would be passed the thread that called it, then manipulate that threads actors with the appropriate animations.
      • Maybe need a different event for each function, for example "event ArrokBoobJob_PlayStage() and event ArrokBoobJob_PositionActors()" for playing animations and positioning the actors respectively for the animation Arrok Boobjob.
      • ​But how to make that 3rd party mod expandable?
    • Probably solving a problem that doesn't really exists.
  • Timed acyclic animation support
    • Like normal animations, only instead of looping have specifically timed stages that don't loop.

 

Link to comment

 

...

The array can be any size, that's just how it interprets the array.

Papyrus limits arrays to 128 entries. That would however be a very long sex act.

 

 

Which, along with it's inability to make real multidimensional arrays; are my two biggest annoyances with papyrus by far.

Link to comment

 

 

...

The array can be any size, that's just how it interprets the array.

Papyrus limits arrays to 128 entries. That would however be a very long sex act.

 

 

Which, along with it's inability to make real multidimensional arrays; are my two biggest annoyances with papyrus by far.

 

I wonder that so many companies spend so much effort creating and developing new languages instead of using known languages.

 

Imagine scripting Skyrim using a version of Javascript.

Link to comment

 

 

 

...

The array can be any size, that's just how it interprets the array.

Papyrus limits arrays to 128 entries. That would however be a very long sex act.

 

 

Which, along with it's inability to make real multidimensional arrays; are my two biggest annoyances with papyrus by far.

 

I wonder that so many companies spend so much effort creating and developing new languages instead of using known languages.

 

Imagine scripting Skyrim using a version of Javascript.

 

I would think that a terrible idea honestly. interpreted languages like Javascript are slow, and on top of that it would have to interface with some abstraction layer between the language and the game, to convert the mods language into what the game understands, since obviously the game couldn't be built on such a language. Which would likely result in terrible mod performance in turn. And bypassing that by going with a lower level language like C would end up crippling the mod community, as fewer would be able to break into it due to complexity, plus open up all sorts of vulnerabilities.

 

It's about controlling what's possible and keeping out vulnerabilities, and by controlling the scope of a custom language, they are able to better fine tune its performance.

 

But I could be completely speaking out my ass here, just my semi-educated guess.

 

Still no excuse for a complete lack of proper support something as basic to a programming language as arrays are.

 

The inability to give a default to an array argument in a function is another god awful thing Papyrus does with arrays.

 

function Foo(float[] Bar = none)
endFunction

Compiles fine, and you'd think by all other accounts would let you not give the function an argument, but sure enough trying to compile a script with Foo() doesn't work. You HAVE to do

float[] Bar
Foo(Bar)

Which is utter stupidity.

Link to comment

Suggestion:

 

Along with the functions .AddTag() and .HasTag() add the functions .RemoveTag() and .HasNotTag().

 

Question:

 

How can I find out what tags are used to describe the animations in the base SexLab Framework?

 

RemoveTag() does exists on the base animation. I wouldn't consider it safe to be removing tags all haphazardly on animations though, unless they were specifcally tags you added yourself.

 

And there's no point in HasNotTag(), HasTag() returns a bool, just add a ! in front of the function and it turns into a check for it not having a tag.

Link to comment

Code:

17	sslBaseAnimation[] anims
18	anims = SexLab.GetAnimationsByTag("Aggressive")

Error message:

(18,16):type mismatch on parameter 1 (did you forgot to cast?)

I've helped myself by using

	sslBaseAnimation[] anims
	anims = SexLab.GetAnimationsByType(2, -1, -1, aggressive=true, sexual=true)

but I would still like to know why the above attempt doesn't work.

Link to comment

Code:

17	sslBaseAnimation[] anims
18	anims = SexLab.GetAnimationsByTag("Aggressive")

Error message:

(18,16):type mismatch on parameter 1 (did you forgot to cast?)

 

The first argument is actor count, not tag. http://git.loverslab.com/sexlab/wikis/function-getanimationsbytag

 

should be GetAnimationsByTag(2, "Aggressive") in order to select aggressive 2 person animations.

Link to comment

Can it be that SexLab ignores a .StartSex if the actorList.Length = 1 if you don't pass .SexLab.GetAnimationsByTag(1, "Masturbation") animations? The NPCs just ignored my spell when I didn't included that line in my code:

sslBaseAnimation[] anims = SexLab.GetAnimationsByTag(1, "Masturbation")

How can I select sex specific masturbation animations? SexLab.GetAnimationsByTag(1, "Masturbation", "Female")?!

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...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more information, see our Privacy Policy & Terms of Use