Most Optimized way to Use GetZipPackageDefinitions?


#1

Hi.

ZipPackageDefinitions allows the user to upload Game Assets in a compressed format.
What we do to fetch those assets is to use GetZipPackageDefinitions in Unity, Download it using UnityWebRequest, Unzip the File, Delete the Source file(zip), then reference those downloaded unzipped assets. The problem is that I this may be an unoptimized way to fetch assets. it is counter intuitive to unzip it after downloading. Is there a way to upload files directly without compressing them? Is there a way to download the package in an Unzip format directly? Or are there any other ways to optimize this aside from downloading then unzipping?

Thank you!


#2

Hi Kenneth,

There is currently no way to download individual Assets from within a ZipPackage at the moment I’m afraid. We store the packages zipped-up on our CDN opposed to storing the individual files to save on network load and to make the download to the client device as quickly as possible (The priority here was to minimize the delay in downloading the assets and use the least amount of Mobile Network Data.) and is unlikely to change in the near future.

“The problem is that this may be an unoptimized way to fetch assets. it is counter-intuitive to unzip it after downloading” - Have you encountered any issues during this process?

Many Thanks,
Steve