2D CHARACTER MOVEMENT IN UNITY 🎮 | Rigidbody2D Movement And Jumping In Unity | | Unity Tutorial

preview_player
Показать описание
In this Unity tutorial I will teach you how to move and jump in Unity with a 2D character! 😊 This video will be a introduction to C# programming and how to move and jump using Rigidbody2D.

➤ TIMESTAMPS

00:00:00 - Introduction.
00:00:17 - Getting Unity ready!
00:00:42 - Creating our Sprites.
00:02:21 - Adding Rigidbody2D and Colliders.
00:04:27 - Creating our C# PlayerController Script.
00:05:36 - I have a C# course!
00:06:06 - Understanding what is in our Script.
00:06:43 - Fields, Properties, and Methods in C#.
00:08:40 - Using, Classes and MonoBehaviour in C#.
00:10:11 - Start(), Update(), and FixedUpdate() in C#.
00:11:09 - The Void keyword in our methods?
00:13:21 - Creating our Fields.
00:16:59 - Assigning values to our Fields.
00:19:33 - How to get player input.
00:21:12 - Moving our player using AddForce.
00:25:09 - Jumping using AddForce.
00:26:05 - Checking if player is grounded.
00:27:05 - Adding a ground check Trigger.
00:27:58 - Preventing player rotation.
00:28:20 - OnTriggerEnter2D() in C#.
00:29:20 - How to add tags to game objects.
00:30:32 - OnTriggerExit2D() in C#.
00:31:02 - Prevent player double jumping.
00:32:11 - Final adjustment to our Rigidbody2D.
00:33:32 - Thanks for watching!

➤ GET ACCESS TO MY LESSON MATERIAL HERE!

First of all, thank you for all the support you have given me!

I am really glad to have such an awesome community on my channel. It motivates me to continue creating and uploading content! So thank you!

I am now using Patreon to share improved and updated lesson material, and for a small fee you can access all the material. I have worked hard, and done my best to help you understand what I teach.

I hope you will find it helpful :)

Рекомендации по теме
Комментарии
Автор

Finally someone who acknowledges the importance of why. So many videos that I have watched just instruct you WHAT to type in to the code and which checkmarks you should have but never do they tell you WHY, which makes the information totally useless because you can never use it in any other situation.

protophase
Автор

best tutorial ive seen on programming for beginners!! like any new subject youre completely unfamiliar with, there's a whole universe of things you need to learn in order to make your own mental image and understanding of the topic in order to really learn stuff instead of memorizing. the way its explained on this video really helps with that

parloleiton
Автор

you're a life safer. Most tutorials dont explain what we're coding and when i did something wrong i wouldnt know how to fix it. But you explained very well. thx

bubblegum
Автор

This, by far, actually taught me something. Thank you so much for making this video, Dani. At the very least, I think I've learned some core concepts of the codes you have introduced here.

leeta
Автор

This is the first video of yours I've watched, and the best tutorial I've seen that (as many others have pointed out) actually explains WHY you're writing a certain line of code and how everything interacts with each other as opposed to just telling you what to write. I ended up taking notes on paper and also adding notes into the script so I can go back and remember what the fields and everything are actually doing.

Thanks SO much for this, subscribing and probably devouring all the rest of your videos!

dylanc
Автор

This is the first player movement script that REALLY worked for me, that I understood. I'm relearning Unity after I took a huge break from coding so thank you so much for helping me bounce back <3 You earned a subscriber, I look forward to seeing more of your videos!! Thank you again so much. When the script actually worked I almost screamed HAHA I was so happy.
THAKN YOU THANK YOU THANK YOOOU

almaaanea
Автор

Im just seeing this now after using many other vids that didn't explain as well as yours. I have decided to make a game on spring break, thanks a ton and i'm sure i'll watch more of the vids you have made to help me

average
Автор

finally a tutorial that actually EXPLAINS why and what the code that we need to type does. I've been looking all over for this. Thanks so much!

dazza
Автор

I just wanna say ive watched about a dozen different unity / c+ beginner videos and tutorials and this is the first one that has actually TAUGHT me something. Thank you!

aaronperdue
Автор

I have watched so many tutorials on youtube by now and this is by far the best one! you explain things so thoughtfully and clear. keep it up, you gained a new subscriber!

NTN
Автор

I've never been so thankful in my life. I've spent over 20++HRS trying to fix my jumping mechanics going through soo many tutorials hoping it would fix my issue and THANKFULLY this has been the one and only that has fixed my issue. Thank you soooo much!!! I am subscribing and liking this video and keeping this Channel as my go to for my issues. Its so informative especially for a beginner. I can't help myself but to thank you again once more.

zoem
Автор

Na this dude is legit he makes sure to think about what would a new Dev be thinking he does not only think from an experienced point of view subbed man

francoisdebruin
Автор

Its Great to see someone explain things and does'nt just gloss over it or assume people already know what everything means.

AmierAzzeal
Автор

It finally worked! After two months of watching tutorials he

FondsRL
Автор

Thank you, for taking the time to just explain(with examples) the little things Even when you say your not going to. !

stanleyhavok
Автор

Out of every channel I've looked at, you were the most informative.
Thank you!

meliasnahtony
Автор

I am getting intetested in game dev and you are beautifully teaching me the way through it. I thank you so much, I devoured this video in the best sense of the term. It shows the crazy amount of devotion you have to teaching.

Thank you once more.

thissideofmyworld
Автор

Thank you so much for actually explaining the code here, it’s purpose and why it’s being used in this instance. The phrase ‘give a man a fish, and he’s fed for a day, teach a man to fish, and he’s fed for a lifetime’ comes to mind. Every other tutorial has just been tossing fish, whereas this one has actually managed to teach me something effectively.

goomba
Автор

thank you for explaining how the code works, you don't know how many people make "beginner tutorials" but never actually explain the functions of the code.

staticplays
Автор

This walk through is amazing so detialed but still welcoming for new game designer and programers like myself. Thanks so much!!!

jamesjam