Jump to content

SexLab Framework Development


Recommended Posts

 

 

Damn, NSAP really is the culprit for those control override issues. I removed it and everything's ok, but I straight up can't live without those animations. Oh well, just gonna have to wait for the official release.

 

 

Hello. @rydin is working on NSAP 3.0, that will be compatible with SL 1.6

Just keep in mind that also SL 1.6 is not yet ready, and @rydin has some personall things to handle this week.

 

Just keep calm and enjoy LoversLab.  ;)

 

 

Yeah, no problem waiting. Just running Payday 2 right now to keep busy, it's still fun checking in on a weekly basis or so to see what you guys've been up to.

 

Link to comment

Most of the NSAP animations are already included in SL1.6.  Mainly the furniture animations, the 2 Rydin animations, and only a few of the more recent animations are missing.  I was still using NSAP with 1.6 and never saw this issues you are seeing (no issue with the "jump" spacebar, nor the "reverse direction" issue).  Recently I went and modified the text file with NSAP that FNIS uses when running the Generator to remove the redundant animations so they wouldn't appear as duplicates.  You just have to make sure not to select any of the removed entries when selecting the animations in the NSAP MCM.  it was easy for me - I removed everything except the 5 dildo animation references.  The file is located here:  ..\meshes\actors\character\animations\NonSexLabAnimationPack\FNIS_NonSexLabAnimationPack_List.txt.  I made a copy of the original before editing it - rename the copy's extension to something other than .txt so that FNIS will not try to use this and the modified one (changed mine to ".bu").  The format is fairly straight-forward, with the animations grouped together by artist (in most cases), and the entries named with approximately the name of the animation (some make take some interpretation).

 

Again, I never saw any of the issues you guys were seeing, so this modification may not work for you.

 

There are quite a few new, really well made animations missing from SL RC2. I dont believe these modifications dont work for us, it is just that were not as experienced as some of the more advanced modders/mod users on here (yourself included) so we just need to relentlessly try to find out what may be wrong since it is most likely not a SL issue but a local issue with us.

 

I am trying to follow what you've advised but it may take a bit to comprehend.

 

Thanks for the tip though.

Link to comment

 

Bah, I'm a fucking idiot. Pretty sure I found the problem.

