I wondered if it was possible to somehow modify the asset loading systems to allow for loading assets from inside archive files such as zip/rar or some other custom archive type. Ideally, it would look something like PhysFS, with a filesystem in memory where different archives may be mounted at different locations in the tree but the loader transparently accesses the asset data in the corresponding archive in the physical filesystem.
My first thought after skimming through some of the source code for the
DefaultLoader type is to implement the
LoaderIo trait from the distill crate and then essentially copy-paste the code for
DefaultLoader but using my
LoaderIo type (which would implement what I’m looking for). Is this an appropriate way to do this or is there some other way I missed that may be easier or more idiomatic somehow?