Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error signal changed is already connected if instance of scene is open in editor #179

Closed
ydeltastar opened this issue Aug 1, 2024 · 4 comments · Fixed by #180
Closed
Labels
bug Something isn't working

Comments

@ydeltastar
Copy link
Contributor

ydeltastar commented Aug 1, 2024

Godot version

v4.3.rc

LimboAI version

v1.2-dev [0918521]

LimboAI variant

Module (custom editor or template build)

Issue description

Many task types such as BTCallMethod, BTSetVar, BTCheckAgentProperty, and BTPlayAnimation, give a signal already connected error when I load the project in the editor.

This only happens when I have a scene with a behavior tree, it is instanced in a parent scene, and both child and parent scenes are open when the project loads.

Signal 'changed' is already connected to given callable 'BTCallMethod::emit_changed' in that object.
Signal 'changed' is already connected to given callable 'BTSetVar::emit_changed' in that object.
Signal 'changed' is already connected to given callable 'BTCheckAgentProperty::emit_changed' in that object.

How to reproduce

  • Create a parent scene.
  • Create a child scene with a BTPlayer and a BTCallMethod task and instantiate it in the parent scene.
  • Make sure both scenes are open in the editor and Project > Reload Current Scene
  • It will raise signal errors

MRP: limbo-signal-error.zip
Open "main.tscn" and "cube.tscn" and reload the project.

@ydeltastar ydeltastar added the bug Something isn't working label Aug 1, 2024
@limbonaut
Copy link
Owner

I couldn't reproduce it even with the help of MRP. There must be some other piece missing here. But I can trace it using your error log. Let's see if I can fix it this way.

@limbonaut
Copy link
Owner

@ydeltastar
Can you confirm if #180 resolves this issue?
You can grab a build here.

@ydeltastar
Copy link
Contributor Author

Strange, I can reproduce it in any project. It looks like the order matter, "main" should be the first in the scene tabs and "cube" the last. It doesn't give an error when I invert the order.

I tested the artifact and it fixed the issue. Thanks!

@limbonaut
Copy link
Owner

Merging then. Thanks for reporting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants