I want to take this value from “CarController” to another script “AnotherScript”:
public float CurrentSpeed { get; private set; }
Is it possible to do that if “CarController” is C# (the value above) and “AnotherScript” is writen in javascript ?
I tried with GetComponent, something like that:
var CurrentSpeedInstance = GameObject.Find("Car").GetComponent(CarController);
var CurrentSpeed : float;
CurrentSpeed = CurrentSpeedInstance.CurrentSpeed;
And it gives me this error:
'CurrentSpeed' is not a member of 'CarController'.