void Values<T, S>::SaveStream(std::stringstream &ss) {
		if (Data.size() < 5) return;

For some idiotic reason it's only saving the types value data if it has 5+ objects with values. Not sure what the hell I was thinking there. The list types data's save function on the other hand actually does the much more sensible Data.size() == 0 check.

 

This version should fix it: 

 

 

New version works, thanks!

 

 

Link to comment

should i download it now and replace in my RC2?

 

Sure, it's not going to hurt. But it's not necessarily guaranteed to solve anybodies problem in particular either.

 

It shouldn't effect anybody to much who are using "older" saves, as they are likely going to have enough saved up data to prevent it from discarding the data on save. But if you are on a relatively new save, or have experienced problems related to settings, such as player voice not saving, or other minor issues of data not saving between save/load, than it may likely solve that issue.

 

---

 

I'll likely be releasing the "seriously actually final this time" RC3 later today/tomorrow in any case, which will include this fix in it. And if I don't release the official 1.60 by the end of the week, for the love of god somebody chastise me for it. It's been more or less ready for months at this point, all these beta's and release candidates could have easily be fixes made in 1.61+ instead so modders could get a move on and start using the new API functions or fix any non-backwards compatible mods.

Link to comment

Also, do any modders or well informed people know WHY I wanted to remove "Game.SetPlayerAIDriven()" in 1.60? It mustn't had some problem with it that lead to me commenting it out 5+ months ago.

 

I have no idea myself, but I could swear I had a good reason for it in favor of using just Game.DisablePlayerControls(). Adding SetPlayerAIDriven back in like it was in 1.59c will fix the issue a few users have had with jumping when advancing stages with space bar. But I just can't for the life of me decide why I was convinced so many months ago that I felt comfortable saying "screw those people, it's not worth it." and just removed the line.

 

I've had the line added back in for a few days now and have been testing a lot, but haven't found any obvious issues resulting from using SetPlayerAIDriven to help further enforce locked player movement  to help re-remember the reason I disabled it to begin with... 

 

Anybody with any idea why I might have felt the need to remove it? Or was I just being stupidly stuck back on the idea that I had to remove all seemingly useless/overkill coding from the mod? 

Link to comment

Maybe to allow conversation? If you disable player controls you get a finer grain control which can allow activation while stopping them moving or fighting. Which isn't without its complications of course

 

That might be it, and fitting you're the one to make that suggestion as I do semi-recall now several people mentioning Sexrim using dialog mid animation for controlling the scene, and thinking that would be something neat to support, or at the very lease allow for another mod to implement in some way.

 

A "unified sexlab dialog api" was also an early feature on the planning board for 1.60, which might have been the final reason that lead to it. That feature obviously hasn't made it into 1.60 though, and now I'm not so sure the trade off of allowing dialog during animation is worth it.

Link to comment

I just noticed the other day that I could talk to my partner, which I wasn't expecting. So that made me wonder.

 

It'd be nice to have, but thinking about it. there's no reason the modder shouldn't hook the animation start, disable controls, unset AI driven and do it that way. Of course, then it's the modders responsibility to put it all back again at the end.

Link to comment

Quick question...

 

 

Has the code from SexLab HDT High heels been included?  or does it need to be installed separately?

 

HDT High Heels is in no way a dependency in SexLab.

 

If you do happen to have it installed, SexLab will default to enabling the option to remove the heel's height effect during animation, which you can then toggle on or off depending on preference. Or you can safely completely ignore it if you don't have HDT-HH installed.

Link to comment

Just trying out the latest build pulled from git (15992) in a coc game.

 

I'm still seeing the issue of the animation hotkeys failing to respond - possibly after rapid transition forward between stages. The animation then becomes stuck in the last stage and can only be ended using the Stop All option in the MCM.

 

Log attached. The stuck animation was the last involving the PC (Prisoner/Horse).

Papyrus.0.log

Link to comment

 

Quick question...

 

 

Has the code from SexLab HDT High heels been included?  or does it need to be installed separately?

 

HDT High Heels is in no way a dependency in SexLab.

 

If you do happen to have it installed, SexLab will default to enabling the option to remove the heel's height effect during animation, which you can then toggle on or off depending on preference. Or you can safely completely ignore it if you don't have HDT-HH installed.

 

 

ok that was my question.  if sexlab framework would remove the HDT heels for me, or if I needed that mod that removed them as well.

 

Link to comment

From what I've read on the past few pages it would appear my issues correlate with the spacebar/reversing animations issues only occurring with NSAP animations.

Not sure if it's SL but when I press N to control a proxy animation with two NPC actors my character just jumps instead of advancing stages. This happened during this session with only two NPCs. Otherwise works fine.

 

I had enabled all NSAP animations except furniture and didn't think of it until FNIS spat out the duplicate errors.

 

Command console logs show that newer animations cause the issues but not the old and trusted ones i.e. SL integrated animations.

 

Is it at all possible to reverse animation stages up to the beginning of the foreplay event too or just the main business? I've noticed I cannot reverse stages past the first animation of the main phase if NSAP was used for foreplay. That might be the cause or I've never noticed if that was possible at all.

 

Otherwise RC2 seems to behave well and all CTDs/hangs are related to cloak scripts/script overload instead (or Skyrim itself).

 

My papyrus log revealed some issues with other unrelated plugins though, posting just in case. Papyrus.0.log.7z

Link to comment

Quick question what is the sexlab creature pack and do i need itz if am useing the more nasty creatures mod alrady ?

 

Quick answer: the creature pack is what has the creature animations and creature support in it. With the new release it will be a seperate download, therefor not included in SexLab itself. So if you want to see/use creature animations then yes, you will need to download and install it.

 

Link to comment

Found 1 non-critical issue.  When I activate SexLab 1.60RC2 on a new save, the info in the MCM is at default (as it should be) with creature animations turned off.  If I then Import saved settings (whether old settings from 1.59c, or new settings specifically saved with 1.60RC2) which has the creature animations on, the animations do not appear in the creature animation list.  Closing the MCM and menus to the game and wait - they never activate.  They will not activate until I uncheck then recheck the creature animation activation in the MCM (leaving the MCM and waiting for the completion confirmation).  Then I have to import the settings again for them to take effect on the individual creature animations.  Again, non-critical because I can activate creature animations after SexLab is activated.  Once activated, I can then import the saved settings and the individual creature animations are enabled/disabled appropriately.

Link to comment

Feature request:

 

Unregister specific animations (opposite of sslAnimationFactory.RegisterAnimation(string) )

It's a bit of a pain to reset all animations to update just one.

I'm not sure it'd be a good idea. The animation searching and registering animations are both reliant on using the number of currently registered animations as it's starting loop point or next available slot. So to keep that I'd accurate I'd have to shift all animations in the registry that come after up one slot to fill in the gap, and possibly break things for any mods that might be storing info on those shifted animations based on their slot id number.

 

You should be able to re-register animations fairly simply as is.

; // Save the registry and slot IDs
int SaveSlotID      = Animation.SlotID
string SaveRegistry = Animation.Registry
; // Reset the animations data
Animation.Initialize()
; // Set the IDs name again since initialize clears it
Animation.SlotID   = SaveSlotID
Animation.Registry = SaveRegistry

; // Animation is empty now, you can now manually call the original registration event/function used to make it, by passing it the SlotID
; // Or just manipulate the animation object from here however you want, just be sure to call Animation.Save(SlotID) afterwards to finalize.

The only reason to do this though would be to alter some of the position data, you can edit pretty much everything else about an animation however you want after it's been registered already.

 

 

 

 

Hook-issue:

 

Log:

 

 

SexLab MCM Loaded CurrentVerison: 15992 / 15992

SEXLAB - LOADED: Version 15992 / 15992
[snip]
[PAHESex] punish([Actor < (FF001062)>], [Actor < (00000014)>], Vaginal, True, )
SEXLAB - Thread[0]  - Entering Making State
[PAHESex] Male PC
SEXLAB - NOTICE: ValidateActor(Vigilant of Stendarr) -- TRUE -- MISS
SEXLAB - ActorAlias[Vigilant of Stendarr] SetActor([Actor < (FF001062)>]) - [sslActorAlias <alias ActorAlias004 on quest SexLabThread00 (0D061EEF)>]
SEXLAB - NOTICE: ValidateActor(Bla) -- TRUE -- HIT
SEXLAB - ActorAlias[Bla] SetActor([Actor < (00000014)>]) - [sslActorAlias <alias ActorAlias003 on quest SexLabThread00 (0D061EEF)>]
[PAHESex] Setting endAnim
[PAHESexScript]: PAHEEstrusTrauma
SEXLAB - ActorAlias[Vigilant of Stendarr]  - Voice[FemaleEvenToned (Lydia)] Expression[angry] BaseEnjoyment[0]
[Zad]: Set slot mask to [0]: 0
SEXLAB - ActorAlias[Bla]  - Voice[MaleEvenToned (Dovahkiin)] Expression[Sad] BaseEnjoyment[5]
SEXLAB - Thread[0] Event Hook - AnimationStart
[Zad]: OnAnimationStart()
[slnc] [slncMainQuestScript <slncControllerQuest (980110DF)>]: OnSexLabAnimationStart(AnimationStart, 0, 0.000000, [sslthreadcontroller <SexLabThread00 (0D061EEF)>]) Begin
[Zad]: No sex-act-restricted actors present in this sex scene. Done.
SEXLAB - Thread[0] Event Hook - StageStart
SEXLAB - Thread[0] Event Hook - StageEnd
SEXLAB - Thread[0] Event Hook - StageEnd
SEXLAB - Thread[0] Event Hook - StageStart
SEXLAB - Thread[0] Event Hook - StageEnd
SEXLAB - Thread[0] Event Hook - OrgasmStart
SEXLAB - Thread[0] Event Hook - StageStart
SEXLAB - ActorAlias[Vigilant of Stendarr]  - Orgasms[1] Enjoyment [11] BaseEnjoyment[-52]
SEXLAB - ActorAlias[Bla]  - Orgasms[1] Enjoyment [13] BaseEnjoyment[-52]
SEXLAB - Thread[0] Event Hook - OrgasmEnd
SEXLAB - Thread[0] Event Hook - AnimationEnding
[slainternalscr <sla_Internal (0E083137)>]: Vigilant of Stendarr had orgasm date updated
SEXLAB - ActorAlias[Bla]  - Resetting!
[slainternalscr <sla_Internal (0E083137)>]: Vigilant of Stendarr got -21 exposure for having orgasm
SEXLAB - ActorAlias[Vigilant of Stendarr]  - Resetting!
[slainternalscr <sla_Internal (0E083137)>]: Bla had orgasm date updated
[slainternalscr <sla_Internal (0E083137)>]: Bla got -21 exposure for having orgasm
SEXLAB - Thread[0] Event Hook - AnimationEnd
[Zad]: OnAnimationEnd()
Error: Cannot call AllowPCDialogue() on a None object, aborting function call
stack:
    [PAHPersonalityEvenToned (0B02C44D)].PAHPunishmentRapeScript.PostRape() - "PAHPunishmentRapeScript.psc" Line 271
Error: Cannot call SetDontMove() on a None object, aborting function call
stack:
    [PAHPersonalityEvenToned (0B02C44D)].PAHPunishmentRapeScript.PostRape() - "PAHPunishmentRapeScript.psc" Line 272

 

 

Code:

 

 

Function punish(Actor _target, Actor _player, String _tag = "", bool _aggressive = false, String _tag2 = "")
[snip]
    sslThreadModel Model = SexLab.NewThread()
[snip]
    actor[] activeActors = new actor[2]
    If _player.GetActorBase().GetSex() == 0
        Model.AddActor(_target, IsVictim = aggressive)
        Model.AddActor(_player, IsVictim = false)
    Else
         [snip]
    EndIf

    If !animSet
        anims = SexLab.GetAnimationsByTags(2, tag, supress)
    EndIf

    Model.DisableUndressAnimation(target)
    Model.DisableRedress(target)

    Model.SetAnimations(anims)

    If startAnim
        model.SetStartAnimationEvent(target, startAnim)
    EndIf

    If aggressive
        RegisterForModEvent("AnimationEnd_PostRape", "PostRape")
        Model.SetHook("PostRape")
        setEndAnim(Model, true)
    Else
        RegisterForModEvent("AnimationEnd_PostFornicate", "PostFornicate")
        Model.SetHook("PostFornicate")
    EndIf

    Model.StartThread()
EndFunction
 
Event PostRape(string eventName, string argString, float argNum, form sender)
    Actor Victim = SexLab.HookVictim(argString)
L 271 ->    Victim.AllowPCDialogue(false)
L 272 ->    Victim.SetDontMove()

    Utility.wait(2.5)
    Debug.SendAnimationEvent(Victim, animIn)
[snip]
EndEvent

 

Problem:

StartAnimationEvent works fine, Animation works fine, EndAnimationEvent works fine, hook-event is called fine, but the stuff in the hook-event can't grab the actor and fails miserably...

It worked in 1.59 :/

No reason I can see, at least not without seeing the full unedited debug log to know for sure certain possible relevant errors weren't edited out.

 

1.60 specifically adds a 10 second period after a scene ends where it just sits idle before resetting so hooks on AnimationEnd can still fetch data for a period of time. This period ends whenever you see the line "Returning to thread pool..."

 

Make sure it's actually failing overall though, and not just on getting the victim. 1.60 adds the ability to define multiple victims in a scene, and for backwards compatibility sake the last actor set as a victim usually fills the Controller.VictimRef property in addition to being included in the new Controller.Victims Actor[] array. It could be your hooks working "fine", but 1.60 is just failing to fill in the VictimRef property. Test this by checking other things on the thread, like if the actors are still set on it or not.

 

Also for the love of talos, please stop using the old style hooks. The new style ones are easier to use, cleaner, sent sooner than the old ones,  and like nude suits I wish the old style hooks would die in a fire so I could remove them.

 

 

 

 

Also, is there a way to tell the actor(s) to enjoy the sex? Especially the

SEXLAB - ActorAlias[Vigilant of Stendarr]  - Voice[FemaleEvenToned (Lydia)] Expression[angry] BaseEnjoyment[0]
[Zad]: Set slot mask to [0]: 0
SEXLAB - ActorAlias[Bla]  - Voice[MaleEvenToned (Dovahkiin)] Expression[Sad] BaseEnjoyment[5]
and

SEXLAB - ActorAlias[Vigilant of Stendarr]  - Orgasms[1] Enjoyment [11] BaseEnjoyment[-52]
SEXLAB - ActorAlias[Bla]  - Orgasms[1] Enjoyment [13] BaseEnjoyment[-52]
are irritating...

At least one of them should be having fun ;)

 

 

