I’m making an FPS controller and I want more than one axis/button to trigger a boolean.
I tried doing this: if(Input.GetButton(“Horizontal”) && Input.GetButton(“Vertical”)){
isWalking = true;
}
But I needed to input both to trigger it.
I’ve also tried doing this: if(Input.GetButton(“Horizontal”) ^ Input.GetButton(“Vertical”)){
isWalking = true;
}
They both work, but only when one of them is active.
Is there some kind of “or” expression or something like that? I want one of them and both of them to work.