How to add a jump key
I have a game where you roll a ball around and collect yellow spheres. Right now, you can move horizontally and vertically, but I want there to be a way the player can make the ball jump. How would I do that? (I only use C-Sharp script) All answers are appreciated. Thanks in advance!
Answer by romatallinn · Nov 10, 2016 at 10:13 PM
It would be useful to google the issue before posting it.
Nevertheless, a few examples are given. The first one is if you want to use the standard physics and rigidbody. The second is custom solution for gravity behaviour.
@$$anonymous$$rkrisher the 2nd link IS C# script... Furthermore, try to look at JS code. It should not be a big deal to transfer JS to C#.
Answer by BrodyDaChappy · Nov 13, 2016 at 11:09 PM
You should check Youtube for tut's, here is one i found this may help.