Noob trap "get or set accessor expected" on Camera

If anyone gets this error on the Camera type declaration know that it is not related to that line I got it because I failed to put the () after declaring my GetAirRay() method. Without the () this line becomes a public field (variable) of the class, and unity was excpecting a way to access this variable apparently.

Anyway, as soon as I put in the () Unity was happy. The error went away.

Privacy & Terms