Exception when trying to load a sprite from SpriteAtlas in Version 1.8.4

Hi,

I am using Unity 2019.2.19f1 . I recently upgraded the addressable assets package to 1.8.4 expecting improved behavior but it broke our game !
It has problem with loading AssetReferenceAtlasedSprite . It throws this exception: InvalidKeyException

Steps to reproduce :

  1. Create an atlas an mark it as Addressable , add a sprite to it
  2. Create a script for loading the sprite through defining a public field of type AssetReferenceAtlasedSprite
  3. Assign the sprite to the field in Inspector
  4. Hit Play in The Editor so that the script tries to load the asset
  5. Exception thrown !

It is really frustrating that such a basic behavior that was working before is broken. I tried to load the sprite by hard coding the address using the Atlas[Sprite] notation but I didn’t work either. Only solution that I found working in this version is loading the sprite Atlas directly and then get the sprite through the SpriteAtlas Api.

I ended up downgrading to version “1.7.5” because it is much easier and less error prone to use AssetReferenceAtlasedSprite.

Sorry to hear you’ve ran into trouble! If you haven’t yet, could you submit a bug report with a repro project attached?

Thanks for your response. I’ll submit a bug report then.