Namespace Issue but code still works

Hey all. Just implementing the code from the weapon sensitivity lecture and I keep getting namespace errors while adding UnityStandardAssets.Characters.FirstPerson. Thing is, the code for sensitivity works in game. Is this a Visual Studio Code issue? Something to do with me using a newer version of Unity?

namespaceissue

Well I solved my own issue though I had to, since Rick changes up how weapon zoom is handled a few lectures later and I wanted to keep going!

When the zoom script is moved to a weapon directly it totally breaks whatever was allowing it to work despite the errors. So I came up with a solution that works but I’ll probably need to work around it later with weapon switching and probably more stuff.

This stays on the player

This goes on each weapon and its customizable. Don’t know how it will hold up to switching weapons and how findobjectoftype will work with different variables. Maybe some sort of reset when weapons are switched?

Definitely still open to fixes or other workarounds!

Ok Rick’s next lecture got it all working lol. Got into my own head with this I guess. Solved lol

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms