Decrease acceleration after changing direction to the opposite direction the second time

I have returned because I’m that much of clown.

Anyway, this time I’m trying to set up a system that makes it so the first time a player changes direction, the acceleration does not decrease, but each subsequent time within a short timeframe, it will decrease it. Most commonly strafing back and forth.

I have this, but I don’t think it really is how I should approach it.

Basically, it gets the current velocity direction and the movement input and finds the percentage of how much that is to the max speed. so, when the player reaches a certain speed it will reset it. allow them to switch directions with full acceleration again one time.

The part I’m getting stuck on is the first strafe of changing of direction not affecting the acceleration.

EDIT:
Here’s another way I found to do the exact same thing, maybe this is a better starting point

Alright I’m looking at this and I’m seeing a lot of bugs and weird behaviors that are going to happen in current way, stopping and starting, forward to right movements. It’s not compensating for any of these types of movements and will make if feel janky. or binary in approach

Gimmie a sec

Ok I think what would work better is getting the rotational angle of the Z for the direction I’m moving in the direction I’m trying to move in

Ok got it

Yes I realized I don’t need the find look at rotation to do it

Ok, now I have no idea how to approach the next part, this is one I need help with.