Jump to content

fQuestDelayTime doesn't seem to work.


jimnms

Recommended Posts

I need to make a script run every in-game minute, which will differ if users change their timescale. To find out how long one in-game minute is, you just divide 60 by the timescale, so I do "set fQuestDelayTime to ( 60 / timescale )". My current timescale is 12, so one game minute is 5 seconds, which is also the default time for repeating scripts. The script works, but when I tested it using a different timescale, it still runs every 5 seconds. I've even explicitly set the fQuestDelayTime to a faster interval, but it always runs at the default 5 seconds. Does this just not work in New Vegas?

Link to comment
Share on other sites

 

I managed to accomplish what I need by using the GetSecondsPassed and adjusting it to the time scale. This worked out better since it doesn't have to run faster for people that use the default timescale of 30, and it's more accurate since the script is not always processed exactly every 5 seconds (the default process time). To help debug the script, I set some stuff to output things to the console and noticed the script processing time would vary by up to 0.1 seconds, which isn't much, but over time would add up to a significant error. The only down side is that more in-game time will pass for people with higher timescales before things update.

 

You should probably leave fQuestDelayTime alone. That set's the default quest delay for every quest in the game.

 

I can't find the page on the GECK Wiki where it gave an example using fQuestDelayTime, but the link it gave for help on the fQuestDelayTime pointed to the Elder Scrolls Construction Set Wiki, which says:

 

fQuestDelayTime is a special float variable used by quest scripts to determine how often the script should run.

 

It must be declared in each quest script that you want to use it in, and can be set like any other variable (set fQuestDelayTime to .01).

 

The variable unit is in seconds, so if you set it to 1 the script will run once every second, 0.5 will run twice a second (every half second), etc. but will never run more than once a frame.

 

If fQuestDelayTime is 0 (or undeclared) the script will run every 5 seconds (default value).

 

 

It appears this is no longer used in the GECK and is replaced by the SetQuestDelay instead.

Link to comment
Share on other sites

 

I managed to accomplish what I need by using the GetSecondsPassed and adjusting it to the time scale. This worked out better since it doesn't have to run faster for people that use the default timescale of 30, and it's more accurate since the script is not always processed exactly every 5 seconds (the default process time). To help debug the script, I set some stuff to output things to the console and noticed the script processing time would vary by up to 0.1 seconds, which isn't much, but over time would add up to a significant error. The only down side is that more in-game time will pass for people with higher timescales before things update.

 

 

 

Exactly ... because frame rate will vary , unless you clamp it.

Using actual seconds passed is a basic function any computer can do without being subject to the frame rate.

 

Glad you figured it out ... I guess that's why they had "Getsecondspassed" linked on that page.

Link to comment
Share on other sites

 

 

I managed to accomplish what I need by using the GetSecondsPassed and adjusting it to the time scale. This worked out better since it doesn't have to run faster for people that use the default timescale of 30, and it's more accurate since the script is not always processed exactly every 5 seconds (the default process time). To help debug the script, I set some stuff to output things to the console and noticed the script processing time would vary by up to 0.1 seconds, which isn't much, but over time would add up to a significant error. The only down side is that more in-game time will pass for people with higher timescales before things update.

 

You should probably leave fQuestDelayTime alone. That set's the default quest delay for every quest in the game.

 

I can't find the page on the GECK Wiki where it gave an example using fQuestDelayTime, but the link it gave for help on the fQuestDelayTime pointed to the Elder Scrolls Construction Set Wiki, which says:

 

fQuestDelayTime is a special float variable used by quest scripts to determine how often the script should run.

 

It must be declared in each quest script that you want to use it in, and can be set like any other variable (set fQuestDelayTime to .01).

 

The variable unit is in seconds, so if you set it to 1 the script will run once every second, 0.5 will run twice a second (every half second), etc. but will never run more than once a frame.

 

If fQuestDelayTime is 0 (or undeclared) the script will run every 5 seconds (default value).

 

 

It appears this is no longer used in the GECK and is replaced by the SetQuestDelay instead.

 

I misread it and thought it was a gamesetting rather than a quest variable. I've never seen that used in FO3 or FNV. I've always used setquestdelay.

On this page: https://geck.technodeep.net/index.php/Special_Variables

 

Link to comment
Share on other sites

  • Recently Browsing   0 members

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