What you're seeing there is misleading to a degree. The enjoyment number is used for building up the meter on multiple/seperate orgasms feature that's been added. It's their full calculated enjoyment, which is based on sexlab stats + animations played, length of time, and stage of animation, then their BaseEnjoyment is added on top of that produce the number used internally for the "orgasm meter". After an orgasm their current enjoyment is subtracted from their base enjoyment and then set to a  lower number so it can start building back up to 100 again. The Thread.GetEnjoyment(ActorRef) function will give you their actual "full" enjoyment level. Which in your example would be 70 for Bla and 63 for the Vigilant.

 

This is all still subject to change as I play around with, that log line isn't likely to stay in the final version and is just there currently more for my benefit while I was working on tweaking the calculations some.

 

 

 

 

 

Quick question for Ashal:

Was the TFC problem fixed in RC2? I am asking because I get the "stuck in 3rd person after sex" issue when I have the free cam set. I know you mentioned this a couple of pages back, but I can't seem to find the post about it :-\

 

I can't remember. If somebody could check for me that'd be super helpful and save me a lot of time to hopefully get RC3 out tonight, otherwise I'll play around with it and see later.

Link to comment

 

Feature request:

 

Unregister specific animations (opposite of sslAnimationFactory.RegisterAnimation(string) )

It's a bit of a pain to reset all animations to update just one.

