Download

Walk, Jog, Sprint with Toggle - How to get previous toggle option

Hey everyone.

I have a toggle between walk and jog. If I toggle to walk then decide to sprint, after i release the sprint key it returns me to jogging. How would i return the character to the previously chosen toggle option as if i wanted to re-enable walk I’d have to press it twice.

Image of my current setup.

Many thanks for any tips :slight_smile:

Create a variable to store the active movement mode (Walk/Jog) or you could store the active Movement Speed. When Shift key is pressed, use this variable to hold the mode/speed of your character. When the user releases the Shift key, you can switch back to the previous movement mode/speed by looking up this variable.

Great thanks! I shall give this a go and post a screenshot after I’ve done it for future reference for anyone else! Cheers!

Thanks again for the response Mindfane, Managed to get this done today been busy at work.

Incase anyone else wants something similar:

1816c82df5c3364271a511364d704fabcefe30f2.png

Thanks for the share. ++