Queststage problem, repeatable quest

Post » Tue Jun 19, 2012 4:01 pm

I have a quest, starts (ongame start enable) on stage 0
after some regular "who are you" dialogue stage sets to 1 and you can get the quest dialogue
In dialogue it sets to 10 when 5 aliases (create on location, starting disabled) I need to kill get enabled
After killing you get stage 100 --> collect bounty
Talking to collect bounty sets stage 200.


This is papyrus script on stage 200:


Game.GetPlayer().AddItem(Gold001, 2500)
utility.wait (1)
SetObjectiveCompleted(10, false)
utility.wait (1)
SetStage (1)
utility.wait (1)


I want the quest to be repeatable (I hope the create aliases on location will allow them to spawn once more but else I'll try to placeactor at later.) my problem now is that I'd like to set the quest to stage 1 (see above). That should disallow the conversation topic to get the bounty (which has a condition queststage > 90). But this doesnt work, I keep getting the recieve bounty option and then you keep getting cash.. which isn't the intention so the quest stage must be > 90 (100 or 200)

Where is my script going wrong.
User avatar
Darren
 
Posts: 3354
Joined: Wed Jun 06, 2007 2:33 pm

Post » Wed Jun 20, 2012 1:46 am

try this:

at stage 200 tick the complete quest checkbox, and in the next quest dropdown, select the same quest (i think this is how Dark Brotherhood Forever is set up i cant remember)


on stage 1 you need an additional condition. introduce a global variable like HasCompleted that starts at 0, and will change to 1 the first time you complete the quest. so that when it restarts back at stage 1, if the variable is already at value of 1 for all the additional go arounds, then it skips directly to stage 2



EDIT: i just checked DB forever quest in the CK. they use a 2nd quest to kickstart the first one again.

what you can do is make a 2nd quest whose sole purpose is to loop the original one.


at stage 200 of your quest do something like ColtrolQuest.SetStage(10), where you would declare a quest property for ControlQuest and set this as your 2nd quest.

on the actual ControlQuest's stage 10, it should be OriginalQuest.SetStage(2) or whatever stage you want it to repeat on
User avatar
Kaley X
 
Posts: 3372
Joined: Wed Jul 05, 2006 5:46 pm

Post » Wed Jun 20, 2012 5:34 am

You may also need to add a stop() command to your quest
User avatar
Charlie Sarson
 
Posts: 3445
Joined: Thu May 17, 2007 12:38 pm

Post » Tue Jun 19, 2012 3:30 pm

I'll try messing around with the stop() a bit.

If not succesful I'll need to look into the control script thingie. I just don't see why exactly the same commands in the same script (as I have now) wouldn't do the same thing. Anyone that can explain that to me for better understanding?
User avatar
Joey Bel
 
Posts: 3487
Joined: Sun Jan 07, 2007 9:44 am

Post » Wed Jun 20, 2012 12:59 am

as far as i know, a quest can only call later stages onto itself (i have never gotten this to work myself, and have yet to find a vanilla quest that can do this). in order to call an earlier stage it has to be done so from an external source such as a control quest or trigger.
User avatar
Jade Barnes-Mackey
 
Posts: 3418
Joined: Thu Jul 13, 2006 7:29 am

Post » Tue Jun 19, 2012 5:47 pm

ok I guess I'll have to take that as a fact.
User avatar
Stephanie Nieves
 
Posts: 3407
Joined: Mon Apr 02, 2007 10:52 pm


Return to V - Skyrim