I trying to get my head around array's in Unity JavaScript. But all ever get is this error message.
Assets/test1.js(3,25): UCE0001: ';' expected. Insert a semicolon at the end.
Unity 4.3.3f1
(I am new Unity, so please be nice)
#pragma strict
var varTestArray : float[2];
function Start () {
varTestArray[0]=2.0;
varTestArray[1]=4.1;
varTestArray[2]=6.2;
for(varloop=0; varloop<3; varloop++)
{
Debug.Log("Value "+varloop+" : "+varTestArray[varloop]);
}
}
function Update ()
{
Debug.Log("U "+Time.deltaTime);
}
function FixedUpdate()
{
Debug.Log("F "+Time.deltaTime);
}
function LateUpdate ()
{
Debug.Log("L "+Time.deltatime);
}
function OnRenderObject()
{
Debug.Log("R "+Time.deltatime);
}
↧