Variable declaration is different, including access and type specification.
JavaScript: The type specification is not necessary.
public var playerLife = 1; // a public var int playerLife = 2; // **private** access is default public GameObject myObj; // a type is specified (no value assigned)
C#: The type is always stated when declaring a variable.
var playerLife = 1; // **public** access is default private var playerLife = 2; // a private var var myObj : GameObject; // a type is specified (no value assigned)
18.227.134.133