Ahnassi Posted January 22, 2021 Posted January 22, 2021 Will the features from Furniture Sex Framework be inplemented in future versions of Sexlab? 1
Noia do Rio De Janeiro Posted January 30, 2021 Posted January 30, 2021 On 1/22/2021 at 2:41 PM, Ahnassi said: Will the features from Furniture Sex Framework be inplemented in future versions of Sexlab? it's easier to ask if the mod is still wip or has already been finished
alranteesi Posted May 23, 2021 Posted May 23, 2021 hello guys, how many animations can register with sexlab se github version?
MadMansGun Posted May 24, 2021 Posted May 24, 2021 4 hours ago, alranteesi said: hello guys, how many animations can register with sexlab se github version? it will say in sexlab's MCM debug menu.
bnub345 Posted September 12, 2021 Posted September 12, 2021 Is there a way to pull the stage specific timers from Sexlab and utilize them in a script? For example something like 'let x = stage 5 timer, Utility.wait(x)'
Multirpg Posted September 12, 2021 Posted September 12, 2021 Hey there, started a playthrough, and since a few day only, when a sex scene start, the screen fades out like a loading screen, and the game crash, any idea?
MadMansGun Posted September 12, 2021 Posted September 12, 2021 2 hours ago, Multirpg said: Hey there, started a playthrough, and since a few day only, when a sex scene start, the screen fades out like a loading screen, and the game crash, any idea? try having sex inside.
Multirpg Posted September 12, 2021 Posted September 12, 2021 10 hours ago, MadMansGun said: try having sex inside. Inside a building? It happens too.
MadMansGun Posted September 12, 2021 Posted September 12, 2021 1 hour ago, Multirpg said: Inside a building? It happens too. then another mod is messing with sexlab.
Multirpg Posted September 12, 2021 Posted September 12, 2021 (edited) 50 minutes ago, MadMansGun said: then another mod is messing with sexlab. Okay so I tested. Removing the mods I installed didn't work. Buuuut. Using the cleaning feature in the sexlab menu did the trick. Since I get your attention. What did I do wrong for all animation to work backward? I am supposed to do all the fucking but the animation play as I am the one who is fucked, so it's sorta funny when I am fucked by a woman who gets no dick at all but it *the fun* is running thin real quick. Edited September 12, 2021 by Multirpg
Nymra Posted September 12, 2021 Posted September 12, 2021 (edited) 20 minutes ago, Multirpg said: Okay so I tested. Removing the mods I installed didn't work. Buuuut. Using the cleaning feature in the sexlab menu did the trick. Since I get your attention. What did I do wrong for all animation to work backward? I am supposed to do all the fucking but the animation play as I am the one who is fucked, so it's sorta funny when I am fucked by a woman who gets no dick at all but it *the fun* is running thin real quick. check in Sexlab MCM "women use strapons", get a futa mod, get cool strap on mods, get mods that replace women with men, configure the mods you use (where possible) to only uses males... you have options the plenty Edited September 12, 2021 by Nymra
Multirpg Posted September 12, 2021 Posted September 12, 2021 3 hours ago, Nymra said: check in Sexlab MCM "women use strapons", get a futa mod, get cool strap on mods, get mods that replace women with men, configure the mods you use (where possible) to only uses males... you have options the plenty They don't have strap on, they are "air fucking" ... The only futa mod I found is supposed to make all females futa and as such no thanks ... don't want to replace any gender, and I configured my mod so I am considered male, and active with both female and male ...
TDA Posted September 17, 2021 Posted September 17, 2021 (edited) In short, those who have problems with compiling SexLab should copy the scripts (source codes only) FNIS (new XXXL), and NiOverride.psc - the script (it is possible for LE). I wonder why the respected authors did not do this, as the simplest SDK? Edited September 17, 2021 by TDA
bonz69 Posted September 18, 2021 Posted September 18, 2021 HI guys in need some help!!! FNIS for users Behaviors Generated ? FNIS SexLabs Framework Idles ? FNIS Creature Pack 5.2+ ? FNIS sexlabs Creature Idles ? I'm using vortex to install ..please guide me what to do.
TDA Posted September 19, 2021 Posted September 19, 2021 21 hours ago, bonz69 said: HI guys in need some help!!! FNIS for users Behaviors Generated ? FNIS SexLabs Framework Idles ? FNIS Creature Pack 5.2+ ? FNIS sexlabs Creature Idles ? I'm using vortex to install ..please guide me what to do. it is not clear what you want to do. FNIS for users Behaviors Generated - just install new animations through the installer (I do this in WryeBash), then run GenerateFNISforUsers.exe , it will create a new behavior file with information about new animations , its all 1 2
TDA Posted September 22, 2021 Posted September 22, 2021 (edited) I have a question, how to get a reference of an arbitrary actor (suitable according to the conditions), from those who are in the loaded location? But, I roughly know how it works with aliases and it is very slow. I would like a way to get a reference instantly - on demand. What I mean is how it works in Oblivion - you just force the whole engine on its next work cycle - to execute your request (script) The same frame when the command arrived. Like that. Because - it's just impossible to wait so long (2-3 sec instead of 1-2 frames ) when the quest finally finds suitable actors Edited September 22, 2021 by TDA
Roggvir Posted September 22, 2021 Posted September 22, 2021 (edited) 1 hour ago, TDA said: I have a question, how to get a reference of an arbitrary actor (suitable according to the conditions), from those who are in the loaded location? But, I roughly know how it works with aliases and it is very slow. I would like a way to get a reference instantly - on demand. What I mean is how it works in Oblivion - you just force the whole engine on its next work cycle - to execute your request (script) The same frame when the command arrived. Like that. Because - it's just impossible to wait so long (2-3 sec instead of 1-2 frames ) when the quest finally finds suitable actors I don't remember how Oblivion works, and i don't understand what do you mean by "work cycle" in this context, but whatever that is, it doesn't sound like anything so low level is available in Skyrim. You can try to look at MiscUtil.ScanCellNPCs(), or the set of Game.FindClosestReferenceOf*() functions, or Game.FindRandomReferenceOf*(), Game.FindClosestActor(), or Game.FindRandomActor() I think there are basically three main methods, how to dynamically get nearby actors: The functions mentioned above (there may be others i forgot) Just be aware, that any functions that scan or search for things in given "cell", usually really just scan the given cell, meaning you can have an actor standing right next to you in a neighboring cell, and the function won't find it, and you may be scratching your head asking "why doens't it work, i see the actor right there?", not realizing the actor is actually in another cell. Cloak Spell Basically an AoE spell that applies some invisible non-hostile magic effect to actors nearby, and you can get the actors from the magic effect script. I don't remember in details, but if you do a bit of searching, you should find enough examples, if you don't already know how to do that. Quest Aliases Quest with an Alias (or several) to be filled with actor(s) at runtime based on some conditions. When you need an actor, you (re)start the quest, and check what ended up in those aliases. There will be some delay, but it should be bearable, way less than a second. Depending on your needs, the fastest will be probably one of those native functions. I never tried the ScanCellNPCs(), but even if it is fast, the problem its search seems to be limited to a given cell, may result in the process being a bit slower than expected, as you MAY need to find the neighboring cells and do the scan for them too, and then use the combined results to get the actor you want. But if you are in a situation, where it may be enough to search just the one cell, then i imagine this could be the quickest way (but i never tried it, so don't really know). And don't shy away from the others, like FindRandomActor(), as it is reasonably quick, and if it doesn't give you an actor you can use on first call, you can repeat the call few times to try and get a better result, and it may still get you some useful result faster (or not much slower) than any other method. I would probably use a combination of the functions above. Maybe first try FindRandomActor() just once, and if it gives a result you can use, great, you are done, and if not then depending on situation maybe try again, maybe try the ScanCelNPCs(), maybe combine results of ScanCelNPCs() of all neighboring cells, maybe try FindClosestActor() using the random actor position as the search center and see what that gets me, etc. Different situation may need a different combination, or different solution. Edited September 22, 2021 by Roggvir 2
TDA Posted September 23, 2021 Posted September 23, 2021 (edited) 6 hours ago, Roggvir said: I don't remember how Oblivion works, and i don't understand what do you mean by "work cycle" in this context, but whatever that is, it doesn't sound like anything so low level is available in Skyrim. You can try to look at MiscUtil.ScanCellNPCs(), or the set of Game.FindClosestReferenceOf*() functions, or Game.FindRandomReferenceOf*(), Game.FindClosestActor(), or Game.FindRandomActor() I think there are basically three main methods, how to dynamically get nearby actors: The functions mentioned above (there may be others i forgot) Just be aware, that any functions that scan or search for things in given "cell", usually really just scan the given cell, meaning you can have an actor standing right next to you in a neighboring cell, and the function won't find it, and you may be scratching your head asking "why doens't it work, i see the actor right there?", not realizing the actor is actually in another cell. Cloak Spell Basically an AoE spell that applies some invisible non-hostile magic effect to actors nearby, and you can get the actors from the magic effect script. I don't remember in details, but if you do a bit of searching, you should find enough examples, if you don't already know how to do that. Quest Aliases Quest with an Alias (or several) to be filled with actor(s) at runtime based on some conditions. When you need an actor, you (re)start the quest, and check what ended up in those aliases. There will be some delay, but it should be bearable, way less than a second. Depending on your needs, the fastest will be probably one of those native functions. I never tried the ScanCellNPCs(), but even if it is fast, the problem its search seems to be limited to a given cell, may result in the process being a bit slower than expected, as you MAY need to find the neighboring cells and do the scan for them too, and then use the combined results to get the actor you want. But if you are in a situation, where it may be enough to search just the one cell, then i imagine this could be the quickest way (but i never tried it, so don't really know). And don't shy away from the others, like FindRandomActor(), as it is reasonably quick, and if it doesn't give you an actor you can use on first call, you can repeat the call few times to try and get a better result, and it may still get you some useful result faster (or not much slower) than any other method. I would probably use a combination of the functions above. Maybe first try FindRandomActor() just once, and if it gives a result you can use, great, you are done, and if not then depending on situation maybe try again, maybe try the ScanCelNPCs(), maybe combine results of ScanCelNPCs() of all neighboring cells, maybe try FindClosestActor() using the random actor position as the search center and see what that gets me, etc. Different situation may need a different combination, or different solution. About my scene, I have two actors, when they are loaded into the game, their script passes their references to the quest to start the animation. I consider that an absolutely unnecessary action, but I don't know how else to transfer the reference of one actor to the script of another. Spoiler ReferenceAlias[] Property aActors Auto float fSpeed Event OnInit() fSpeed = 11 aActors[0].ForceRefTo(self) Utility.Wait(0.3) RegisterForUpdate(fSpeed) EndEvent Event OnUpdate() aActors[0].ForceRefTo(self) Utility.Wait(0.3) EndEvent but for some reason after the animation and the command aActors [0] .Clear () in the quest script, they don't fill themselves up again quickly - you have to wait a minute or two, it's just a nightmare This quest(if anyone has interest) it is not necessary to look at it Spoiler Scriptname AmQQQH1 extends Quest ReferenceAlias[] Property aActors Auto Float fSpeed SexlabFramework Property SexLab Auto Event OnInit() utility.wait(5) fSpeed = 13 RegisterForUpdate(fSpeed) utility.wait(5) EndEvent ;========================================================================= Event OnUpdate() ;========================================================================= float w = ww.GetValue() if w==0 if fSpeed!=13 utility.wait(5) fSpeed = 13 RegisterForUpdate(fSpeed) utility.wait(5) endif Actor npc1=aActors[0].GetActorReference() Actor npc2=aActors[1].GetActorReference() if npc2!=None && npc1!=None && npc1!=npc2 Actor Player=Game.GetPlayer() Cell pCELL =Player.GetParentCell() Cell aCELL =npc1.GetParentCell() Cell bCELL =npc2.GetParentCell() if pCELL==aCELL && aCELL==bCELL if (npc1.HasKeyWordString("SexLabActive"))==False if (npc2.HasKeyWordString("SexLabActive"))==False if npc1.IsInCombat()==0 && npc2.IsInCombat()==0 if npc1.IsDead()==0 && npc1.IsDisabled()==0 && npc2.IsDead()==0 && npc2.IsDisabled()==0 && npc1.GetSleepState()==0 && npc2.GetSleepState()==0 if npc1.IsSneaking()==0 && npc2.IsSneaking()==0 && npc1.IsWeaponDrawn()==0 && npc2.IsWeaponDrawn()==0 && npc1.IsSwimming()==0 && npc2.IsSwimming()==0 float r=Utility.RandomInt( 0, 100) if (Player.GetDistance(npc1))>111 || cmp(Player)==False actor[] sexActors = new actor[2] sexActors[0] = npc1 sexActors[1] = npc2 sslBaseAnimation[] anims Bed=SexLab.FindBed(npc1,768,none) if Bed!=None if SexLab.IsBedAvailable(Bed) SexLab.StartSex(sexActors, anims,none,Bed,true) else SexLab.StartSex(sexActors, anims) endif else SexLab.StartSex(sexActors, anims) endif elseif (Player.GetDistance(npc1))<111 && cmp(Player)==True actor[] sexActors = new actor[3] sexActors[0] = npc1 sexActors[1] = npc2 sexActors[2] = Player sslBaseAnimation[] anims Bed=SexLab.FindBed(npc1,768,none) if Bed!=None if SexLab.IsBedAvailable(Bed) SexLab.StartSex(sexActors, anims,none,Bed,true) else SexLab.StartSex(sexActors, anims) endif else SexLab.StartSex(sexActors, anims) endif endif ;aActors[0].Clear() ;aActors[1].Clear() ww.SetValue(1) utility.wait(35) ww.SetValue(0) endif endif endif endif endif endif endif endif EndEvent bool Function cmp (Actor inpc) if (inpc.HasKeyWordString("SexLabActive"))==False && inpc.GetSleepState()==0 if ( inpc.IsInCombat()==0) && (inpc.IsDead()==0) &&( inpc.IsDisabled()==0) && (inpc.IsSneaking()==0) && ( inpc.IsWeaponDrawn()==0) &&( inpc.IsSwimming()==0) RETURN true endif endif RETURN false EndFunction MiscObject Property gg Auto VisualEffect Property ve1 Auto GlobalVariable Property ww Auto ObjectReference Property Bed Auto ...................................... It is also interesting if the papyrus has purely physical functions - imitation of body movement along a ballistic trajectory - like from a cannon and the like. I myself am reluctant to remember and write all this ... Edited September 23, 2021 by TDA
Roggvir Posted September 23, 2021 Posted September 23, 2021 (edited) 6 hours ago, TDA said: About my scene, I have two actors, when they are loaded into the game, their script passes their references to the quest to start the animation. I consider that an absolutely unnecessary action, but I don't know how else to transfer the reference of one actor to the script of another. Reveal hidden contents ReferenceAlias[] Property aActors Auto float fSpeed Event OnInit() fSpeed = 11 aActors[0].ForceRefTo(self) Utility.Wait(0.3) RegisterForUpdate(fSpeed) EndEvent Event OnUpdate() aActors[0].ForceRefTo(self) Utility.Wait(0.3) EndEvent but for some reason after the animation and the command aActors [0] .Clear () in the quest script, they don't fill themselves up again quickly - you have to wait a minute or two, it's just a nightmare This quest(if anyone has interest) it is not necessary to look at it Hide contents Scriptname AmQQQH1 extends Quest ReferenceAlias[] Property aActors Auto Float fSpeed SexlabFramework Property SexLab Auto Event OnInit() utility.wait(5) fSpeed = 13 RegisterForUpdate(fSpeed) utility.wait(5) EndEvent ;========================================================================= Event OnUpdate() ;========================================================================= float w = ww.GetValue() if w==0 if fSpeed!=13 utility.wait(5) fSpeed = 13 RegisterForUpdate(fSpeed) utility.wait(5) endif Actor npc1=aActors[0].GetActorReference() Actor npc2=aActors[1].GetActorReference() if npc2!=None && npc1!=None && npc1!=npc2 Actor Player=Game.GetPlayer() Cell pCELL =Player.GetParentCell() Cell aCELL =npc1.GetParentCell() Cell bCELL =npc2.GetParentCell() if pCELL==aCELL && aCELL==bCELL if (npc1.HasKeyWordString("SexLabActive"))==False if (npc2.HasKeyWordString("SexLabActive"))==False if npc1.IsInCombat()==0 && npc2.IsInCombat()==0 if npc1.IsDead()==0 && npc1.IsDisabled()==0 && npc2.IsDead()==0 && npc2.IsDisabled()==0 && npc1.GetSleepState()==0 && npc2.GetSleepState()==0 if npc1.IsSneaking()==0 && npc2.IsSneaking()==0 && npc1.IsWeaponDrawn()==0 && npc2.IsWeaponDrawn()==0 && npc1.IsSwimming()==0 && npc2.IsSwimming()==0 float r=Utility.RandomInt( 0, 100) if (Player.GetDistance(npc1))>111 || cmp(Player)==False actor[] sexActors = new actor[2] sexActors[0] = npc1 sexActors[1] = npc2 sslBaseAnimation[] anims Bed=SexLab.FindBed(npc1,768,none) if Bed!=None if SexLab.IsBedAvailable(Bed) SexLab.StartSex(sexActors, anims,none,Bed,true) else SexLab.StartSex(sexActors, anims) endif else SexLab.StartSex(sexActors, anims) endif elseif (Player.GetDistance(npc1))<111 && cmp(Player)==True actor[] sexActors = new actor[3] sexActors[0] = npc1 sexActors[1] = npc2 sexActors[2] = Player sslBaseAnimation[] anims Bed=SexLab.FindBed(npc1,768,none) if Bed!=None if SexLab.IsBedAvailable(Bed) SexLab.StartSex(sexActors, anims,none,Bed,true) else SexLab.StartSex(sexActors, anims) endif else SexLab.StartSex(sexActors, anims) endif endif ;aActors[0].Clear() ;aActors[1].Clear() ww.SetValue(1) utility.wait(35) ww.SetValue(0) endif endif endif endif endif endif endif endif EndEvent bool Function cmp (Actor inpc) if (inpc.HasKeyWordString("SexLabActive"))==False && inpc.GetSleepState()==0 if ( inpc.IsInCombat()==0) && (inpc.IsDead()==0) &&( inpc.IsDisabled()==0) && (inpc.IsSneaking()==0) && ( inpc.IsWeaponDrawn()==0) &&( inpc.IsSwimming()==0) RETURN true endif endif RETURN false EndFunction MiscObject Property gg Auto VisualEffect Property ve1 Auto GlobalVariable Property ww Auto ObjectReference Property Bed Auto ...................................... It is also interesting if the papyrus has purely physical functions - imitation of body movement along a ballistic trajectory - like from a cannon and the like. I myself am reluctant to remember and write all this ... Are those actors realy "random"? you, or your scene doesn't know who those actors will be? They aren't part of some other quest where you could grab them from, or some other scene, or script, etc? (for example, if this scene is for player having sex with his followers, then obviously, the best way to get those followers would be to grab them from the appropriate follower quest scripts, depending on follower framework in use, etc.) But if you really need to use the quest method to get these actors... After you call Clear() on the aliases, do you stop the quest and start it again? (you should). Make the conditions for filling the aliases as simple as possible, while still providing the required limitations, but also consider your situation and place the conditions in an optimal order, so the conditions at the beginning of the stack exclude as much actors as possible, resulting in less work for the next condition below, and so on. For example, let's say you have these conditions: 1. actor must be NPC 2. actor must be male 3. actor must NOT be member of SexLab Animating faction The order above is already the most optimal way how to stack these three conditions, but imagine you'd reverse the order (which would then be the least optimal) - do you see why? surely you do, anyway i am too lazy to explain that Consider how expensive each condition might be (hard to say, but even guessing may get you somewhere), and try to place the more expensive conditions at the end of the stack - for example, checking for something in actor's inventory is probably more expensive than checking if actor has a keyword, so place the keyword condition before the inventory conditions, so the more expensive inventory condition has as few actors to work with as possible. Consider using a special quest dedicated to nothing else but this purpose, with no scripts attached to it, or just a very simple script with nothing but OnInit that sends even/calls function to let you know the aliases have been filled, or attach the script to the aliases instead, depending on what's more convenient, but try to minimize any code in those scripts (or avoid any scripts if you can), so there is as little as possible to slow down the restarting of the quest. Try giving that quest a high priority, maybe it will cause it to get (re)started sooner. But do you really need a quest filling aliases at runtime to get these actors? Your description isn't detailed enough for me to know for sure, but it seems that those actors are not an UNKNOWN to you - you mentioned "their script passes their references to the quest", which sounds like actually the best solution which should be fast, unless ...i don't know what. Can you describe in more detail, where exactly do those actors come from, how they end up being where they are, and why is it them that your scene is using? What you wrote implies intent to use those particular actors, so they must be a known variable - can't you just place them into your quest aliases right from the start, to put them into the aliases from Creation Kit? or is there a reason why you can't / don't want to do that? By the way, this code is a bit unwieldy and you make it more complicated than it needs to be: if npc1.IsInCombat()==0 && npc2.IsInCombat()==0 if npc1.IsDead()==0 && npc1.IsDisabled()==0 && npc2.IsDead()==0 && npc2.IsDisabled()==0 && npc1.GetSleepState()==0 && npc2.GetSleepState()==0 if npc1.IsSneaking()==0 && npc2.IsSneaking()==0 && npc1.IsWeaponDrawn()==0 && npc2.IsWeaponDrawn()==0 && npc1.IsSwimming()==0 && npc2.IsSwimming()==0 ...as far as i know, almost all those functions return boolean, and i could be wrong, but i don't think the Papyrus compiler is smart enough to fix the mess you made, so it will probably cast every zero to boolean before doing the comparison, or it will cast the result of the function to int, one or the other - it isn't a big deal, but why make things harder than they need to be? It will be even more readable, if you write it like this: if npc1.IsInCombat() || npc1.IsDead() || npc1.IsDisabled() || npc1.GetSleepState() != 0 || npc1.IsSneaking() || npc1.IsSwimming() \ || npc2.IsInCombat() || npc2.IsDead() || npc2.IsDisabled() || npc2.GetSleepState() != 0 || npc2.IsSneaking() || npc2.IsSwimming() return endIf ; here do whatever you were doing inside your original IF block In general, get rid of all those AWULL nested IF blocks. That is absolutely horrid, it makes your code harder to read, you end up avoiding identation as you do, and the result is a horrible mess. I am sorry if it sounds harsh, i am not trying to be mean to you, just ...it's really awful habit, get rid of it. Just use return to abort the function/event block if your conditions aren't satisfied, and don't be shy using several of such blocks if you need to check 200 conditions like you do. A better readable code is way more important than "wasting" absolutely negligible amount of processing time by adding two more if-return blocks like that. Do not use RegisterForUpdate() Use RegisterForSingleUpdate() instead, and alter any of your scripts accordingly (re-registering for single updates if needed, etc.). Reason for that is explained here (scroll down until you find "Important Warning"). Do NOT wait inside OnInit() like you do: Event OnInit() utility.wait(5) fSpeed = 13 RegisterForUpdate(fSpeed) utility.wait(5) EndEvent The main reason why NOT to do that (described here) is: Quote Until OnInit has finished running, your script will not receive any events, and other scripts that try to call functions or access properties on your script will be paused until the event finishes. The only exceptions are when the functions are being called from another script inside its OnInit event, or inside a property set function being set by the master file. As a result, it is generally not advisable to fill your OnInit event with a large amount of processes. It is safer and more reliable to allow your OnInit to finish running while only performing minor tasks, and defer other larger activities to an update (as in the example above) or something similar. Why do you even do that? What is your reason to put that wait inside the OnInit() ? I guarantee you, that this is the hands down worst possible way to do, whatever it is you want to do. This is probably also the reason why your quest script is taking weirdly long time to do anything - you are effectively delaying the quest start by 10 SECONDS just inside that OnINit(), and you set the update interval at 13 seconds, so the OnUpdate gets to run after no less than 18 seconds after the quest started! No wonder it takes time to restart the quest ? And this following block at the beginning of the OnUpdate event handler block is mighty stinky too if fSpeed!=13 utility.wait(5) fSpeed = 13 RegisterForUpdate(fSpeed) utility.wait(5) endif You know it never does anything right? The code inside NEVER runs, because fSpeed in your script is set to 13 inside OnInit(), and the value is never changed for as long as the script runs. But that is probably a good thing, because surely after delaying the OnUpdate for 18 seconds, you wouldn't want to add yet another 10 on top of that Maybe we can fix this, but what exactly are you trying to do? Edited September 23, 2021 by Roggvir 1
Roggvir Posted September 23, 2021 Posted September 23, 2021 2 hours ago, TDA said: About my scene, I have two actors, when they are loaded into the game, their script passes their references to the quest to start the animation. I consider that an absolutely unnecessary action, but I don't know how else to transfer the reference of one actor to the script of another. Reveal hidden contents ReferenceAlias[] Property aActors Auto float fSpeed Event OnInit() fSpeed = 11 aActors[0].ForceRefTo(self) Utility.Wait(0.3) RegisterForUpdate(fSpeed) EndEvent Event OnUpdate() aActors[0].ForceRefTo(self) Utility.Wait(0.3) EndEvent What is this script? Where is it attached? You didn't include the first line that would make that clear. Is that script extending ObjectReference, attached to an actor? Or is it some ReferenceAlias script on some other quest? or... on the same quest?????? We need to know to tell you how to fix it, or if there is a better way to do this. Anyway, what is with the Wait() again? btw. holy crap, you are registering for an update interval and you never stop it? You are forcing the same actor into the alias again after 0.3 seconds, and everytime you do that, the alias probably gets "reset", trigering the OnInit again, registering for update again, and repeating the same thing again in 0.3 seconds, and then again, and then again, and then again, and then again, and then again, and then again, ... This is very bad thing to do. Not just because of the never ending update chain, but also because repeating ForceRefTo() in rapid succession can mess up actor's packages (see the Notes here) - you mentioned the word scene, but i guess you meant a "scene" in general, not The Scene, but even so, you should be carefull, and what you are doing is unnecessary and wrong anyway. So, the important thing to know is - what is this script, how is it attached to the actor? Then we can talk about how to fix it, or whether there may be a better way entirely.
Roggvir Posted September 23, 2021 Posted September 23, 2021 3 hours ago, TDA said: ... Here is what i think you need. (just keep in mind, i didn't actually tried any of the code in game, there can be mistakes and typos, etc., no guarantees, take this as a rough draft of how you should go about it) First, the quest script: It wasn't 100% clear as to what you are trying to do, but i assumed you just want to keep repeating a scene, maybe with a delay in between. The script uses states to prevent the scene code (that you had in OnUpdate) to run before last scene finished. The script won't do much on its own - you need some OTHER script to actually get the OnUpdate() rolling on the quest script. The idea was that the OTHER script should in its initialization (maybe in its OnInit) register for a mod event "AmQQQH1_READY" which will be sent by the quest script everytime its ready to run a scene - when the event is received by the OTHER script, it should feed the actors into the quest script, and register the quest script for Update(s) (i didn't fleshed out that part much, as i didn't know what the OTHER script is supposed to be, or if there is to be one - maybe there is a better way to do this, but we won't know until you provide more details). Spoiler Scriptname AmQQQH1 extends Quest referenceAlias[] property aActors auto SexlabFramework property SexLab auto ; Assuming the 'ww' global variable was intended to be used as a 'thread lock', ; preventing the OnUpdate from running before the last run scene had time to finish, ; i took the liberty to use script states for that purpose instead. ;globalVariable property ww auto keyword SexLabActive = none actor Player = none event OnInit() if IsRunning() SexLabActive = Keyword.GetKeyword("SexLabActive") Player = Game.GetPlayer() GotoState("READY") else GotoState("WHATEVER") endIf endEvent event OnUpdate() endEvent event TheSexThingEnded(int tid, bool HasPlayer) endEvent state READY event OnBeginState() SendModEvent("AmQQQH1_READY") endEvent ;========================================================================= event OnUpdate() ;========================================================================= ; Assuming the 'ww' global variable was intended to be used as a 'thread lock', ; preventing the OnUpdate from running before the last run scene had time to finish, ; i took the liberty to use script states for that purpose instead. ;if ww.GetValue() != 0 ; return ;endIf GotoState("BUSY") endEvent endState state BUSY event OnBeginState() RegisterForModEvent("HookAnimationEnd_AmQQQH1", "TheSexThingEnded") if !DoTheSexThing() GotoState("READY") endIf endEvent event OnEndState() ; This event handler will run when we use GotoState() to switch to some other state, ; like we do above if the scene fails to run (DoTheSexThing() returns false), ; or like we do after we receive event from SexLab telling us the scene is finished. ; IF you want to do some cleanup after the scene, or if the scene failed to run, ; maybe remove the actors from aliases, etc., here could be a good place to do that. ; At the very least, we should unregister the SexLab mod event. UnregisterForModEvent("HookAnimationEnd_AmQQQH1") endEvent event TheSexThingEnded(int tid, bool HasPlayer) ; Event we receive from SexLab when the animation ends. ; We just switch back to the READY state, which makes the quest script available for ; another scene. ; If you want to run some cleanup code, put it into the OnEndState. GotoState("READY") ;sslThreadController Thread = SexLab.GetController(tid) ;actor[] actors = Thread.Positions ;[firstActor, secondActor] endEvent endState bool function DoTheSexThing() ; I added check to make sure the Player is also not active in some SexLab scene. ; Not sure if needed - if at this point you already KNOW player isn't in SL scene, ; you can remove this check if SexLabActive != none && Player.HasKeyword(SexLabActive) return false endIf actor npc1 = aActors[0].GetActorReference() actor npc2 = aActors[1].GetActorReference() if npc2 == none || npc1 == none || npc1 == npc2 return false endIf cell pCell = Player.GetParentCell() if pCELL != npc1.GetParentCell() || pCell != npc2.GetParentCell() return false endIf if !ValidActor(npc1) || !ValidActor(npc2) return false endIf int slThreadId = -1 actor[] sexActors if Player.GetDistance(npc1) < 111 && ValidActor(Player) sexActors = new actor[3] sexActors[2] = Player else sexActors = new actor[2] endif sexActors[0] = npc1 sexActors[1] = npc2 sslBaseAnimation[] anims objectReference Bed = SexLab.FindBed(npc1, 768, none) if Bed != none && SexLab.IsBedAvailable(Bed) slThreadId = SexLab.StartSex(sexActors, anims,none,Bed,true,"AmQQQH1") else slThreadId = SexLab.StartSex(sexActors, anims,none,none,true,"AmQQQH1") endif ; Assuming the 'ww' global variable was intended to be used as a 'thread lock', ; preventing the OnUpdate from running before the last run scene had time to finish, ; i took the liberty to use script states for that purpose instead. ; IN ANY CASE, THAT WAIT HAS NO BUSINESS BEING HERE ANYMORE ; - IF you need to add somedelay before the next scene can run, just add a DELAY state, ; switch to it, in it's OnBeginState register for SINGLE update with the delay you want, ; and then from the OnUpdate handler placed inside that state, issue GotoState("READY"). ;ww.SetValue(1) ;Utility.Wait(35) ;ww.SetValue(0) return (slThreadId > -1) endFunction bool function ValidActor(actor inpc) if SexLabActive != none && inpc.HasKeyword(SexLabActive) return false elseIf (inpc.GetSleepState() != 0) || inpc.IsInCombat() || inpc.IsDead() || inpc.IsDisabled() || inpc.IsSneaking() || inpc.IsWeaponDrawn() || inpc.IsSwimming() return false endIf return true endFunction Now, the other script... You need to tell us more, i just don't know how you are gettign the actors, where d othey come from, how they ended up being there, what is that OTHER partial script you posted which was trying to feed the actors to the quest script, etc.
TDA Posted September 23, 2021 Posted September 23, 2021 (edited) 3 hours ago, Roggvir said: What is this script? Where is it attached? So, the important thing to know is - what is this script, how is it attached to the actor? That short script on the participants themselves, they send themselves to the alies of the quest. (and by the way, by scene I mean just script triggering and animation (in a broad sense), and not what is in the constructor - I don’t use that. ) ЭThese are just two actors on the beach, if you get close to them, then the player will become a participant in the animation - that's all. Э But you can just watch them, these are the actions of the environment for hot springs. Because there are no such mods and frameworks (loke Lovers Joburg), where the framework itself looks for participants for animation. You either have to talk to someone or be aggressive - this is annoying But the question about random participants is a reserve for the future, so that this quest script can be used for other actors. Those. since I did not find a better way than with a quest, I decided to make it universal. ///////////////////////////////// Thanks also for the detailed explanations, while I need to translate everything and understand what you have written. Actually my scene works without problems, but it takes a very long time to update - it annoys me. Edited September 23, 2021 by TDA
TDA Posted September 27, 2021 Posted September 27, 2021 (edited) how can I take all the number of registered animations and then select one specific one (randomly by index) so that this is started? why? because - this structure - actor[] sexActors = new actor[2] sexActors[0] = off sexActors[1] = def sslBaseAnimation[] anims does not work for random (in SE, in LE - it works) Edited September 27, 2021 by TDA
Guest Posted October 4, 2021 Posted October 4, 2021 (edited) I'm probably just retarded and can't read, and apologies if this is not the right place to ask, but question: Is there a way to disallow female characters from partaking in a MF scene? I'm trying a lebian run without futa (this time), but all to often female NPCs will start dry-humping me with invisible strap-ons. I thought that by disabling strap-ons I would be more non-dick scenes, but it didn't. SexLab Tools scene changer will only let me swap between MF tagged scenes when the invisible dildo comes out, so there isn't really a way for me to ignore it. I'm not dissing strap-on use, I just wanted to make more female on female sans penis scenes happen. Edited October 4, 2021 by dovahnurse accidentallly made a quote post instead of edit. Fixed that.
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now