I'm not sure it'd be a good idea. The animation searching and registering animations are both reliant on using the number of currently registered animations as it's starting loop point or next available slot. So to keep that I'd accurate I'd have to shift all animations in the registry that come after up one slot to fill in the gap, and possibly break things for any mods that might be storing info on those shifted animations based on their slot id number.

 

You should be able to re-register animations fairly simply as is.

; // Save the registry and slot IDs
int SaveSlotID      = Animation.SlotID
string SaveRegistry = Animation.Registry
; // Reset the animations data
Animation.Initialize()
; // Set the IDs name again since initialize clears it
Animation.SlotID   = SaveSlotID
Animation.Registry = SaveRegistry

; // Animation is empty now, you can now manually call the original registration event/function used to make it, by passing it the SlotID
; // Or just manipulate the animation object from here however you want, just be sure to call Animation.Save(SlotID) afterwards to finalize.

The only reason to do this though would be to alter some of the position data, you can edit pretty much everything else about an animation however you want after it's been registered already.

That's exactly what I need ;) (screwed up a rotation)

 

Hook-issue:

 

Log:

 

 

SexLab MCM Loaded CurrentVerison: 15992 / 15992

 

SEXLAB - LOADED: Version 15992 / 15992

[snip]

[PAHESex] punish([Actor < (FF001062)>], [Actor < (00000014)>], Vaginal, True, )

