godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
89.2k stars 20.22k forks source link

Editing sub scenes of control nodes is not trivial #21620

Closed QbieShay closed 5 years ago

QbieShay commented 6 years ago

Godot version: 3.1 custom

Issue description: When making multiple scenes for the GUI, using the default viewport size is not always wanted. I have an object that needs to stay in a small square on the screen. That small square changes size and it is animated. The foreign scene that gets instantiated needs to be anchored as full rect. The problem arises when i want to edit the foreign scene on its own: if i use the full rect the control get stretched all over the viewport size, meaning that some things, like label text, does not show in an accurate way.

Proposal: In the view menu, be able to specify a custom viewport size for the current scene.

Zylann commented 6 years ago

I had this situation too but I got over it by just not defining the root anchors in the subscene (leaving some convenient default for edition), and instead choosing them in their "host" scene. It just made sense to me because a control meant to be integrated should not assume how its anchors should be (I design such items in a resizeable way so that doesnt matter), because that's the "host" to decide that in the appropriate context.

A menu to hot-swap resolution could be useful though, especially if your game is resizeable.

QbieShay commented 6 years ago

@Zylann good point. I will try to design with that in mind.