Chanelno5
Chanelno5

Reputation: 11

Unity 5 keeps giving me errors

since I've downloaded Unity 5. I have encountered countless errors. All are alike so I googled it. I found a common answer but I don't know what they mean by it.

errors:

Assets/6by7/ProGrids/Scripts/Editor/ProGrids_Base.js(5,42): BCE0144: 'UnityEngine.Resources.LoadAssetAtPath(String, System.Type)' is obsolete. Use AssetDatabase.LoadAssetAtPath instead (UnityUpgradable)

Assets/6by7/ProGrids/Scripts/Editor/ProGrids_Base.js(6,40): BCE0144: 'UnityEngine.Resources.LoadAssetAtPath(String, System.Type)' is obsolete. Use AssetDatabase.LoadAssetAtPath instead (UnityUpgradable)

Assets/6by7/ProGrids/Scripts/Editor/ProGrids_Base.js(7,41): BCE0144: 'UnityEngine.Resources.LoadAssetAtPath(String, System.Type)' is obsolete. Use AssetDatabase.LoadAssetAtPath instead (UnityUpgradable)

Assets/6by7/ProGrids/Scripts/Editor/ProGrids_Base.js(8,46): BCE0144: 'UnityEngine.Resources.LoadAssetAtPath(String, System.Type)' is obsolete. Use AssetDatabase.LoadAssetAtPath instead (UnityUpgradable)

This is the common answer: It basically tells you what to do, instead of blahblah.renderer you now need to do, blahblah.GetComponent(Renderer). It looks a little more work, but it is more generalised for all components now, and more obvious what the code used to do in the background.

I don't know what it's telling me to do.

Upvotes: 0

Views: 270

Answers (1)

Claudio Cortese
Claudio Cortese

Reputation: 1380

It's telling you exactly what you already said. You should write and use

blahblah.GetComponent<Renderer>()

instead of

blahblah.renderer

You should check out UNITY 5: API CHANGES and this.

Upvotes: 5

Related Questions