You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the problem or limitation you are having in your project
I often want to use tools from the asset library (e.g. sound manager, scene manager). Such assets will typically provide an autoload which you can access in gdscript to interface with the various functions of the asset. The code completion for this though is poorly organised, with various node-specific functions at the top, and an impossibly long scroll list of functions, signals, variables and enums I don't care about. I would like to learn the functionality of the asset by browsing through it's functions, but these interesting functions are buried in amongst hundreds of other irrelevant options. Here's an example of the code completion for the SoundManager asset:
Code.Completion.mp4
Describe the feature / enhancement and how it helps to overcome the problem or limitation
This could be in the form of a new @ important annotation which places the function / variable above others in code completion. Asset creators could use this annotation to highlight important functions and variables. This annotation could also have an int order, however this could lead to inconsistent ordering between various assets. Having just an important or default level of priority is enough to separate important things from everything else in code complete. No options are added nor removed, only things marked with @ important are brought to the top of code completion.
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
As described above. Adding the @ important annotation before any function, variable or anything else will result in that being sorted ahead of other options in code completion. Asset creators can use this to highlight the important functions, making it easier to learn what an asset can do.
If this enhancement will not be used often, can it be worked around with a few lines of script?
No.
Is there a reason why this should be core and not an add-on in the asset library?
This enhances the experience of using assets, giving a way to see important functions separate from the hundreds of others.
The text was updated successfully, but these errors were encountered:
To me, it sounds like we should fix/improve autocompletion rather than allowing specific add-ons to prioritize their completions. If add-ons prioritize their methods/properties without good justification, it won't improve the situation at all.
I would like to learn the functionality of the asset by browsing through it's functions,
You can use the Search Help button in top-right corner of the script editor. It displays classes registered by add-ons too 🙂
This is actually a bug with the autocompletion sorting. It is supposed to show methods defined in the autoload above options defined in the base type. The combination of godotengine/godot#85239 and godotengine/godot#85215 should fix the sorting problem.
Seems like the need for this solution comes from a bug rather than a limitation that needs a special feature to resolve. Please give 4.3 dev 3 a try later this month and see if it's working better/closer to what you expect. For now, let's close this as resolved.
Describe the project you are working on
Jam projects with godot
Describe the problem or limitation you are having in your project
I often want to use tools from the asset library (e.g. sound manager, scene manager). Such assets will typically provide an autoload which you can access in gdscript to interface with the various functions of the asset. The code completion for this though is poorly organised, with various node-specific functions at the top, and an impossibly long scroll list of functions, signals, variables and enums I don't care about. I would like to learn the functionality of the asset by browsing through it's functions, but these interesting functions are buried in amongst hundreds of other irrelevant options. Here's an example of the code completion for the SoundManager asset:
Code.Completion.mp4
Describe the feature / enhancement and how it helps to overcome the problem or limitation
This could be in the form of a new @ important annotation which places the function / variable above others in code completion. Asset creators could use this annotation to highlight important functions and variables. This annotation could also have an int order, however this could lead to inconsistent ordering between various assets. Having just an important or default level of priority is enough to separate important things from everything else in code complete. No options are added nor removed, only things marked with @ important are brought to the top of code completion.
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
As described above. Adding the @ important annotation before any function, variable or anything else will result in that being sorted ahead of other options in code completion. Asset creators can use this to highlight the important functions, making it easier to learn what an asset can do.
If this enhancement will not be used often, can it be worked around with a few lines of script?
No.
Is there a reason why this should be core and not an add-on in the asset library?
This enhances the experience of using assets, giving a way to see important functions separate from the hundreds of others.
The text was updated successfully, but these errors were encountered: