When i’m running more than one instance of the game, is there any quick way to tell which instance of the game is the one that gets its scene tree displayed under “Remote” in the editors scene tab?.

You are viewing a single thread.
View all comments
0 points
*

It’s the “first” instance that opens - on my machine it corresponds to the window order in the taskbar. The feature to configure the started instances with parameters is not yet merged into Godot 4 but I think for 3 there’s an addon in the asset library to give your started instances some parameters to help you identify them.

If you just want to quickly see which window you have in the “remote” tree view, I’d suggest a quick and dirty autoload script like this:

extends Node
func _ready():
    name = str(randi_range(111,999))

    # Chill for a frame in case some other script sets the window title
    await get_tree().process_frame
    DisplayServer.window_set_title("Window: %s" % name)

Put it at the end of the autoload queue and it will create a top level node with a random-number as the name and also put that name in the window title. Note that this is for Godot 4.

Alternatively if you don’t want to write the number into the window’s title you can also get the name property of the autoload and write in in a label somewhere in your UI.

permalink
report
reply

Godot

!godot@programming.dev

Create post

Welcome to the programming.dev Godot community!

This is a place where you can discuss about anything relating to the Godot game engine. Feel free to ask questions, post tutorials, show off your godot game, etc.

Make sure to follow the Godot CoC while chatting

We have a matrix room that can be used for chatting with other members of the community here

Links

Other Communities

Rules

  • Posts need to be in english
  • Posts with explicit content must be tagged with nsfw
  • We do not condone harassment inside the community as well as trolling or equivalent behaviour
  • Do not post illegal materials or post things encouraging actions such as pirating games

We have a four strike system in this community where you get warned the first time you break a rule, then given a week ban, then given a year ban, then a permanent ban. Certain actions may bypass this and go straight to permanent ban if severe enough and done with malicious intent

Wormhole

!roguelikedev@programming.dev

Credits

  • The icon is a modified version of the official godot engine logo (changing the colors to a gradient and black background)
  • The banner is from Godot Design

Community stats

  • 636

    Monthly active users

  • 242

    Posts

  • 866

    Comments