On Demand Resources and Asset Catalogs

I'm having a problem getting On Demand Resources to work correctly in my development environment. This particular app (an iOS app, not a tvOS app if that matters) has may different pre-rendered animations that I have loaded as images in an asset catalog (grouped in a simple 2-level folder structure). I've gone through and tagged all the images appropriately and even configured a default group of them to be installed with the app. However, when I run the app I get several warnings that say "CUICatalog can't locate asset pack". I noticed there aren't any files listed in the OnDemandResources.plist either (I clipped it down for space, but each entry is the same):


OnDemandResources.plist


Notice the empty array under NSBundleResourceRequestAssetPacks? The AssetPackManifestTemplate.plist does point to the files for an asset pack though:


AssetPackManifestTemplate.plist


I looked and the files pointed to by the AssetPackManifestTemplate.plist exist, but the only files in that directory are Assets.car and Info.plist. I assume the Assets.car has the image assets for the animation tagged animation_01.


To compare, I copied a small sample set of images to my project outside the asset catalog and tagged them with a new tag. This time the images get loaded without incident. However, I'd rather not have to pull apart all the images in my asset catalog just to get ODR working. I'd also like to take advantage of slicing which it looks like only works if you configure your images in an asset catalog.


Has anyone else gotten ODR to work in an iOS app when tagging images in an asset catalog? What did you do to get it to work? Is there maybe something I have misconfigured in my development environment? Any ideas of things to look at or double check would be helpful.

Hi


Don't know if this is still an issue for you but I have this working in my iOS game.



Basically you create a folder inside the Blah.xcassets top level. Click the + button to do that, and choose "folder". Put the ODR tag onto that folder.


Then inside the folder put your sprite sheets, data files and whatever. They will then inherit the ODR tags.



You can then debug these, check the sizes of them and so on by looking at the Storage tab of the Debug view when running your app in debug mode (via a USB cable). Note this won't work on the Simulator. Never use the simulator for this stuff.

On Demand Resources and Asset Catalogs
 
 
Q