Quantcast
Channel: Questions in topic: "error"
Viewing all articles
Browse latest Browse all 7934

Help with UCE0001: ';' expected. Insert a semicolon at the end.

$
0
0
The error message says that the error is at 33,61. the issue being that line 33 ends at col.58, with a semicolon. Any assistance would be very much appreciated, thanks. EDIT: Due to the pragma strict not being in the code preview here, the error would appear on line 31 here. #pragma strict var rotationSpeed = 100; var jumpHeight = 8; private var playOnce = true; var Hit1 : AudioClip; var Hit2 : AudioClip; var Hit3 : AudioClip; private var isFalling = false; function Update () { //Ball Rotation var rotation : float = Input.GetAxis ("Horizontal") * rotationSpeed; rotation *= Time.deltaTime; GetComponent.().AddRelativeTorque (Vector3.back * rotation); if (Input.GetKeyDown(KeyCode.W) && isFalling==false) { GetComponent.().velocity.y = jumpHeight; playOnceTrue(); } isFalling= true; } function OnCollisionStay () { if (playOnce == true) { var theHit = Random.Range(0,4); if (theHit ==0) { GetComponent.() clip = Hit1; } else if (theHit ==1) { GetComponent.().clip = Hit2; } else { GetComponent.().clip = Hit3; } GetComponent.().Play(); playOnce = false; } isFalling=false; } function playOnceTrue() { yield WaitForSeconds (0.5); playOnce = true; }

Viewing all articles
Browse latest Browse all 7934

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>