Jump to content

[LE] papyrus script to enable specific quest


Recommended Posts

Hmm.. did you ever seen this https://www.creationkit.com/index.php?title=Bethesda_Tutorial_Dialogue

 

please have a look at headline "Scripting Dialogue"

normally a dialogue script fragment looks as follow

 

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

;BEGIN FRAGMENT Fragment_0
Function Fragment_0(ObjectReference akSpeakerRef)
Actor akSpeaker = akSpeakerRef as Actor
;BEGIN CODE
GetOwningQuest().SetStage(135)        ; GetOwningQuest() means that the quest we care about is the one that contains this dialogue.
;END CODE
EndFunction
;END FRAGMENT

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

 


yours could be as follow

 

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

;BEGIN FRAGMENT Fragment_0
Function Fragment_0(ObjectReference akSpeakerRef)
Actor akSpeaker = akSpeakerRef as Actor
;BEGIN CODE
    IF myQuest.IsRunning()
        ; quest is already running
    ELSE
        myQuest.Start()             ; to start a quest which not owned this dialogue
;;;     myQuest.SetStage(1)         ; to start the quest and set a special stage here 1
    ENDIF
;END CODE
EndFunction
;END FRAGMENT

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

  Quest PROPERTY myQuest auto        ; do not forget to fill this with your quest "KoahniRestoration"

 

 

Edited by ReDragon2013
Link to comment
Share on other sites

  • Recently Browsing   0 members

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