How did I get this to work? Control Scheme

Hello,

I know this might be too broad, but I could really use the help understanding it. I’m working on a survival horror tank control scheme, and it’s working. The problem is, I don’t know how!

I started this months ago, then had to step away. Recently, I got some time to work on it again and coming back to it feels like a completely different person put it together, and I can’t begin to figure out how I got it to work.

In my new build, my character gets stuck in either walking or running states, and can’t move between them freely. For example, if I hold the run button while walking forward, the character will increase movement speed (800). But if I then walk backwards while still holding run, he maintains the run speed (800) going backwards. This shouldn’t happen. He’s supposed to revert back to walk speed of 200, if the run button is released or perform a quick turn if it’s not.

However, in this months-old build (shown below), the controls work flawlessly. My guess is that it has something to do with the two speed increases in different places that’s somehow fixing the issue, but I’m not sure.

Let me be clear, I don’t want to just copy the previous build, I need to know how I did it to begin with, in case I need to change/troubleshoot anything.

I know this is a ridiculous question/request, but any help or observations would be appreciated. Thanks!