-
-
Notifications
You must be signed in to change notification settings - Fork 97
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
Add a method dropdown list to the signal connection popup #5193
Comments
We have a big PR that addresses this among other things, but it's in a bit of a limbo: godotengine/godot#27988. However, its implementation of the feature would be preferable to what is proposed here. |
Ah, that is definitely what I am looking for, thanks for pointing that out. Wasn't aware that there was already an on-going PR for this, so I'll close this thread now. |
Let's keep it open. A proposal can be closed when the feature is implemented and merged. And in this case that PR may need to be salvaged and implemented in steps, one of which can be adding a method selector. PS. Unless this a duplicate, then we can indeed close it. But I don't see anything linked in the PR. |
Might be closable, godot 4 supports this. |
Describe the project you are working on
A 2D platformer/action game with a lot of signal connections
Describe the problem or limitation you are having in your project
In my projects, most signal connections are connected to existing methods, such as
Character::on_hit
->HPBar::update_hp
orEnemy::on_damage
->Shaker::shake
, as opposed to creating unique methods tied to signals likeHPBar::on_Character_on_hit
.When connecting signal via the signal connection popup, this becomes cumbersome as I would have to type out the specific method name each time. Furthermore, if there is a typo, it would create an entirely new method.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
Adding a drop-down to select the method from the target node would make this process much more convenient and ensures that there are no typos.
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
A simple drop-down (OptionButton) popup activated by a button next to the method TextField should be sufficient.
I considered the idea of replacing the text field with the drop-down entirely and adding "New method..." as the final option which then displays the text field, but this would make the UI less convenient for users who prefer connecting signals the old way (creating new methods). Since I'm unsure what most user would prefer, I think the example above would be the most appropriate implementation.
The screenshot is from a basic implementation I made off the 3.5 branch: poohcom1/godot@8f8f49f
If this enhancement will not be used often, can it be worked around with a few lines of script?
Not really, as this is about the editor.
Is there a reason why this should be core and not an add-on in the asset library?
This is a simple editor change that would be applicable to most projects.
The text was updated successfully, but these errors were encountered: