Jump to content

[Dialogue] 3 Scripting Requests


travis199

Recommended Posts

Posted

Hello Everyone.

 

I'm currently working on a simple yet hugely time consumming mod that consist in adding multiple dialogue trees.

Now what I want are 3 actions at the end of a dialogue.

 

- Increase/Decrease in Relationship rank

- Trigger specific animations, all dressed

- Trigger simple sex

 

How am I supposed to do that? I never learned scripting but i think this is not a really hard thing to do right ?

 

Anyway, how am i supposed to call all of that ? The lines in papyrus i mean.

 

Your help would truly make a difference for me thanks a lot.

 

Posted

Change the relationship rank:

 

Actor Property PlayerRef Auto

 

...

akSpeaker.SetRelationshipRank(PlayerRef, 6)

...

 

 

About triggering animations it depends of what the animation is

 

Maybe a Debug.SendAnimationEvent(theActor, "name of the HKX file") will be enough.

 

 

About how to start a SexLab anim, just give a look to my Papyrus guide to find it out.

 

 

And ask for help, I will always answer.

  • 2 weeks later...
Posted

Sorry for being so slow to respond, i think i've had all the issues reported with scripting in the CK :D . I re-installed it 2 times and it's ok now.

 

Thanks a lot CPU, your guide helped me more than i could have ever hoped. I managed to do what i wanted to do, almost.

 

The last thing that i can't manage to find how to do is calling a specific animation.

 

To be clear; what i want is triggering the "Leito Kissing" animation at the end of the dialogue, but it never works for me. It can be nothing happens at all or it triggers every animations. + a little non-strip script that i can't seem to find.

 

The last thing i tried is being less specific and calling by tags

 

 

;BEGIN FRAGMENT CODE - Do not edit anything between this and the end comment
;NEXT FRAGMENT INDEX 1
Scriptname SeduceKiss_001 Extends TopicInfo Hidden

;BEGIN FRAGMENT Fragment_0
Function Fragment_0(ObjectReference akSpeakerRef)
Actor akSpeaker = akSpeakerRef as Actor
;BEGIN CODE
actor[] MoresexActors = new actor[2]
MoresexActors[0] = akSpeaker
MoresexActors[1] = Game.GetPlayer()
sslBaseAnimation[] Moreanims = SexLab.GetAnimationsByTag(2, "Kissing", MoresexActors[0])
SexLab.StartSex(MoresexActors, Moreanims)
;END CODE
EndFunction
;END FRAGMENT

;END FRAGMENT CODE - Do not edit anything between this and the begin comment
 

SexLabFramework Property SexLab Auto

 
Any idea ? Thanks again.
Posted

If you want a specific anim try that.

;BEGIN FRAGMENT CODE - Do not edit anything between this and the end comment
;NEXT FRAGMENT INDEX 1
Scriptname SeduceKiss_001 Extends TopicInfo Hidden
 
;BEGIN FRAGMENT Fragment_0
Function Fragment_0(ObjectReference akSpeakerRef)
Actor akSpeaker = akSpeakerRef as Actor
;BEGIN CODE
actor[] MoresexActors = new actor[2]
MoresexActors[0] = akSpeaker
MoresexActors[1] = Game.GetPlayer()
sslBaseAnimation[] Moreanims = new sslBaseAnimation[1]
Moreanims[0] = SexLab.GetAnimationByRegistry("<id of the leito kissing anim>")
SexLab.StartSex(MoresexActors, Moreanims)
;END CODE
EndFunction
;END FRAGMENT
 
;END FRAGMENT CODE - Do not edit anything between this and the begin comment
 
SexLabFramework Property SexLab Auto

In case you want to disable the stripping, then you need to use a slightly advanced code.

;BEGIN FRAGMENT CODE - Do not edit anything between this and the end comment
;NEXT FRAGMENT INDEX 1
Scriptname SeduceKiss_001 Extends TopicInfo Hidden
 
;BEGIN FRAGMENT Fragment_0
Function Fragment_0(ObjectReference akSpeakerRef)
Actor akSpeaker = akSpeakerRef as Actor
;BEGIN CODE
sslThreadModel t = SexLab.NewThread() ; "Claim for a sexlab thread"

t.AddActor(akSpeaker) ; "Add the actors"
t.AddActor(PlayerRef)

bool[] strips = new bool[33]
t.SetStrip(akSpeaker, strips) ; "Do not strip"
t.DisableUndressAnimation(akSpeaker, true) ; "no strip animation"
t.SetStrip(PlayerRef, strips)
t.DisableUndressAnimation(PlayerRef, true)

sslBaseAnimation[] Moreanims = new sslBaseAnimation[1]
Moreanims[0] = SexLab.GetAnimationByRegistry("<id of the leito kissing anim>")
t.SetForcedAnimations(Moreanims)

sslThreadController tc = t.StartThread() ;END CODE EndFunction ;END FRAGMENT   ;END FRAGMENT CODE - Do not edit anything between this and the begin comment   SexLabFramework Property SexLab Auto Actor Property PlayerRef Auto

Archived

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

  • Recently Browsing   0 members

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