Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
  • Help Room /
avatar image
-1
Question by TheShadowFighter · Oct 12, 2015 at 11:32 PM · errorbegginer

Begginer Here: probably a simple Error i can not resolve!

alt textThis is the error i got: Assets/ballcontrol.js(9,53): UCE0001: ';' expected. Insert a semicolon at the end.

This is my code: #pragma strict

var rotationSpeed = 100;

function Update () { var rotation : float = Input.GetAxis ("Horizontal") rotationSpeed; rotation = Time.deltaTime; rigidbody;AddRelativeTorque {Vector3.back * rotation}; }

I get that i need to put a semicolon as the 53rd characted of the 9th row, however that character is the 't' in Vector :/

pls help me!

screenshot-1.png (11.2 kB)
Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

2 Replies

· Add your reply
  • Sort: 
avatar image
0
Best Answer

Answer by meat5000 · Oct 13, 2015 at 12:00 PM

It is perfectly normal, upon fixing the listed errors, to be presented with a fresh list of errors.

This is because the compiler gets mixed up. When it hits the first error, from then on it can have trouble interpreting the remaining code, given that it is not what is expected.

This is why a missing semi-colon will present parsing errors as well as unexpected symbol errors, even though it is just one problem.

You problem is greater.

Line 9 needs a lot of work.

http://docs.unity3d.com/ScriptReference/Rigidbody.AddRelativeTorque.html

AddRelativeTorque is a function call so must be structured so.

 rigidbody.AddRelativeTorque ( PARAMETERS ); //ROUND BRACKETS

you have

 rigidbody.AddRelativeTorque; <-- You have ended the line early, then

 { Vector3.back * rotation } <-- used the wrong brackets.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image
1

Answer by landon912 · Oct 12, 2015 at 11:34 PM

You have a semicolon in the middle of that line where a period should be.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image TheShadowFighter · Oct 13, 2015 at 11:53 AM 0
Share

@landon91235 Still didnt fix the original error.That just added an extra error, this time it asked me to put a semicolon at the end of rigidbody.AddRelativeTorque.I have no other errors except for the one i specified above. alt text

screenshot-2.png (8.6 kB)

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

Unity Editor Error Build,Unity Editor Error build 0 Answers

I got a weird error: 0 Answers

Unity point light not working in some android devices . 1 Answer

I cant do any Painting in My Terrain.. but other choices work just fine! When i click the paint icon the screen goes all in black and then shows my unity project all in white 0 Answers

Can't launch my Project from Unity Hub 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges