Difference between revisions of "FQuestDelayTime"
Jump to navigation
Jump to search
imported>Haama (Clarified?) |
imported>QQuix (Added an example) |
||
(2 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
fQuestDelayTime is a special float variable used by [[Quest scripts|quest scripts]] to determine how often the script should run. | |||
[[Category: | 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). | |||
===Example=== | |||
ScriptName MyQuestScript | |||
float fQuestDelayTime | |||
begin gamemode | |||
... | |||
set fQuestDelayTime to .1 ;== runs 10 times per second === | |||
... | |||
end | |||
[[Category: Variables]] |
Latest revision as of 15:11, 6 February 2012
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).
Example[edit | edit source]
ScriptName MyQuestScript float fQuestDelayTime begin gamemode ... set fQuestDelayTime to .1 ;== runs 10 times per second === ... end