How do I make the car drift only when I hold or press the handbrake?

I have been in a class for game development, and have been trying to make a drifting game. I have used @5Drifts tutorial, and the physics are amazing! But I am trying to make the car ONLY drift when the handbrake is in use. I also want the car to be able to do donuts, and the car physics right now can’t do that yet.

I’m just wondering if anyone else has done this and how I would implement this into my own game.

Hey @Eclipith! Welcome to the forums!

So I skimmed through to see what they’re doing in that video and it looks like you can get the car blueprint, cast to the car blueprint if necessary, use Get Component of class and get wheel. Then you can drag off of wheel to SET Cornering Stiffness and Friction Force Multiplier to values you choose based on if the handbrake is pulled or not. You would do a branch, have a “handbrake?” boolean variable to use there, and if “handbrake?” is true, set to the drifting values you want and on false set it to regular values (this will take 2 set nodes on each branch) then you can merge the paths back together on the next nodes if there are any.

You definitely will need to have the button you use (which should probably be a Hold/Release) to set “Handbrake?” boolean.

Hope that helps! If there’s more confusion try to post pictures of your code in a readable state! :slight_smile: