summaryrefslogtreecommitdiff
path: root/doc/classes/Timer.xml
diff options
context:
space:
mode:
authorHugo Locurcio <hugo.locurcio@hugo.pro>2021-10-09 08:57:48 +0200
committerHugo Locurcio <hugo.locurcio@hugo.pro>2021-10-09 08:57:48 +0200
commit42d13e29e2813ee833fa209cfd0e9b379cb84cd9 (patch)
tree08dd8fdced1e1ea5fa30ce282e9f0015e9353c3a /doc/classes/Timer.xml
parent6f72d9d19fe11ccc38a69e0460813646ad28d0e5 (diff)
Add a warning for Timer nodes with very low wait times
Very low wait times behave in unpredictable ways depending on the rendered frame rate. This is because the timeout signal is only emitted once per rendered frame (or physics frame, depending on the timer's process mode).
Diffstat (limited to 'doc/classes/Timer.xml')
-rw-r--r--doc/classes/Timer.xml3
1 files changed, 2 insertions, 1 deletions
diff --git a/doc/classes/Timer.xml b/doc/classes/Timer.xml
index a6ea5738d5..fde887dd87 100644
--- a/doc/classes/Timer.xml
+++ b/doc/classes/Timer.xml
@@ -51,7 +51,8 @@
[b]Note:[/b] You cannot set this value. To change the timer's remaining time, use [method start].
</member>
<member name="wait_time" type="float" setter="set_wait_time" getter="get_wait_time" default="1.0">
- Wait time in seconds.
+ The wait time in seconds.
+ [b]Note:[/b] Timers can only emit once per rendered frame at most (or once per physics frame if [member process_callback] is [constant TIMER_PROCESS_PHYSICS). This means very low wait times (lower than 0.05 seconds) will behave in significantly different ways depending on the rendered framerate. For very low wait times, it is recommended to use a process loop in a script instead of using a Timer node.
</member>
</members>
<signals>