|
i am making a 2d platformer that involves jumping but when i put my code in it gives me this error: Unknown identifier moveDirection. but i know it should a known identifier because it's highlighted orange! my script: var jumpSpeed = 5.0; if(Input.GetKeyDown("UpArrow")) { moveDirection.y = jumpSpeed; } p.s. please help!
(comments are locked)
|
|
It's unknown because you haven't defined it anywhere. You need to define variables before you can use them. what do i need to put in after i type var moveDirection = ? if i put a number it comes up with an error.please comment back! thanks!
Aug 19 '10 at 07:35 PM
john 2
(comments are locked)
|
|
Try this.
(comments are locked)
|
