example.md 560 B


tags: timer title: Cancel timer example brief: This example shows how to create timer and cancel it anytime, using built-in timer API. author: Pawel Jarosz

scripts: cancel_timer.gui_script

The example shows how to use Defold built-in timer and uses two indicators:

  1. A particlefx gui node that is triggered every 1s.
  2. A text node with an information displaying.

The particle fx is played every 1s showing small eruption. You can click anywhere to cancel the timer and the particlefx won't be triggered anymore.

cancel_timer