What's the best way to avoid an is inside tree error

I did that the first time. You said this file was missing

Yes, zip everything (including this file) again into one zip file.

Last time

So looking forward to setting up the toggle buttons and randomiser for them. Right I need to charge my cell and it’s the middle of the night

It doesn’t reproduce. Runs as expected here. The issue is probably related to mobile.

Based on what @normalized is saying, the next step is to log a bug. The Android version of the Godot Editor is new.

  1. Click here to go to the issues page.
  2. Click the New Issue button.
  3. Click Bug Report in the pop-up.
  4. Read the bug report and give all the information you are asking.
  5. Make sure you include the Godot version you are using. (According to your screenshots you are using: Godot 4.6.1.stable)
  6. Attach the zipfile of your project that @normalized had you make as the MVP project. (Make sure you give them the one with the project file in it.)
  7. Link to this thread to provide them additional information. (Make sure you describe the problem in your bug report - don’t just link this thread.)

Hopefully setting up the toggles in the environment menu will go smother.

I believe this may be related to this bug: ERROR: can_process: Condition "!is_inside_tree()" is true. Returned: false · Issue #48607 · godotengine/godot · GitHub

Adding a change_scene function and using call_deferred to call it from the UI control’s pressed signal is the workaround recommended in that github discussion, and it worked for me.

func _change_scene(scene_path: String) -> void:
	get_tree().change_scene_to_file(scene_path)
func _on_start_button_pressed() -> void:
	call_deferred("_change_scene", SettingsManager.TIMER_SCREEN_PATH)

It works for me too and it’s ok for a few scene changes. If there was a lot of changes though I just thought there might be a better way to do it like a single delay or auto load rather than call deferred attached to every function.

Implement a global function that does the deferred call. It’d at least remove the need to constantly type “call_deferred”

Thanks. I’ll keep that in mind when I’ve worked out more of what I need as there may be other global code required.