- Home /
How to program a dodge roll and similar?
I am making a kind of character action game and am stuck on how to program the character to do a dodge roll. How would I program a primitive, like a capsule representing the player, to do a dodge roll? For example the player presses the button that dodge is mapped to and the capsule then does a spin as a representation of the dodge being performed.
Answer by Stankiem · Oct 21, 2016 at 04:49 PM
Honestly, save your time and use an asset from the asset store.
https://www.assetstore.unity3d.com/en/#!/content/3853 https://www.assetstore.unity3d.com/en/#!/content/27438 https://www.assetstore.unity3d.com/en/#!/content/66826
Surely you can think up a logical way of doing this using lerps and/or childing the collider to the model armature, but I don't see why you would spend time with this (especially if you're needing to ask the question here). Just spend a little bit of money, save loads of time and buy a good system that is ready to go such as the links above.