Starting A Quest From Within A Quest

Post » Thu Jun 21, 2012 6:24 pm

In my initial quest I have a character that gives the player a note through ForceGreet.

In the dialog where he gives the note I have NextQuest.SetStage(10)

"NextQuest" is started at the game beginning.

I also have a routine that transfers the note from the greeter to the player.

I get the expected Tune and Display that the next quest has started and a message to read the note.

However, when I read the note it doesn't advance the next quest's stage.

There is a script in the 2nd quest that should advance to the next stage and it worked before when that quest was on it's own.

The problem I am encountering is that the current quest can not be stopped at this point and will be stopped at a later time.

So, how can I transfer the player to the next quest without stopping the current quest?

Thanks for any and all help :smile:
User avatar
Miguel
 
Posts: 3364
Joined: Sat Jul 14, 2007 9:32 am

Post » Thu Jun 21, 2012 7:56 am

if you want the stage to advance after reading the note, you should use a script on the note. i believe there is already a default script for this very thing
User avatar
Lexy Corpsey
 
Posts: 3448
Joined: Tue Jun 27, 2006 12:39 am

Post » Thu Jun 21, 2012 7:12 am

Man

I though that was definitely the right answer.

I went through about 5 different saves and used one to fast travel about 4 times and then went back.

But it still didn't advance to the next stage after reading the note.

I put the script "DefaultOnReadSetQuestStage" on the note and I can't see why that wouldn't work if the variables are set correctly.
User avatar
Jeff Tingler
 
Posts: 3609
Joined: Sat Oct 13, 2007 7:55 pm

Post » Thu Jun 21, 2012 8:44 pm

In order to test it to ensure that there wasn't something wrong with the Next quest I set the stage to 20 when the player receives the note.

The correct message was displayed and the compass heading showed correctly as well.

But for some reason the script on the note itself isn't running :confused:
User avatar
Josephine Gowing
 
Posts: 3545
Joined: Fri Jun 30, 2006 12:41 pm

Post » Thu Jun 21, 2012 11:46 am

are you testing with clean saves?
some quest data will not update if you are using an existing save that already has the older version of your mod in it
User avatar
Haley Merkley
 
Posts: 3356
Joined: Sat Jan 13, 2007 12:53 pm

Post » Thu Jun 21, 2012 9:25 am

I just went through the beginning of the game, made shorter by the mod "Live Another Life" :cool: , and it still didn't advance.

I'm wondering if the problem is that Stage 10 isn't being set as completed before reading the note sets it to Stage 20.

So I am trying to just make everything the other quest does into the current one.

But I've forgotten the syntax for setting the current Stage.

It's something like game.GetOwningQuest().Stage(20) or something like that that I can put into a fragment.

Oh yea and something like the same but to set the stage as completed.
User avatar
Chris Ellis
 
Posts: 3447
Joined: Thu Jul 26, 2007 10:00 am

Post » Thu Jun 21, 2012 6:52 am

I figured it out...it's "GetOwningQuest().setstage(60)" that I was looking for :)

It didn't work anyway and it also showed the name of the current quest "Keep Player Out"...which I really don't want displayed lol
User avatar
Amy Smith
 
Posts: 3339
Joined: Mon Feb 05, 2007 10:04 pm

Post » Thu Jun 21, 2012 10:31 am

This might give a better understanding of what I'm doing:

https://www.youtube.com/watch?v=SXj3tdWuGWM
User avatar
biiibi
 
Posts: 3384
Joined: Sun Apr 08, 2007 4:39 am

Post » Thu Jun 21, 2012 8:16 am

How is the script attached to the note?

Given that it worked stand-alone, have you changed how the note is created and referenced?

For example, a script which extends an object reference will do nothing on a reference alias (and vice-versa).

If that doesn't help, maybe you could post your scripts?

P.S. If SetStage is displaying an unwanted quest name, check that the corresponding log entry (and objective, if any) is null text.
User avatar
MR.BIGG
 
Posts: 3373
Joined: Sat Sep 08, 2007 7:51 am

Post » Thu Jun 21, 2012 8:57 pm

I've tried the script on the note itself and in the Alias page for it.

What I am doing is I'm changing how the note is obtained.

What I did to originally create the note quest was to follow this tutorial: https://www.youtube.com/watch?v=iustaHoHnEE

That quest used the Courier to give the note to the player.

What I am trying to do is use that same quest by starting it with the quest that starts the Lamplight mod.

So I have deleted the stuff regarding the WICourier and I am trying to use a ForceGreet instead within the Lamplight quest called "KeepPlayerOut".

In the ForceGreet it is setting two things....

It starts the old courier quest with NextQuest.Start()

It then sets the stage number with NextQuest.SetStage(10)

NextQuest is a property that points to the old courier quest.

In stage 10 of the courier quest I added: game.getPlayer().AddItem(Note) to the fragment in order for the player to receive the note, and the player receives the note as expected.

The next line in Stage 10 is: SetObjectiveDisplayed(10)

In the Objectives tab Objective 10 says Read which does not work. The output is Read <...> so something is wrong with the property not being set so the Alias is the Note. But the property is actually in the properties of the fragment, which is left-over from the courier quest.

So I think the issue is that the alias is not being set for some reason.
User avatar
Jinx Sykes
 
Posts: 3501
Joined: Sat Jan 20, 2007 11:12 pm

Post » Thu Jun 21, 2012 7:30 am

...So I think the issue is that the alias is not being set for some reason.
To fill the alias, you could either use the Alias tab in the CK (e.g. Create Reference To Object ... In ...) or ForceRefTo a note created by some other means.

If you're already doing the latter, I'd reset any script properties that refer to the item or its alias (even if they appear to be correct) for good order.

If none of that works, please post scripts!

P.S. Having the attention span of a gnat, I didn't look at the video tutorial...
User avatar
Susan
 
Posts: 3536
Joined: Sun Jun 25, 2006 2:46 am


Return to V - Skyrim