How to pause the action?

Godot Version

4.3 beta 2

Question

i can’t figure out how to pause the action in my tower defense game. What i’ve tried:

  1. get_tree().pause=true. This pauses the action but it also disables the entire UI, including the unpause button.
  2. Engine.time_scale = 0.0. This works a lot better but, despite everything i’ve read, it doesn’t work on timers. The result: The creeps are paused but the towers keep firing, killing the creeps.

i can manually write my own game loop and timing system (i’ve had to for other engines) but i’m hoping Godot has a better option.

You can set specific nodes to act during pause, this is the “Process Mode” Set your un-pausable UI to “Always”

1 Like

Well hey, that worked. Went to the root CanvasLayer, set Process-->Mode=Always and now every UI button works. Cool.

2 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.