Have a dedicated .import
folder to enable non-standard asset importing
#12177
Replies: 1 comment 6 replies
-
Right now we have import scripts that can - taking your example - allow you to import a model as an skeleton. However, you need to set it per imported resource. Of course, it is also possible to make import plugins, but those are more work. Now, given that you want to place files in a particular folder to have them be handled in an special way, this is what comes to mind: We could have an special name for an import script, so that Godot uses it automatically for any file that is added to the same folder. That way - again taking the example - we could have a folder for models from which we only want the skeleton, there place an import script with an special name, and when we add a model to that folder Godot will automatically import it with that import script. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Godot's import process is fairly rigid when it comes to importing meshes/animations etc. The process is basically import .fbx/.glb/etc. -> get scene you can instantiate. Which is extremely simple and quick if that serves your purpose, but in the event you want to do something more complex or non-standard it's not simple to import your files in a different manner.
I am making a colony sim and have the most experience with Unity and Unreal prior to trying Godot where when you import a file like an FBX you get a list of resources instead of a scene. And then what you do with those resources is up to you as a developer. What I would like to be able to do is have a single skeleton rig that I can apply different meshes and animation libraries to depending on what I am doing.
Enter my proposal, a dedicated folder for importing standardised assets (glb/fbx/obj/etc.) to be converted to Godot specific resources (AnimationLibrary, Mesh, Skeleton, Textures). The goal with a import folder, which for simplicity I will refer to as
.import
from now on, is that it is a dedicated location for you to import resources you want to break down. It would have default settings for where to save different types of resources, but all of which are overwritable so the user can decide where they are saved to. For files that are reasonably easy to diff then updating the import should also update the generated resource. For example, if you update your GLB to include a new mesh, then when you save the file in.import
Godot could in theory detect and export only the additional mesh.Since all resources from the
.import
folder would be converted to Godot specific resources it can simply be discarded on publish as it won't be needed anymore. And also since this would be a dedicated folder for this kind of behaviour is doesn't remove or affect the current standard way of importing files by dragging them into the assets folder and then getting a scene returned to the user. And finally, as a more opinion-based benefit, having everything in a dedicated.import
folder creates a separation of concerns that makes project asset management much clearer in my head.Would love to hear feedback.
Beta Was this translation helpful? Give feedback.
All reactions