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
Currently Godot only supports trailing default values. If you want to only override 'some_count', you have to override all of them, e.g. start_explosion(1.0,55,1000000)
You then lose the ability to use the functions built-in default values. What would be better would be named or optional parameters, e.g.
Describe the feature / enhancement and how it helps to overcome the problem or limitation:
As above
Describe how your proposal will work, with code, pseudocode, mockups, and/or diagrams:
As above
Is there a reason why this should be core and not an add-on in the asset library?:
Optional parameters are a valuable feature of modern languages and a time-saver. Otherwise, you have to resort to using dictionaries and other methods which will be more complex to implement and hinder performance in the same way.
The text was updated successfully, but these errors were encountered:
Describe the problem or limitation you are having in your project:
Pretend you have a method like this:
Currently Godot only supports trailing default values. If you want to only override 'some_count', you have to override all of them, e.g.
start_explosion(1.0,55,1000000)
You then lose the ability to use the functions built-in default values. What would be better would be named or optional parameters, e.g.
start_explosion(some_count=100000)
start_explosion(,,,100000)
Describe the feature / enhancement and how it helps to overcome the problem or limitation:
As above
Describe how your proposal will work, with code, pseudocode, mockups, and/or diagrams:
As above
Is there a reason why this should be core and not an add-on in the asset library?:
Optional parameters are a valuable feature of modern languages and a time-saver. Otherwise, you have to resort to using dictionaries and other methods which will be more complex to implement and hinder performance in the same way.
The text was updated successfully, but these errors were encountered: