Unity 2d tutorial 4:how to jump the player in platform 2d game unity engine with easy c# codings


In this tutorial We want to see how to jump character(player) in a 2d platform game on unity engine with easy c# scripts.This tutorial we can learn step by step process to move the  character(player)  in 2d game.I wish you can learn this easily.I will explain with screenshots and videos.Lets go to tutorial.Its not much harder


Before enter this tutorial you want see these tutorials 

  •  How to move player here.
  •  Flip the player tutorial here.
  •  How to animate here.


1.Now You know how to move and flip them animate that player.now i am going to tell you to how to jump the player when    pressing spacebar.

2.Add some coding to the playercontrol script
   In varibale=>
             Rigidbody2D player;


   In start methord=>
             player = GetComponent<Rigidbody2D>();

   In update methord=>

             if (Input.GetButtonDown("Jump"))              player.velocity = new Vector2(0, 5f);}


3.then start the game.If any error comment me(download script)


       Check out this tutorial in this video,




If is it usefull and you want more videos subscribe my channel subcribe my youtube channnel



you can watch how to move player in this link here

you can watch how to flip moving player in this link here

you can watch how to animate moving player in this link here






Watch tutorial to download Unity Engine here