1

So in every game engine I program, with a steering controller, the gas is positive values on the Y-axis and the brakes are negative values. Basically, pressing the gas sends a Y value of 0 to 1, and pressing the brake sends 0 to -1.

How can I tell if the brake is pressed at the same time as the accelerator? A value of .5 could mean the gas pedal part way down, or all the way down with some brake applied.

Is there a way to determine if the brake is pressed?

Tanoshimi
  • 463
  • 1
  • 4
  • 11

0 Answers0