Right now I have these lines of code that detect if the “up” arrowkey is pressed;
bool arrowpress = Input.GetKey (“up”);
This is then followed by an If…statement that, if true, will play a sound.
However, I want to play a sound if either “up”, “down”, “left” or “right” is pressed. Is there any way I can do this one one bool? I.e. something along the lines of:
bool arrowpress = Input.GetKey (“up”) OR (“down”) OR (“left”) OR (“right”);
Much obliged…