Two problems here

Godot Version

4.4

Question

Pausing just does not work I have no idea what the problem is.
Also there is stretched legs. (It looks fine in editor.)

I wish I could upload a video…

What do you mean pausing doesn’t work? Do you pause in code, or in editor, or when does it not work?
What do you mean stretched legs? Have you tried standing up from your desk?
Please provide more details, I’m confused :slight_smile:

1 Like
  1. In code:
    extends Button

func _button_pressed():
print(“Button pressed”)
get_tree().set_deferred(“paused”, true)
I’ve tried lots of other configurations, copilot is no help

  1. On blargy the guy in my profile pic. (still can’t upload.)

Also; if it matters I mean stretched wider not longer.

Try this script on your Button, it will allow you to pause and resume the game on each click.

extends Button

func _ready() -> void:
	process_mode = Node.PROCESS_MODE_ALWAYS

func _pressed() -> void:
	get_tree().paused = not get_tree().paused

About your profile picture - I still don’t understand what you mean, sorry.

2 Likes

Maybe your pressed signal is not connected.

Could you post a screen shot of the issue you are having?


Make sure to paste code with proper formatting

1 Like

I changed my profile pic to better represent the bug. :sweat_smile:


I can upload now!

1 Like