SEXLAB - Thread[0]  - Entering Making State

[PAHESex] Male PC

SEXLAB - NOTICE: ValidateActor(Vigilant of Stendarr) -- TRUE -- MISS

SEXLAB - ActorAlias[Vigilant of Stendarr] SetActor([Actor < (FF001062)>]) - [sslActorAlias <alias ActorAlias004 on quest SexLabThread00 (0D061EEF)>]

SEXLAB - NOTICE: ValidateActor(Bla) -- TRUE -- HIT

SEXLAB - ActorAlias[bla] SetActor([Actor < (00000014)>]) - [sslActorAlias <alias ActorAlias003 on quest SexLabThread00 (0D061EEF)>]

[PAHESex] Setting endAnim

[PAHESexScript]: PAHEEstrusTrauma

SEXLAB - ActorAlias[Vigilant of Stendarr]  - Voice[FemaleEvenToned (Lydia)] Expression[angry] BaseEnjoyment[0]

[Zad]: Set slot mask to [0]: 0

SEXLAB - ActorAlias[bla]  - Voice[MaleEvenToned (Dovahkiin)] Expression[sad] BaseEnjoyment[5]

SEXLAB - Thread[0] Event Hook - AnimationStart

[Zad]: OnAnimationStart()

[slnc] [slncMainQuestScript <slncControllerQuest (980110DF)>]: OnSexLabAnimationStart(AnimationStart, 0, 0.000000, [sslthreadcontroller <SexLabThread00 (0D061EEF)>]) Begin

