ThePat02 / BehaviourToolkit

A collection of tools for AI Behaviour in the Godot 4 Game Engine!
MIT License
303 stars 12 forks source link

Sometimes a scene needs to be reloaded before you can edit / reset properties after adding a new node. #48

Open ThePat02 opened 7 months ago

ThePat02 commented 7 months ago

image

Steps to reproduce:

  1. Create a new scene with a FSM or BT
  2. Add a node (for example the print leaf) via the UI
  3. Edit the exported property.

This problem doesn't exist when using the normal way to add nodes.

ThePat02 commented 7 months ago

@SirPigeonz can you try to reproduce this, if you got some free time?

SirPigeonz commented 7 months ago

@ThePat02 I tested it and I found few detials:

  1. You don't have to restart the scene, it's enouigh that you will add with normal method the same node somewhere then they fix...
  2. After fixing it this way all new nodes of the same type and different type added with UI work xD

Looks like a bug in the Engine... I will try to look into C++ code to check if they do something extra after adding nodes with default means. - my Godot build env is broken and I don't have time now to fix to find code where nodes are added xD I will try that later. It looks like engine bug tho.

ThePat02 commented 7 months ago

@ThePat02 I tested it and I found few detials: You don't have to restart the scene, it's enouigh that you will add with normal method the same node somewhere then they fix... After fixing it this way all new nodes of the same type and different type added with UI work xD

That's what I found too. Very annoying

ThePat02 commented 7 months ago

Or the nodes are some not added correctly via the UI...

ThePat02 commented 7 months ago

Someone on the discord suggested, that this could be either not having assigned default values or not notifying the editor that property have changed. Will look into it later today.

ThePat02 commented 7 months ago

Someone on the discord suggested, that this could be either not having assigned default values or not notifying the editor that property have changed. Will look into it later today.

Didn't fix it...