I need help! a trouble code says Assets/MeleeSystem.js(3,20): UCE0001: ‘;’ expected. Insert a semicolon at the end.
I DON’T KNOW WHAT LINE THEY ARE REFERRING TO! Help would be much appreciated so I can get this FPS underway.
I need help! a trouble code says Assets/MeleeSystem.js(3,20): UCE0001: ‘;’ expected. Insert a semicolon at the end.
I DON’T KNOW WHAT LINE THEY ARE REFERRING TO! Help would be much appreciated so I can get this FPS underway.
I’m not too familiar with UnityScript, but this looks suspect. Notice the equal sign.
// Incorrect
var TheDamage : int - 50;
// I think you want one of these?
var TheDamage : int = 50;
var TheDamage : int = -50;
Also, the line number is the 3 in MeleeSystem.js(3,20). That means row/line 3, column/character 20.
Does character 20 include white space from indents?
Yes. Indents are usually 4 spaces. If you’re using a monospaced font, column 20 should be the same column of characters on the entire document.
In this specific example, the compiler got to the negative sign and decided something was wrong.
// Negative sign doesn't make sense!
var TheDamage : int - 50;
// Compiler is expecting something like this.
var TheDamage : int;