Open Scony opened 1 year ago
This has nothing to do with CheckBox being local_to_scene
by default, but it was like that since a503f8aadcb8cbc85bde589fb25ea06e599b367b
Seems like copying a local_to_scene
resource makes it unique. It's a new thing, it wasn't like that before.
It works correctly if you duplicate the node with the resource.
@KoBeWi This is caused by the logic added in #59472, since this ends up running Make Unique on the pasted resource. Here's some debug prints:
print_line(edited_resource->is_built_in()); // true
print_line(edited_resource->get_path()); // ""
print_line(EditorNode::get_singleton()->
get_edited_scene()->get_scene_file_path()); // "res://node.tscn"
The resource has an empty path, which breaks this logic. After saving, the resource's path is filled, and the logic works as expected.
Godot version
4.0 beta (master @ 14.01.2023)
System information
Linux Manjaro
Issue description
When trying to create radio buttons one has to create
ButtonGroup
resource and copy-paste it to other nodes from the group.However, since the
ButtonGroup
resource islocal_to_scene
by default at the moment, simple copy-pasting won't work.local_to_scene
will make copy-pasted resource actually different.Therefore to make radio buttons working, one has to remove
local_to_scene
flag fromButtonGroup
resource and then copy-paste.Steps to reproduce
Control
sceneCheckBox
ButtonGroup
on 1stCheckBox
ButtonGroup
resource from 1st to 2ndCheckBox
Minimal reproduction project
N/A