Well i was converting big javascript code to C#. Everything’s done, but only this one is left:
static void ClampAngle (float angle, float min, float max) {
if (angle < -360)
angle += 360;
if (angle > 360)
angle -= 360;
return Mathf.Clamp (angle, min, max);
// Update is called once per frame
}
Error says: Since “DoesntMatterScriptName.ClampAngle(float, float, float)” returns void, a return keyword must not be followed by an object expression