To stop a vehicle you need to accelerate in opposite direction than vehicle is actually moving. That is OK. What is not OK - if you move forward and press backwards to break and keep that button pressed, you will start moving backwards immediately after vehicle stops moving forward. Basically you never stop moving.
What I would expect - button to move backwards works as break only when it is pressed while vehicle is moving forward. It remains in breaking mode until vehicle completely stops and button gets released. Pressing it again while vehicle is stopped, will switch it to acceleration backwards mode and vehicle will start moving backwards.
Another issue:
Behavior inconsistency when pressing both move forward and backwards button while vehicle is moving. Moving backwards always wins, no difference what direction vehicle is moving to. Talking in examples:
- if you keep pressed button to move vehicle forward + vehicle actually accelerates forward, and then press "move backwards" button without releasing "move forward" vehicle will start slowing and finally will start moving backwards.
- if you keep pressed button to move vehicle backwards + vehicle actually accelerates backwards, and then press "move forward" button without releasing "move backwards" vehicle will keep moving like nothing had happened.