Jump to content
Ashal

SexLab Framework Development

Recommended Posts

Just a thought pertaining to end sequence animations instead of ragdolling:

 

What about the end sequence from estrus/estrus chaurus?

There's kind of a brief post coitus rest then stand up animation, from both lying on back, and lying on stomach in there.

idk if they're really usable permission wise or w/e, but the animations aren't all that bad considering.

 

Pardon if it's been mentioned already.

Share this post


Link to post

 

 

 

As for the clipping, I don't know if there is a solution to that, I've tried just about everything I could there from a papyrus level, if you can find a way to reduce the clipping distance in C, than that should do the trick.

 

easy fix for objects clipping too close to the player, under skyrim.ini in the [display] section add this line

 

fNearDistance=4.0000

 

 

Thanks this fixed it, but 4 was still a little bit of clipping. This was perfect:

fNearDistance=1.0

fNear1stPersonDistance=1.0

 

These can't be set while in game with setini so they must be added to ini or I could look into overwriting this somehow but not sure if it's worth the effort.

 

I uploaded another version of the plugin. If you setcameranode then it will write a text file saying previous camera rotation and the node rotation you set to I think it was named "debug_camera.txt" in skyrim exe folder.

 

Also added saving int, float, string, int list, float list, string list to separate file. This can be useful if you want to share data between savegames for example if someone modifies animation offsets then they probably want to use it in all savegames and this type of info can go in there.

 

Added writetofile, readfromfile functions and get reference by form id, so you can use the int value or int list value saving to save object references (akTargetRef.GetFormID() to save and SexLabUtil.GetReference(formId) to get reference again).

 

Fixed some errors with list earlier that caused infinite loop.

 

Any news on getting the rotation matrix working, Ashal? :)

slplugin4.zip

Share this post


Link to post

Thanks this fixed it, but 4 was still a little bit of clipping. This was perfect:

fNearDistance=1.0

fNear1stPersonDistance=1.0

 

These can't be set while in game with setini so they must be added to ini or I could look into overwriting this somehow but not sure if it's worth the effort.

It would be nice if these values could be changed ingame, for the duration of 1st person sex only. Drastically reducing them from their defaults (15.0 and 5.0) can lead to increased z-fighting in the distance, such as flickering textures on mountains. So I wouldn't like to keep them like that during normal gameplay. Of course, the amount of z-fighting also depends on your graphics hardware and driver, so everyone has to see for himself what's tolerable.

Share this post


Link to post

 

 

As for the clipping, I don't know if there is a solution to that, I've tried just about everything I could there from a papyrus level, if you can find a way to reduce the clipping distance in C, than that should do the trick.

 

easy fix for objects clipping too close to the player, under skyrim.ini in the [display] section add this line

 

fNearDistance=4.0000

 

 

Thanks this fixed it, but 4 was still a little bit of clipping. This was perfect:

fNearDistance=1.0

fNear1stPersonDistance=1.0

 

These can't be set while in game with setini so they must be added to ini or I could look into overwriting this somehow but not sure if it's worth the effort.

 

 

They can be, I've already added it to my papyrus implementation for 1st person and it works fine.

; // Entering first person mode
fNearDistance = Utility.GetINIFloat("fNearDistance:Display")

; // Leaving first person mode
Utility.SetINIFloat("fNearDistance:Display", fNearDistance)
Atleast fNearDistance does, I didn't test with a fNear1stPersonDistance. 

 

 

I uploaded another version of the plugin. If you setcameranode then it will write a text file saying previous camera rotation and the node rotation you set to I think it was named "debug_camera.txt" in skyrim exe folder.

