nathanhoad / godot_dialogue_manager

A powerful nonlinear dialogue system for Godot
MIT License
2.04k stars 161 forks source link

Dialogue balloon panel rendering scene (or sprites) inside itself #628

Closed mihailides closed 1 month ago

mihailides commented 1 month ago

Describe the bug The dialogue balloon is rendering a sprite that I have inside the same scene. (I can see the sprite in the background, and once the balloon appears, it renders inside of that as well). Debug printing inside of the sprite seems that it only loads once.

Affected version

To Reproduce Steps to reproduce the behavior:

(Basically straight out of the tutorial)

  1. Create a scene with a Node2D
  2. Attach one child - a Sprite2D and add a resource
  3. Add a script to the root node, the sprite, or to another node2d as a child
  4. Create the balloon programmatically inside _unhandled_input (e.g. DialogueManager.show_dialogue_balloon(dialogue_resource, "start")
  5. Add a custom balloon via project -> tools -> create copy of dialogue example balloon..
  6. Click on Balloon.tscn -> Balloon control node -> open the theme
  7. In the default preview, change type to panel and select the StyleBoxFlat theme
  8. Reduce opacity
  9. Run and notice sprite has rendered into the panel

Expected behavior Not to have a sprite rendered inside the panel, not sure if I've missed some kind of vital step but I made a whole project from scratch with just these steps to check and had the same issue. It does this with all sprites I add to the scene.

Screenshots image image

Selenyhr commented 1 month ago

I've had the same thing with the Vulkan mobile renderer due to this Godot bug.

Since the Panel for the example balloon is also using Clip + Draw, it will trigger this behavior for Godot 4. This seems to have been resolved for Godot 4.3. Meanwhile, changing the renderer to Forward+ solves the issue for current 4.X :)

nathanhoad commented 1 month ago

Closing this as it's not technically a bug in Dialogue Manager itself.

mihailides commented 2 weeks ago

I've had the same thing with the Vulkan mobile renderer due to this Godot bug.

Since the Panel for the example balloon is also using Clip + Draw, it will trigger this behavior for Godot 4. This seems to have been resolved for Godot 4.3. Meanwhile, changing the renderer to Forward+ solves the issue for current 4.X :)

Thankyou for this, you're amazing!