maktoobgar/scene_manager

Canvas Layer issue

joaopedrosgs opened this issue · 2 comments

Currently, the canvas in the SceneManager has a layer index of 1. If a game uses a any canvas with the same index or greater, the fade animations will play below the user interface.

If possible, it would be nice to be able to set the layer of the SceneManager.

Anyway, thanks for your work. This is the most complete scene manager I've ever used!

Hello,
Thanks for taking your time to open an issue.
Sorry to answer so late too, I just don't have much free time right now.
I will come at this about 2 weeks later and will go through with it. 🙏

Hi again,
I'm back.
I am thinking about this but I'm not actually getting anywhere, help me here.
Do you suggest that we add this feature into the UI of the Scene Manager so that the developer can change the layer index of the transition from the UI?
But... I can just make the layer index higher if the problem is just sometimes the content goes on top of the transition scene.
But if the case is to have more control over that, we can add a config variable named layer_index in the GeneralOptions:

class GeneralOptions:
	var color: Color = Color(0, 0, 0)
	var timeout: float = 0
	var clickable: bool = true
	var add_to_back: bool = true
	# new variable
	var layer_index: int = 1

Then we can change the layer index in each transition, even the first transition.
How about that?