Why does Godot create/use .import files?

Hi there!

Why does Godot create .import files next to every resource it imports?

Couldn’t this information better be stored in an SQLite database, without cluttering the filesystem? (Might it not also be quicker?)

I have 6000 PNG files from a number of different animations (because I need transparency, and this seems to be the only way to achieve it), and it obviously creates another 6000 .import files, and it is taking ages to import.

I managed to think about this problem, find this forum via Google, sign up, and post this while it was running and it’s still at 80%.

Any ideas (perhaps from the devs)?

I’m not a dev on Godot, so I don’t actually know! However, I suspect this answer in the FAQ about the .uid files is also the reason they choose to use .import files :man_shrugging:

1 Like

I could be wrong, but my guess is that using SQLite would create dependency that the team wants to avoid. It’s already impressive how smoothly Godot works across so many different pieces of hardware.

Also an SQLite database is a single binary file, it would be an absolute NIGHTMARE to deal with that with something like Git

4 Likes

That was a point Gemini made as well, that it would be a nightmare for version control. I didn’t think of that, and it’s a very good point.

Use animation sheets to reduce the number of files.

2 Likes

Excellent, thanks for the suggestion!