Beginner Question - Load a single standard asset in Unity 5, not every asset

Hi,

My goal is to load the 1st person character controller from the standard assets into my game. I do not want to load every standard asset, because I think it will make my file saving too heavy. However, when I uncheck the other assets on pre-load, it causes errors.

Here is specifically what I’ve tried:

I go to Asset store, Download, Standard Assets 1.0, then I click Import.
It opens a checklist of components to import.
I deselect all, then click 1st person character…

So basically I only load the 1st person character controller. I immediately get this error:

Assets/Standard Assets/Characters/FirstPersonCharacter/Scripts/FirstPersonController.cs(3,27): error CS0234: The type or namespace name CrossPlatformInput' does not exist in the namespace UnityStandardAssets’. Are you missing an assembly reference?

I suspect there are more items I need to import… I’ve been experimenting / failing… but I do not have the experience to really understand what I am doing and know which additional components to import.

I’ve tried also importing the entire character folder… but it still gives errors. I think I remember in Unity 4, being able to import a single item… and having it be self sufficient.

Thank you for your thoughts.

Try the whole first person character folder. Then any errors like the above, import the scripts one by one ( like for your example above, find CrossPlatformInput.cs and import it). Then keep finding scripts it identifies in the errors and import them one by one until your project compiles again.

Also as a side note, it doesn’t matter how many assets you have in your project in terms of your game build size. When you create a build, only assets that are referenced in a scene inside your build settings or in the Resources folder are included in the build. So you can have gigs and gigs of files in your project and they won’t make your actual game build any bigger unless you are using them.

2 Likes

Thank you goonter.

One at a time I followed the errors and it now works!

Good to know if I add extra stuff, it only counts to my project if actually used.

Thanks again!!

It’s good to know that! Thank you, sir! :slight_smile:

Funciona perfectamente! :slight_smile: