Jump to content

How to figure out if an Actor is in a SexLab animation


Recommended Posts

I'm wondering if Actors get added to a faction/something to that effect when they are engaged in a SexLab animation. I only ask because I've been developing TDF Prostitution and Pimping, and one important aspect of the mod is that the player should not be able to offer a client the services of a prostitute while the prostitute is still engaging in an animation with another Actor. So, I'd like to find a way to determine whether the prostitute is engaged in an animation already or not. Currently, I'm indirectly solving this issue with sufficient success (by having the prostitute cast a spell that lasts 150 seconds on herself as the animation begins), but it has occurred to me that this solution will be insufficient for any user who has tweaked the length of the animations with the MCM menu. Any help would be appreciated.

Link to comment

They get added to the faction "SexLabAnimatingFaction" as well as get the keyword "SexLabActive" added to them.

 

Either one should be suitable for your needs.

 

The script SexLabFramework has the faction as a property if you need it, so a simple ActorRef.IsInFaction(SexLab.AnimatingFaction) should be the easiest way.

 

Likely unneeded, but within the SexLabAnimatingFaction you can also check if they are actively animating, or just "preparing" to animate (stripping and such). At faction rank 0, they are just added to an animation and are getting ready, at faction rank 1 they are actively being animated. The time frame between this is short however, seconds at most, so 99.9% likely that just checking for existence of the faction or keyword will be all you need.

 

 

Link to comment

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

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