+2 votes

So I have a couple of GraphNodes as children of a GraphEdit node.

I allowed them to connect by using the connection_request() signal in GraphEdit, this signal is emitted when the user attempts to graphically connect two nodes using the mouse. It works as intended.

However, how do I allow the user to disconnect two slots after a connection has been made? It appears there is adisconnection_request() signal, but I don't know what action emits this signal, so I'm unable to disconnect any nodes!

Any ideas on how disconnections are implemented?

in Engine by (45 points)

1 Answer

+1 vote

Call set_right_disconnects( true ) on the GraphEdit, then drag the connection away from the input slot.

by (1,086 points)

You can also do this from the inspector!

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.