I don’t know how to fix this error I keep getting
"Assets/Standard Assets (Mobile)/Scripts/Joystick.js(90,20): BCW0012: WARNING: ‘UnityEngine.GameObject.active’ is obsolete. GameObject.active is obsolete. Use GameObject.SetActive(), GameObject.activeSelf or GameObject.activeInHierarchy.
"
I’m not even using the mobile assets and the error is there? How do I fix this.
Well, you clearly have the Standard Assets for Mobile, which contains the joystick script. Otherwise that (Assets/Standard Assets (Mobile)/Scripts/Joystick.js) wouldn’t show in the log. If you are using them or not doesn’t matter since the code will still get compiled.
The log message also suggests how you should fix the issue:
Use GameObject.SetActive(), GameObject.activeSelf or GameObject.activeInHierarchy.
If you aren’t using the mobile assets, then you should consider removing them from your project.
If you want to work around the issue, then remove any references to gameObject.active etc, and replace them with GameObject.SetActive(), GameObject.activeSelf or GameObject.activeInHierarchy as suited.
The log is displayed because that code is referencing members that have been deprecated.