I just started learning Unity and, I came across this code which I want to try. When I finished the it ends up: Assets/Input.js(3,19): BCE0019: ‘GetButtonUp’ is not a member of ‘Input’.
This is my code
#pragma strict
function Update(){
if (Input.GetButtonUp("Jump")){
Debug.Log("Done!");
}
}
if you very much have to have a script called “Input” in your project you’ll need to call the unityengine Input class with the namespace explicitly, i.e.
UnityEngine.Input.GetButtonUp(...
because you have a local class called Input it’ll assume you are talking about that, not the unityengine one. (not even sure unityscript allow this though! :()
of course the simplest solution is to call your script something else like “PlayerInput” or “InputHandler” or whatever.