Best way to make the player wait 3 hours before continuing q

Post » Mon Nov 19, 2012 12:47 pm

In my quest a blacksmith is making the player an item. I want the player to have to wait 3 hours (Run around for 3 hours, sleep, whatever they do) before the blacksmith's dialogue changes to 'the item is done'.

What would be the most efficient and cleanest way of doing this? What I'm currently considering is adding my own global variable, then when the blacksmith starts his work, setting the global to GameDaysPassed + .16 (so it's ~3 hours later). Then I would just use GetGlobalValue as a dialogue condition with >= my global. The issue here is that I want the blacksmith's dialogue to change incrementally as his work progresses. If you ask within the first hour, he says one thing. Second hour, he says another. Third hour, he says he's almost done. Then after the third hour he says he's done and the quest progresses.

The issue is that would then require 3 global variables, and it just seems like it's getting too messy and I'm going about this the wrong way.

Is there a clear, more efficient way to set the time his work started, then have my call a dialogue condition for 'Is within hour 1', 'Is within hour 2', 'Is within hour 3', and 'Is done' or something to that effect?
User avatar
Roberto Gaeta
 
Posts: 3451
Joined: Tue Nov 06, 2007 2:23 am

Post » Mon Nov 19, 2012 3:29 am

I'd say use a script with Utility.Wait, and then set the next stage in the next line.

Then in the dialogue have a condition that the next stage is complete :smile:

Edit:

Say your dialogue is at Stage 30. So in the End Fragment of your "I'll make your thing now" dialogue response, have:

Utility.WaitGameTime(3); pauses the script for 3 in-game hoursGetOwningQuest.SetStage(40)

Then, make a new Dialogue Topic/Response, where the player can get the thing, with a condition on TARGET GetStageDone QuestName 40 == 1 (if you get my drift).

Easy peasy :smile:

You could do this more than once like you want. Have 3 responses, and Utility.WaitGameTime(1) in each, and have a new stage set for each stage of the creation process.
User avatar
Danielle Brown
 
Posts: 3380
Joined: Wed Sep 27, 2006 6:03 am

Post » Mon Nov 19, 2012 4:41 am

Ah, yes I can use http://www.creationkit.com/WaitGameTime_-_Utility then set a stage indeed. However I don't think that would let me do it in increments, but that's fine I just wont. I doubt anyone will be checking back every 5 seconds anyway, they'll probably just go do another quest or wait for several hours. :P

This is indeed far simpler. This is why I come here! Thanks! :D
User avatar
maria Dwyer
 
Posts: 3422
Joined: Sat Jan 27, 2007 11:24 am

Post » Mon Nov 19, 2012 1:18 pm

Ah, yes I can use http://www.creationkit.com/WaitGameTime_-_Utility then set a stage indeed. However I don't think that would let me do it in increments, but that's fine I just wont. I doubt anyone will be checking back every 5 seconds anyway, they'll probably just go do another quest or wait for several hours. :tongue:

This is indeed far simpler. This is why I come here! Thanks! :biggrin:

See my final sneaky edit at the end ;)
User avatar
Laura Simmonds
 
Posts: 3435
Joined: Wed Aug 16, 2006 10:27 pm

Post » Mon Nov 19, 2012 10:41 am

See my final sneaky edit at the end :wink:
But what if the player waits for longer than one hour? My impression is that if they wait for, say 5 hours, the game hour would complete it's wait for 1 hour, then initiate the next wait. Meaning that after 5 hours it thinks it's only waiting for 1.

Or wait... Since the game waits 1 hour at a time, would it calculate properly for each hour? Am I overthinking this? :bonk:
User avatar
Louise Andrew
 
Posts: 3333
Joined: Mon Nov 27, 2006 8:01 am

Post » Mon Nov 19, 2012 6:06 am

But what if the player waits for longer than one hour? My impression is that if they wait for, say 5 hours, the game hour would complete it's wait for 1 hour, then initiate the next wait. Meaning that after 5 hours it thinks it's only waiting for 1.

Or wait... Since the game waits 1 hour at a time, would it calculate properly for each hour? Am I overthinking this? :bonk:

It calculates properly lol :smile: and yes! ;)
User avatar
Tamara Dost
 
Posts: 3445
Joined: Mon Mar 12, 2007 12:20 pm

Post » Mon Nov 19, 2012 6:12 am

I'd suggest putting the Utility.WaitGameTime(1)--and SetStage code after the first--in each stage's script, rather than the response script. That way they will advance whether or not the player checks in with the blacksmith during the 3-hour window.
User avatar
George PUluse
 
Posts: 3486
Joined: Fri Sep 28, 2007 11:20 pm

Post » Mon Nov 19, 2012 6:25 am

I'd suggest putting the Utility.WaitGameTime(1)--and SetStage code after the first--in each stage's script, rather than the response script. That way they will advance whether or not the player checks in with the blacksmith during the 3-hour window.

Well spotted soldier!
User avatar
tiffany Royal
 
Posts: 3340
Joined: Mon Dec 25, 2006 1:48 pm

Post » Mon Nov 19, 2012 7:48 am

Ah. I was going to throw it all in the first dialogue's response script, (So not quite all different scripts) but doing it in the stage scripts would indeed be better! I'll get this all set up.

Thanks again guys! I knew I was overthinking it, I'm glad I asked here. xD
User avatar
Guy Pearce
 
Posts: 3499
Joined: Sun May 20, 2007 3:08 pm


Return to V - Skyrim