Can you have it print these 3 to the file:

  • Rotation node matrix
  • Camera rotation matrix BEFORE override
  • Camera rotation matrix AFTER override
  • Rotation node matrix AFTER override (incase it's changed at all since)

Also added saving int, float, string, int list, float list, string list to separate file. This can be useful if you want to share data between savegames for example if someone modifies animation offsets then they probably want to use it in all savegames and this type of info can go in there.

 

Added writetofile, readfromfile functions and get reference by form id, so you can use the int value or int list value saving to save object references (akTargetRef.GetFormID() to save and SexLabUtil.GetReference(formId) to get reference again).

 

 

A lot of these function should probably be split out of SexLabUtil into their own script files, rather than jamming it all into one. I'm a picky bastard when it comes to keeping the scope and purpose of assets as limited as possible. And I've been using SexLabUtil for other papyrus based global functions before all this, the scripts getting kinda unwieldy with all these new variable functions.

 

I'd propose a separate StorageUtil script for the for the all object and file storage functions.

 

 

But what format do they save to now? I'd love a JSON or INI-style format for saving settings such as offsets. There was a XML file SKSE plugin released awhile  ago I thought about using for this, but I despise all things XML, and it required adding a new esp dependency to the mod.

 

It would have to be fast though, or at least not significantly slower than current methods of saving offsets to the script variables.

 

Something like this would be nice using JSON as an example:

 

 

{
	"ArrokOral" : [
		// Stage 1
		[
			{
				"forward" : 0,
				"sideways" : 0,
				"upward" : 3.50,
				"rotation" : 0,
				"SchlongOffset" : 0
			},
			{
				"forward" : 60,
				"sideways" : 0,
				"upward" : 3.50,
				"rotation" : 180,
				"SchlongOffset" : 5
			}
		],
		// Stage 2
		{
			"Actor1" : {
				"forward" : 0,
				"sideways" : 0,
				"upward" : 2.50,
				"rotation" : 0,
				"SchlongOffset" : 0
			},
			"Actor2" : {
				"forward" : 65,
				"sideways" : 0,
				"upward" : 0,
				"rotation" : 180,
				"SchlongOffset" : 3
			}
		}
		// And so on...
	],
	"ArrokCowgirl" : [
		// Blah blah
	]
}
Then accessed in papyrus like so

SexLabUtil.OpenJSON("sexlab/animations.json")

; // Get the forward offset for stage 1 actor 2 in the Arrok Oral animation
float offset = SexLabUtil.GetJSONFloat("ArrokOral[0][1].forward")
; // Get other offsets before closing the file

SexLabUtil.CloseJSON("sexlab/animations.json")

 

 

By no means any sort of priority, just a thought and personal preference on how to handle external file settings.

 

 

(akTargetRef.GetFormID() to save and SexLabUtil.GetReference(formId) to get reference again).

SexLabUtil.GetReference(formId)already exists in vanilla papyrus.

 

Game.GetForm(formID) as ObjectReference

 

Any news on getting the rotation matrix working, Ashal? :)

Haven't looked at it much yet today, trying to catch up on that pesky paying jobs work at the moment.

Share this post


Link to post

Hmm let's separate the functions later because I will probably add / change a lot more before release of next version of sexlab and it would get tedious. Or I mean I could change it now too if you like but it might be empty work.

 

Hmm I tried exact same papyrus code and it didn't work for me when I put it on a spell.

 

These rotations aren't necessary because camera rotation = what it was before and camera rotation after = node rotation, node rotation after = also node rotation so those 2 matrixes actually show everything.

 

Actually what I thought would be good is if you put the default animation offset in papyrus script and only save to file if user modifies the offsets. So only the modifications are saved to file. It saves in a format that is human readable but not too easy to modify. I wouldn't recommend writing data outside of scripts.

 

Ah cool didn't know about the object reference functions. :P

 

Alright, I think this first person view is going to be awesome :D

 

Edit: or you probably want to write in scripts already using StorageUtil.* ? Yeah probably better to separate now then. I'll write in next version.

Share this post


Link to post

Hmm let's separate the functions later because I will probably add / change a lot more before release of next version of sexlab and it would get tedious. Or I mean I could change it now too if you like but it might be empty work.

 

Hmm I tried exact same papyrus code and it didn't work for me when I put it on a spell.

 

These rotations aren't necessary because camera rotation = what it was before and camera rotation after = node rotation, node rotation after = also node rotation so those 2 matrixes actually show everything.

 

Actually what I thought would be good is if you put the default animation offset in papyrus script and only save to file if user modifies the offsets. So only the modifications are saved to file. It saves in a format that is human readable but not too easy to modify. I wouldn't recommend writing data outside of scripts.

 

Ah cool didn't know about the object reference functions. :P

 

Alright, I think this first person view is going to be awesome :D

What about those forced 0.0 values from the original camera rotation? Are you accounting for those in the override? The camera might be using a different type of matrix than regular nodes.

Share this post


Link to post

No I'm not accounting for anything because I have no idea how a rotation matrix works or a regular matrix.

Share this post


Link to post

Skyrim sets rotation on camera like this:

*(float *)(a1 + 1744) = *(float *)a8;

*(float *)(a1 + 1748) = *(float *)a7;

*(float *)(a1 + 1752) = *(float *)a6;

*(float *)(a1 + 1756) = 0.0;

*(float *)(a1 + 1760) = *(float *)(a8 + 4);

*(float *)(a1 + 1764) = *(float *)(a7 + 4);

*(float *)(a1 + 1768) = *(float *)(a6 + 4);

*(float *)(a1 + 1772) = 0.0;

*(float *)(a1 + 1776) = *(float *)(a8 + 8);

*(float *)(a1 + 1780) = *(float *)(a7 + 8);

*(float *)(a1 + 1784) = *(float *)(a6 + 8);

*(float *)(a1 + 1788) = 0.0;

I mean account for it in sense that the camera override includes applying the

 

*(float *)(a1 + 1756) = 0.0;

*(float *)(a1 + 1772) = 0.0;

*(float *)(a1 + 1788) = 0.0;

 

values from the original?

Share this post


Link to post

Still same answer :D

How and where are is the matrix being applied to the camera then?

Share this post


Link to post

Hmm good question, I hook a game function that sets camera rotation and I just overwrite the camera's rotation matrix with the node's rotation matrix, but perhaps there are more calculations made after I set this.

Share this post


Link to post

I am using the development build and with matchmaker I can get the death hounds to have sex with my PC but their is no animation the creature sits at 180 degrees on my character and doesn't move/animate. Is their anything I need to do to make this work. I have run FNIS and all dogs and wolves work flawlessly

 

 

Share this post


Link to post

I was sure that deathhounds actually have no animations made because it was assumed that they would use the dog/wolf animation set. Apparently it isnt. I could be wrong but im pretty sure that's how it is.

Share this post


Link to post

Just gave the current build on git another try. The shaking effect at orgasm is a nice addition. However, can you restrict it to 1st person mode only? In 3rd person, being in the position of an incorporeal voyeur, it looks rather strange to me. And maybe add one or two more, but weaker camera shakes after the first one?

 

Custom key bindings don't get saved, they're back at their defaults after reloading a game.

 

Overall, looking great so far. :)

Share this post


Link to post

Hi ! Great Modder Ashal !

 

First, I'd like to thank you and all the people (if any) helping you for the SL Framework, it's really a great job and now Skyrim is really a 18+ game! 

 

That said, I think there is one really important thing missing in the framework : creatures' voices for sex animations ! I dunno if it has already been said but I had to tell you. Do you or anyone on the forums already plan on doing it ? 

Share this post


Link to post

Didn't have enough strength to read through the whole topic, so I hope I don't duplicate anything already written...

SSL would certainly benefit from female creatures animations. For now all creatures have animations done for female humanoids. But what about males? You can have a girl humped by a wolf, but what about a wolf humped by a guy?

Also what about creature on creature action? Not necessarily cross-species animations, but werewolf on werewolf, dragon on dragon, dog on dog...

Share this post


Link to post

ever stumbled across a thieve's or vampire's and wish you could make it your home? me too wish someone could make a mod that allows you to do just that 

Share this post


Link to post

Hi Ashal,

Please. I have a request. Hope this is the right place.  I would like to have a option in the sexlab configuration menu where i can choose filter a animation based on the PC role in the action, please let me elaborate.

While playing the mod "Devious Devices - Integration" , i came across the following situation: my female character was wearing a chastity belt and triggered a sexlab animation, which is "logically possible"  the PC being the "top" but not the other way around (cause the chastity belt).

The mod developer (@Min) thought about a "positional context awareness" but i would like to know if you can think a more elegant way to help him.

Thank you so much for your attention.

Share this post


Link to post

There are tags for each animation, mod authors can choose animations by tags, for example choose animations where there is no vaginal sex and has aggressive tag. I would agree on adding maybe another restrictive tag (NOT tag) but other than that it should be possible to filter nearly anything.

Share this post


Link to post

 

Custom key bindings don't get saved, they're back at their defaults after reloading a game.

 

Confirming that.  Thought I was going crazy, but any custom key bindings set are lost on the next load and revert to defaults.

 

An oddity with the 1st person mode in that the view tends to shift slightly periodically.  I can see in the script where you're linking the camera to the eyebone so my only guess is during each refresh cycle, the eye bone isn't in the same place it was during the last update.  Assuming the periodic shift is due to the registerforsingleupdate time period. 

 

Ashal: "As for the clipping, I don't know if there is a solution to that, I've tried just about everything I could there from a papyrus level, if you can find a way to reduce the clipping distance in C, than that should do the trick. "

 

Have been searching for an answer to this for some time myself.  Have yet to find anything that impacts near-distance clipping.  You would think a simple variable somewhere would set this, but be damned if I can find it. 

Share this post


Link to post

There are tags for each animation, mod authors can choose animations by tags, for example choose animations where there is no vaginal sex and has aggressive tag. I would agree on adding maybe another restrictive tag (NOT tag) but other than that it should be possible to filter nearly anything.

 

 

Sorry, I guess I did not explain right. The mod already uses the tags but it is not enough. Allow me to exemplify:

 

