End of the Resources folder

One of the key themes that permeated throughout Unite Melbourne was the general awesomeness of Asset Bundles. Pretty much every workshop I went to mentioned them.

One of the devs from Obsidian went as far as mentioning that the Resource folder should never be used, and that asset bundles were the way to go. And that Unity had recognised this and was planning to deprecate the Resources system all together.

So, was there a blog post I missed about the the deprecation? But anyway, I thought I’d start this thread as a last shout out to the Resources folder, and everything its done for us before we throw it ends up on the garbage heap of the Unity archive with SendMessage, the webplayer, OnGUI, flash builds and .ridgidbody.

Thanks Resources. You were great. Say hi to OnGUI for me, we were buddies back in the day.

3 Likes

I’ve still never used Asset Bundles, I love my resources when it’s needed (mainly) for Photon Networking.
Never use it outside of that honestly.

What makes Asset Bundles better than resources in general? I’m assuming speed efficiency.
Looks like Photon gonna have to Upgrade from using Resources to Asset Bundles (however they are even done).

Never used them so I don’t even have a clue on where to start with using them lol.

1 Like

I’d be happy if asset bundles rose up. I am using them for an experiment elsewhere and I love how they can important unity resources on the fly externally. If they move from resources to asset bundles then we knock out the model importing problem too.

What’s the current performance on importing asset bundles? I read a lot of scary things about them, and I don’t want this to be another webgl.

Internally, the Resources folder basically is an AssetBundle, it’s just one that is generated automatically for you during the build process - but in a very inflexible way (no incremental build, no control over compression, no variant support, no ability to split into multiple bundles, files are required to be in a particular place in your project, etc).

There’s a few things AssetBundles are still missing, like script-free building, but once we’ve sorted all of those things out then Resources will just be ‘a crappier AssetBundle’ and we’ll be looking to get rid of it. No timeline on this yet, though.

7 Likes

Except, Resource folder is very good for when you don’t know whether you need something or not. Also dynamically spawning prefabs, having only resource name (string) as a way to get it. It’s really useful, and I don’t see I could live with asset bundles which are limited (resources folder can have any type of stuff, bundles only certain types).

1 Like

You can do the exact same thing with AssetBundles.

As far as I know that’s simply not true; the resources folder is an AssetBundle so it wouldn’t be possible for it to store something that can’t be packed into an AssetBundle. Can you give an example of what you’re talking about?

Custom binary data which I can store in Resources and load using textbytes or whatever it was called.

That’s supported by AssetBundles.

1 Like

How about not having to load it and just use Resources.Load instead of first loading asset bundle then using AssetBundle.LoadObject?

1 Like

well, OK then. :slight_smile:

Please provide API so us non-coders can use it please. :slight_smile:

Good riddance, it always seemed a little hacky.

2 Likes

Is SendMessage being discontinued? I didn’t find anything on that matter.

I wouldn’t thing so. Other unity elements like animation events rely on it.

1 Like

Resources.Load was only available via code. :wink:

2 Likes

You just blew my mind.

If I was able to figure this one out with a few minutes of research then it’s not that bad :stuck_out_tongue:

I’m glad asset bundles are a priority. That’s going to make modding a bigger part of unity games! I hope.

1 Like

How about implementing your own wrapper that replicates Resources but supports multiple AssetBundles? If you wanted it could even default to a specifically named bundle in the event that you don’t specify the bundle’s name.

holds my resource folder tight

Never let go resources… never let go…

4 Likes

5 Likes

SendMessage is still around. But the job it did is mostly done by ExecuteEvents now. I don’t see it disappearing entirely. But it’s a lot less useful then it was.