[Zad]: No sex-act-restricted actors present in this sex scene. Done.

SEXLAB - Thread[0] Event Hook - StageStart

SEXLAB - Thread[0] Event Hook - StageEnd

SEXLAB - Thread[0] Event Hook - StageEnd

SEXLAB - Thread[0] Event Hook - StageStart

SEXLAB - Thread[0] Event Hook - StageEnd

SEXLAB - Thread[0] Event Hook - OrgasmStart

SEXLAB - Thread[0] Event Hook - StageStart

SEXLAB - ActorAlias[Vigilant of Stendarr]  - Orgasms[1] Enjoyment [11] BaseEnjoyment[-52]

SEXLAB - ActorAlias[bla]  - Orgasms[1] Enjoyment [13] BaseEnjoyment[-52]

SEXLAB - Thread[0] Event Hook - OrgasmEnd

SEXLAB - Thread[0] Event Hook - AnimationEnding

[slainternalscr <sla_Internal (0E083137)>]: Vigilant of Stendarr had orgasm date updated

SEXLAB - ActorAlias[bla]  - Resetting!

[slainternalscr <sla_Internal (0E083137)>]: Vigilant of Stendarr got -21 exposure for having orgasm

SEXLAB - ActorAlias[Vigilant of Stendarr]  - Resetting!

[slainternalscr <sla_Internal (0E083137)>]: Bla had orgasm date updated

[slainternalscr <sla_Internal (0E083137)>]: Bla got -21 exposure for having orgasm

SEXLAB - Thread[0] Event Hook - AnimationEnd

[Zad]: OnAnimationEnd()

Error: Cannot call AllowPCDialogue() on a None object, aborting function call

stack:

    [PAHPersonalityEvenToned (0B02C44D)].PAHPunishmentRapeScript.PostRape() - "PAHPunishmentRapeScript.psc" Line 271

Error: Cannot call SetDontMove() on a None object, aborting function call

stack:

    [PAHPersonalityEvenToned (0B02C44D)].PAHPunishmentRapeScript.PostRape() - "PAHPunishmentRapeScript.psc" Line 272

 

 

Code:

 

 

Function punish(Actor _target, Actor _player, String _tag = "", bool _aggressive = false, String _tag2 = "")

[snip]

    sslThreadModel Model = SexLab.NewThread()

[snip]

    actor[] activeActors = new actor[2]

    If _player.GetActorBase().GetSex() == 0

        Model.AddActor(_target, IsVictim = aggressive)

        Model.AddActor(_player, IsVictim = false)

    Else

         [snip]

    EndIf

 

    If !animSet

        anims = SexLab.GetAnimationsByTags(2, tag, supress)

    EndIf

 

    Model.DisableUndressAnimation(target)

    Model.DisableRedress(target)

 

    Model.SetAnimations(anims)

 

    If startAnim

        model.SetStartAnimationEvent(target, startAnim)

    EndIf

 

    If aggressive

        RegisterForModEvent("AnimationEnd_PostRape", "PostRape")

        Model.SetHook("PostRape")

        setEndAnim(Model, true)

    Else

        RegisterForModEvent("AnimationEnd_PostFornicate", "PostFornicate")

        Model.SetHook("PostFornicate")

    EndIf

 

    Model.StartThread()

EndFunction

 

Event PostRape(string eventName, string argString, float argNum, form sender)

    Actor Victim = SexLab.HookVictim(argString)

L 271 ->    Victim.AllowPCDialogue(false)

L 272 ->    Victim.SetDontMove()

 

    Utility.wait(2.5)

    Debug.SendAnimationEvent(Victim, animIn)

[snip]

EndEvent

 

Problem:

StartAnimationEvent works fine, Animation works fine, EndAnimationEvent works fine, hook-event is called fine, but the stuff in the hook-event can't grab the actor and fails miserably...

It worked in 1.59 :/

No reason I can see, at least not without seeing the full unedited debug log to know for sure certain possible relevant errors weren't edited out.

 

1.60 specifically adds a 10 second period after a scene ends where it just sits idle before resetting so hooks on AnimationEnd can still fetch data for a period of time. This period ends whenever you see the line "Returning to thread pool..."

 

Make sure it's actually failing overall though, and not just on getting the victim. 1.60 adds the ability to define multiple victims in a scene, and for backwards compatibility sake the last actor set as a victim usually fills the Controller.VictimRef property in addition to being included in the new Controller.Victims Actor[] array. It could be your hooks working "fine", but 1.60 is just failing to fill in the VictimRef property. Test this by checking other things on the thread, like if the actors are still set on it or not.

 

Also for the love of talos, please stop using the old style hooks. The new style ones are easier to use, cleaner, sent sooner than the old ones,  and like nude suits I wish the old style hooks would die in a fire so I could remove them.

The log is everything SexLab related, snipped to remove all the null-pointers from BeeingFemale, CreatureFeature and Apropos. No other edits (would be pointless to post it otherwise)

Also the timestamps for "Event Hook - AnimationEnd" and "Returning to thread pool..." are 11 seconds apart, so that should be in working order

 

SexLab.HookActors(argString) works fine when used to replace HookVictim(argString)... I'll try the new Victims[] and report back.

 

What new hooks are you talking about? I used the git-API to set those up ages ago. Mind to point me to the new one? (so the old ones can die in a fire ;) )

Link to comment

 

        RegisterForModEvent("AnimationEnd_PostRape", "PostRape")
        Model.SetHook("PostRape")

Also for the love of talos, please stop using the old style hooks. The new style ones are easier to use, cleaner, sent sooner than the old ones,  and like nude suits I wish the old style hooks would die in a fire so I could remove them.

 

What new hooks are you talking about? I used the git-API to set those up ages ago. Mind to point me to the new one? (so the old ones can die in a fire ;) )

 

Please let us know, supreme @Ashal. So we can use the new way, and guide the people by updating the mods and the guides. For the Love of Talos, Akatosh, Arkay, Alduin, Dibella, Herma-Mora, Julianos, Kynareth, Kyne, Malacath, Mara, Shor, Stendarr, Ysmir, and Zenithar.

Link to comment
RegisterForModEvent("HookAnimationEnd_MyHook", "AnimationEnded")

event AnimationEnded(int tid, bool HasPlayer)
	sslThreadController Thread = SexLab.GetController(tid)
	; // Do stuff with Thread.
endEvent

All the old style hooks exist, just add "Hook" to the start of it, and it'll receive the simplified event arguments instead. They've been in since 1.52 or somewhere around there, so they aren't really "new" at this point, but newer.

 

And to illustrate why I hate the old style hooks so much, this is literally what all of those HookXXX() functions look like.

int function HookStage(string argString)
	return ThreadSlots.GetController(argString as int).Stage
endFunction

With the new style you can just grab the thing that matters, the thread controller, and access every piece of the thread directly. Without having to cast to int, fetch the controller (everytime you call a HookXXXX() function), just to return a single property.

 

 

Link to comment

All the old style hooks exist, just add "Hook" to the start of it, and it'll receive the simplified event arguments instead.[/size][/font]

... 

Without having to cast to int, fetch the controller (everytime you call a HookXXXX() function), just to return a single property.

Holy-Moly. I was completely not aware of this.

You have no idea of how many [beep] I did to be able to get the Controller...

 

Link to comment
RegisterForModEvent("HookAnimationEnd_MyHook", "AnimationEnded")

event AnimationEnded(int tid, bool HasPlayer)
	sslThreadController Thread = SexLab.GetController(tid)
	; // Do stuff with Thread.
endEvent

All the old style hooks exist, just add "Hook" to the start of it, and it'll receive the simplified event arguments instead. They've been in since 1.52 or somewhere around there, so they aren't really "new" at this point, but newer.

New to me, so good enough ;)

Does the sslThreadModel.SetHook("MyHook") remain?

 

 

All the old style hooks exist, just add "Hook" to the start of it, and it'll receive the simplified event arguments instead.[/size][/font]

... 

Without having to cast to int, fetch the controller (everytime you call a HookXXXX() function), just to return a single property.

Holy-Moly. I was completely not aware of this.

You have no idea of how many [beep] I did to be able to get the Controller...

Why not use SexLab.HookController(argString)?

Not that it matters anymore, but... you know... ;)

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