Two females trigger a sex animation, only one is wearing a chastity belt. Its a lesbian oral licking animation (so Oral tagged). It makes sense the girl wearing the chastity belt lick the other one, but not the other way around! This is only a example,  but there are dozens of cases.

 

I can not even disable the animation of my character being f*cked in the ass by a female npc without also disabling the opposite (deselecting the strap-on option only make it invisible) . You see, you cant filter by roles (who is "giving" or "receiving" the action). So I humbly ask for help.

Share this post


Link to post

 

Custom key bindings don't get saved, they're back at their defaults after reloading a game.

 

Confirming that.  Thought I was going crazy, but any custom key bindings set are lost on the next load and revert to defaults.

 

The development build reset hotkeys every time you load game, as I had some temporary code in there when I was testing a lot of hotkey stuff. I removed it a couple days ago however so it should be working normally now if you are using the newest build.

 

An oddity with the 1st person mode in that the view tends to shift slightly periodically.  I can see in the script where you're linking the camera to the eyebone so my only guess is during each refresh cycle, the eye bone isn't in the same place it was during the last update.  Assuming the periodic shift is due to the registerforsingleupdate time period.

The shift is it adjusting the angle to match the camera to the angle of the players head, it was put on a timer instead of included in the OnTranslationAlmostComplete() event in order to reduce script lag.

 

Doesn't matter now though, I've actually completely removed the first mode from the newest development build. h38fh2mf was able to get his SKSE based version of it working well, well enough that he's decided to release it as a seperate mod (available now from here: http://www.loverslab.com/files/file/491-immersive-first-person-view/). So rather than using my hacked in papyrus method for first person animations, I'm just going to point people towards his mod as a recommended addon. It performs better and more accurately replicates the intended effect.

 

Ashal: "As for the clipping, I don't know if there is a solution to that, I've tried just about everything I could there from a papyrus level, if you can find a way to reduce the clipping distance in C, than that should do the trick. "

 

Have been searching for an answer to this for some time myself.  Have yet to find anything that impacts near-distance clipping.  You would think a simple variable somewhere would set this, but be damned if I can find it.

It's irrelevant now since the use for it has been removed from recent builds; but already found a way adjust this, there's an ini setting under [Display] that affects this: fNearDistance

Share this post


Link to post

 

There are tags for each animation, mod authors can choose animations by tags, for example choose animations where there is no vaginal sex and has aggressive tag. I would agree on adding maybe another restrictive tag (NOT tag) but other than that it should be possible to filter nearly anything.

 

 

Sorry, I guess I did not explain right. The mod already uses the tags but it is not enough. Allow me to exemplify:

 

Two females trigger a sex animation, only one is wearing a chastity belt. Its a lesbian oral licking animation (so Oral tagged). It makes sense the girl wearing the chastity belt lick the other one, but not the other way around! This is only a example,  but there are dozens of cases.

 

I can not even disable the animation of my character being f*cked in the ass by a female npc without also disabling the opposite (deselecting the strap-on option only make it invisible) . You see, you cant filter by roles (who is "giving" or "receiving" the action). So I humbly ask for help.

 

Just press the swap positions hotkey to put them in the right positions, or if making a mod add the actors to the scene in the proper order of no belt then with belt, that way no belt ends up in female position and with belt ends up in male position.

 

Modders already have the ability to put actors in specific positions within an animation, it's up to the modders to actually use them, and if they don't use them then the user can make use of the swap positions hotkey.

Share this post


Link to post

 

 

There are tags for each animation, mod authors can choose animations by tags, for example choose animations where there is no vaginal sex and has aggressive tag. I would agree on adding maybe another restrictive tag (NOT tag) but other than that it should be possible to filter nearly anything.

 

 

Sorry, I guess I did not explain right. The mod already uses the tags but it is not enough. Allow me to exemplify:

 

Two females trigger a sex animation, only one is wearing a chastity belt. Its a lesbian oral licking animation (so Oral tagged). It makes sense the girl wearing the chastity belt lick the other one, but not the other way around! This is only a example,  but there are dozens of cases.

 

I can not even disable the animation of my character being f*cked in the ass by a female npc without also disabling the opposite (deselecting the strap-on option only make it invisible) . You see, you cant filter by roles (who is "giving" or "receiving" the action). So I humbly ask for help.

 

Just press the swap positions hotkey to put them in the right positions, or if making a mod add the actors to the scene in the proper order of no belt then with belt, that way no belt ends up in female position and with belt ends up in male position.

 

Modders already have the ability to put actors in specific positions within an animation, it's up to the modders to actually use them, and if they don't use them then the user can make use of the swap positions hotkey.

 

 

Thank you for your clarification

 

Share this post


Link to post

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


×