godot-proposals icon indicating copy to clipboard operation
godot-proposals copied to clipboard

Allow us to strongly type packed scenes

Open Shadowblitz16 opened this issue 5 years ago • 17 comments

Describe the project you are working on: 3d Tower defense

Describe the problem or limitation you are having in your project: there is no way to strongly type packed scenes

Describe the feature / enhancement and how it helps to overcome the problem or limitation: can we have a some sort of generics for packed scenes that allow for strongly typed instancing

Describe how your proposal will work, with code, pseudocode, mockups, and/or diagrams: something like..

var scene : PackedScene(Spatial)

exporting generic packed scenes would also insure type safety in the inspector

If this enhancement will not be used often, can it be worked around with a few lines of script?: it would be used alot and no not safely

Is there a reason why this should be core and not an add-on in the asset library?: supports better code

Shadowblitz16 avatar May 02 '20 04:05 Shadowblitz16