Scriptname __LALLParentsBedScript extends ObjectReference
{When Bjorn and Nicolette are within triggerbox radius, start a sexlab scene}

Actor Property Bjorn Auto
Actor Property Nicolette Auto
SexLabFramework Property mySexLab Auto
Quest Property MiscDialogueQuest Auto
GlobalVariable Property SpecialEventGLB Auto
GlobalVariable Property SexCooldownGLB Auto


string Function GetTag()
int rand = Utility.RandomInt(0,5)
if rand == 0
return "Doggy"
elseif rand == 1
return "69"
elseif rand == 2
return "Behind"
elseif rand == 3
return "Anal"
elseif rand == 4
return "Riding"
elseif rand == 5
return "Vaginal"
endif
EndFunction


Event OnTriggerEnter(objectReference akActionRef)
float SpecEvent = SpecialEventGLB.GetValue()
float CooldownActive = SexCooldownGLB.GetValue()
if akActionRef == Bjorn && SpecEvent != 1 && CooldownActive != 1
mySexLab.QuickStart(Bjorn,Nicolette,none,none,none,none,GetTag())
debug.notification("Parents fucking")
RegisterForSingleUpdateGameTime(12.0)
SexCooldownGLB.SetValue(1)
if MiscDialogueQuest.GetStageDone(10) == false
MiscDialogueQuest.Start()
MiscDialogueQuest.SetStage(10)
endif
endif
EndEvent

Event OnUpdate()
SexCooldownGLB.SetValue(0)
EndEvent