I know how many comments have already said the same thing but this was shockingly concise and well made. You perfectly quickly explain everything so well. You've earned my subscription sir.
I have a whole lot of concept art for a 2d top down game and these tutorials really helped, there is a lot of stuff I’m still trying to figure out like how I’m going to animate my sprites and a lot more, but I saved some of your tutorials to a playlist I will watch them all on repeat until I can understand it well
You, good sir, are a freaking LIFE SAVER. I was looking everywhere for a simple tutorial on this, and by God, you made it stupidly easy. Thanks to you I overcame a simple, yet seemingly insurmountable obstacle. THANK YOU! :)
Had to rewatch on .75 and .5 speed and pause, but this is not a video about copying your code, simple explanations, right to the point, even just enough of extra info about some codeline, keep it up and thank you for your help
im making a small indie game with 2 of my friends and i have NEVER touched unity in my life and this tutorial helped me figure out movement enough to get the basics of the game
0:58 Small tip: if you make simple 2d top down game and don't need gravity or physics that much, you should change rigidbody2d -> body type from Dynamic (default) to Kinematic instead. So you don't have to worry about forgot set this thing up or something made up. Good luck on your journey!
@@koolkiller35 You can refer here in 1:28 and 2:09 th-cam.com/video/xp37Hz1t1Q8/w-d-xo.html Also you have to know that in unity when you build something in your scene event you build in 2D world basicly it's still happen in 3D that why you can switch it's properly and you can check in RigidBody2D -> Constraints -> Freeze rotation Z which is height value of 2D object in 3D world to prevent it's had strange behavior when interacting and have behavior of 3D world like floating around.
Nice video. Amazing how you can get full movement for top down in a 7 minute video. A lot of other tutorials drag on for like half an hour to achieve the same outcome. This is one of my 5* tutorials, which I keep in a folder for future reference.
anyone who got stuck on the scripting bit. like me. i was missing the extensions in visual studio code. you just need the c# one but you'll also need .net framework 7 and the 4.7.1 devpack ( forgot full name) once i got those i had all the needed links after that it was a breeze. also at end my character wouldn't move and i had all the spelling and so on correct in the code the issue was super simple. i had to capitalise the H and V in horizontal and vertical. drove me mad but wanted to share because this video works but my road was bumpy cause those factors. liked and subbed mate spot on thank you
FYI you can just put * speed in the process input float and put rb.velocity = moveDirection in void move and it will work just as fine as rb.velocity = new Vector2 (movedirection.x, movedirection.y)
More than a year old but this still holds up! Only nitpick is I wish you'd linger on your code for a second or two after you've finished typing rather than just zipping back over to Unity, gives me a chance to pause so I can fully read what you've done.
hi i am russian and i don’t even know if i am writing correctly because through a translator. i didn’t think i would switch to english courses but i switched thanks to you
I was stuck using AddForce from a different tutorial, and I couldn't for the life of me figure out, or find the syntax for other movement types. Not only that, even had I found Velocity, the way it is implemented is different than the AddForce was... so I would've been lost regardless! Now, we have a very straightforward, and easy to understand multidirectional movement!
i literally love you. Thx for this, pls keep making short videos like this. For example make a one tutorial about how to make 2d map work properly, making game interface etc.
Wow thank you so much, i found it hard to follow on in other peoples videos but you did a really good job at explaining the code and how it is used, so thanks a lot!!!
I have been trying to learn basic top down movement like this for the past couple days. I have no C# experience, but this is the only video where the code actually worked and I learned what it meant. Will definitely watch more videos, thanks!
Do you have your VS Code editor formatting method blocks in K&R style as you type or are those subtle jump cuts? I'm going crazy trying to get VSCode C# to stop doing Java style curly braces. Even the Unity snippet extension I'm using formats it that way, but the auto formatter fixes it when I hit the hotkey. I just want the lightweight-ness of Code with the feeling of Studio typing ahhh
Great video, I was stuck for hours before. what interpreter are you using? I think mine is basic c#, and I even downloaded Unity for Visual Studio Code.
whenever i open VSCode on unity and try puttting something like GameObject nothing comes up, and its not the intelli thing cos other tthings come up like try and stuff does anyone know why
Really nice video, explained everything really well and very clear. I'm still a beginner for unity and my first real project is making the Atari game from the film Ready Player One and this video was an absolute godsend.
Is there a reason you received the inputs and put them into the moveDirection vector only to separate the components again with: rb.velocity = new Vector2(moveDirection.x * movespeed, moveDirection.y * movespeed); Could you just do: rb.velocity = new Vector2(moveX * movespeed, moveY * movespeed);
your tutorials are really short doable and amazing its better than brackeys brackeys just acts like everyone knows what everything is and does so its not really great for beginners like me so thank you b mo also i love how you reply interact and help people example- (you helped me on discord with the typo errors and the main menu so i appreciate you BMo
Simple Easy to follow along To the point with out any unnecessary assets or utility files to import. As someone who's just gotten into the gamedev, Thank you! I've been trying to learn basic concepts and techniques and I keep hitting walls because a lot of "beginner" tutorials will skip explaining/showing 1 or 2 really basic code that is essential to making a script work, or have assets preloaded and then never reference them in the tutorial. I've had to stop (after much frustration and time invested) a number of them and then look for how to do X, just to move forward. So a big thank you for keeping it short and sweet w/out any other unnecessary dependencies.
hey BMo! It worked perfectly one time, but now it doesn't anymore. There's no error and the sprite is moving but it's moving down without me pressing any buttons. If I press a button it goes in this direction. I don't understand. I have the EXACT same code...
@@justleo2903 Did you ever figure out the answer to this problem? I'm dealing with the same thing myself. And none of the internet's solutions seem to work.
@@leonaxt611 I don't know how... But after letting this project sleep for an eternity, it suddenly worked. Idk what i did but i just hit run without expecting it to work, but it did
5:57 because I used python in the past I k ow how to fix that using math and now I start unity and I still stuck on the way that everything should be code like in python but in unity you got all set up my code before that video was not good and it even didn't work good so thx you
maybe i can somewhere copy all the codes bcause, i have some problems like colors not the same a lot of errors in the console and more... btw im new in the coding, this is my first time and i dont understand sh!t
@@alexanderschmid6251 If you can't make use of this video to make such easy mouvements maybe it's time to rethink your programming skills and creativity just saying... This video is perfect since he uses physics and the inputs are perfectly managed (I'm not insulting btw it's just what I think)
i would like to know how do i make it so like if your close to the wall, you can only see the top, if you get more far away from it, you can see its sides, i know its sounds weird but when you understand it you go "OHHHHHHHH"
Ok I know this is a really dumb question, but in 2:20, when you make the first line of code, the text shows up purple and has a line that says “zero references”. On mine, the text is blue and doesn’t say “zero references” Sorry for the small brain problem, just started unity
Its probably just my visual studio color theme. The 0 references is just a handy feature visual studio provides.. Which program are you using to write code
@@BMoDev I’m also using visual studio. Im trying to make a floaty-any direction movement for my character (basically just this except a little bit of sliding when you stop moving) and I figured this would be a great place to start
Yeah, no matter where you start theres a ton to learn, just take it 1 step at a time - but this is a great place to start. Were you able to follow the tutorial and get it working?
I'm having trouble I did exactly this and it doesn't work I've gone over it multiple times and it doesn't say there is any issues but then says all issues must be fixed before compiling?
I got this error: Assets/PlayerMovement.cs(32,12): error CS1061: 'Rigidbody2D' does not contain a definition for 'Velocity' and no accessible extension method 'Velocity' accepting a first argument of type 'Rigidbody2D' could be found (are you missing a using directive or an assembly reference?) Does anyone know how to fix it?:)
at 5:20 after I save the code it says, "error CS0542: 'Move': member names cannot be the same as their enclosing type" After you type the move code into fixed update it cuts before i can see the finished code, so I don't know what is wrong because I followed the tutorial perfectly.
when i type public float moveSpeed; and public Rigidbody2D rb; it does not show anything under the tab and I have not found anything on the forum that can help me.
BRO I love you instead of just showing the code you also explain it even though it's 3 years old this is one of the few tutorials I respect
Simple, straight to the point and only 7 minutes long. Love it.
That's what she said.
I know how many comments have already said the same thing but this was shockingly concise and well made. You perfectly quickly explain everything so well. You've earned my subscription sir.
People who gives their knowledge for free, r a other kind of hero. U r kinda saving lives if I think deep about it. Gj!
I appreciate your speed and conciseness! Other tutorials are finishing up their promotions and introduction at 7:20
*cough* *cough* brakeys *cough* *cough"
@@sofisticated1940 Don't disrespect the legend himself.
kids hating on brackeys
I have a whole lot of concept art for a 2d top down game and these tutorials really helped, there is a lot of stuff I’m still trying to figure out like how I’m going to animate my sprites and a lot more, but I saved some of your tutorials to a playlist I will watch them all on repeat until I can understand it well
Short, simple, and it works! As an artist trying to learn code, thank you!
You, good sir, are a freaking LIFE SAVER. I was looking everywhere for a simple tutorial on this, and by God, you made it stupidly easy. Thanks to you I overcame a simple, yet seemingly insurmountable obstacle. THANK YOU! :)
best tutorial! telling my friends to come here if they want to learn game dev
Had to rewatch on .75 and .5 speed and pause, but this is not a video about copying your code, simple explanations, right to the point, even just enough of extra info about some codeline, keep it up and thank you for your help
im making a small indie game with 2 of my friends and i have NEVER touched unity in my life and this tutorial helped me figure out movement enough to get the basics of the game
FINNALY a video that will work! i've lost my hair trying to find a top down movement tutorial
0:58 Small tip: if you make simple 2d top down game and don't need gravity or physics that much, you should change rigidbody2d -> body type from Dynamic (default) to Kinematic instead. So you don't have to worry about forgot set this thing up or something made up. Good luck on your journey!
I'm sorry I'm new to coding and don't understand. Can you explain that in a bit more detail?
@@koolkiller35 You can refer here in 1:28 and 2:09 th-cam.com/video/xp37Hz1t1Q8/w-d-xo.html
Also you have to know that in unity when you build something in your scene event you build in 2D world basicly it's still happen in 3D that why you can switch it's properly and you can check in RigidBody2D -> Constraints -> Freeze rotation Z which is height value of 2D object in 3D world to prevent it's had strange behavior when interacting and have behavior of 3D world like floating around.
@@koolkiller35in the rigid body where u adjust the gravity, there is an potion called "bodytype" change that from dynamic to kinematic
Good shout honestly
I love how straight to the point this is. :)
This is perfect for underwater movement. Thank you for this tutorial!
Nice video. Amazing how you can get full movement for top down in a 7 minute video. A lot of other tutorials drag on for like half an hour to achieve the same outcome. This is one of my 5* tutorials, which I keep in a folder for future reference.
Thanks! I did this and linked it with the Animator StateMachine- with the Horizontal and Vertical inputs - to make very smooth-looking movements.
Ayy nice work! You're ahead of the game, that was going to be a followup video :)
@@BMoDev That's great to hear! Looking forward to watching the next.
TNice tutorials is THE most helpful tutorial on TH-cam imo. I am starting production in Hardstyle, and I find soft soft really useful
OMFG the best tutorial easy to follow and I learned soooo much KEEP GOING
No doubt, glad it helped!
Thanks so much for this tutorial! I'm getting back into game dev after a long break and this tutorial was super helpful to me!!!
Love to hear it, keep going! Feel free to share your progress in the discord would love to see what you make!
same here!
LOVE how you explains stuff. so clear!
Everything that I needed was here all the time...thanks for sharing your skills.
It scares me how good theses tutorials are!
Wow appreciate it
Great tutorial. If anyone's Vector2 is an issue, delete "using System.Numerics;" if it's in your Visual studio code. That fixed it for me
Thanks for sharing!
anyone who got stuck on the scripting bit. like me. i was missing the extensions in visual studio code. you just need the c# one but you'll also need .net framework 7 and the 4.7.1 devpack ( forgot full name) once i got those i had all the needed links after that it was a breeze. also at end my character wouldn't move and i had all the spelling and so on correct in the code the issue was super simple. i had to capitalise the H and V in horizontal and vertical. drove me mad but wanted to share because this video works but my road was bumpy cause those factors. liked and subbed mate spot on thank you
Thank you so much for this tutorial. I am currently working on a procedurally generated dungeon game, and this helped me get started. Great video!
Appreciate it! Would love to keep tabs on your game
FYI you can just put * speed in the process input float and put rb.velocity = moveDirection in void move and it will work just as fine as rb.velocity = new Vector2 (movedirection.x, movedirection.y)
getting watched latered for the rest of my days thank you
More than a year old but this still holds up! Only nitpick is I wish you'd linger on your code for a second or two after you've finished typing rather than just zipping back over to Unity, gives me a chance to pause so I can fully read what you've done.
im learning game design for a class project and this was helpful. thank you!
hi i am russian and i don’t even know if i am writing correctly because through a translator. i didn’t think i would switch to english courses but i switched thanks to you
Кстати я тоже русский
Super easy to follow tutorial!! We STAN Bmo 😎
your comments actually make me laugh everytime
Not really. I'm doing Unity the first time and he is just jumping around. It should be slower for a tutorial.
I was stuck using AddForce from a different tutorial, and I couldn't for the life of me figure out, or find the syntax for other movement types. Not only that, even had I found Velocity, the way it is implemented is different than the AddForce was... so I would've been lost regardless! Now, we have a very straightforward, and easy to understand multidirectional movement!
i literally love you. Thx for this, pls keep making short videos like this. For example make a one tutorial about how to make 2d map work properly, making game interface etc.
It's the best unity tutorial video I ever seen
surprisingly hard to find videos about top down movement and this tutorial was very helpful
I've always thought that too, np
Short and concise! Thank you!
Thanks for the tutorial. The intellisense of my VS Code is not working properly; at 2:26, I type "Rigid" and nothing happens. How can I solve this?
yes the same thing was happening to me
You need to set your IDE settings in unity. You do it through preferences
@@mr.bluesman9879 how do i do that?
do u have c# extension
Thank you, your tutorial is the only one working on all of the videos I searched
Omg this is so much simpler and a better explanation than 3 other videos
Can someone give me finished script? I want to compare it
Sure
hey, having trouble for some reason on ln22 col5 (fixed update) and cant figure out why. any ideas?
It would be really helpful when you jump around in the code to show the finished line of code for longer than 1ms before cutting to the next frame
Wow thank you so much, i found it hard to follow on in other peoples videos but you did a really good job at explaining the code and how it is used, so thanks a lot!!!
I have been trying to learn basic top down movement like this for the past couple days. I have no C# experience, but this is the only video where the code actually worked and I learned what it meant. Will definitely watch more videos, thanks!
Nice job!
Ty bro, short tutorial, not some complicated code, this is great Im leaving like and subscribe!
Do you have your VS Code editor formatting method blocks in K&R style as you type or are those subtle jump cuts? I'm going crazy trying to get VSCode C# to stop doing Java style curly braces. Even the Unity snippet extension I'm using formats it that way, but the auto formatter fixes it when I hit the hotkey.
I just want the lightweight-ness of Code with the feeling of Studio typing ahhh
great value in this, plus your voice is really nice. gonna go check out your other videos now!
Went way too fast at times and even cut away like 1 frame before you finished typing a line of code but I was able to make it work.
I can't type I need help
@@Ivy_olive_catswhy are you coding then
Omg, glad you’re ok!
Yeah my problem but I can't make it work
Great video, I was stuck for hours before.
what interpreter are you using? I think mine is basic c#, and I even downloaded Unity for Visual Studio Code.
I followed the tutorial step by step, but it doesnt work. did i do anything wrong?
You probably are using a newer version of Unity
Thank you so much for explaining why you did the things you did! It really helped me learn!
Loved the way you explain things! subbed ;)
Thanks!
Thank guy, have a good day
THANK YOU VERY MUCH GOD BLESS YOU. THE ONLY TUTORIAL I COULD FOLLOW AND IT WORK.
This is a very simple and good tutorial! I had trouble finding a tutorial that was easy to follow so thank you very much :)
Awesome, happy to hear that!
whenever i open VSCode on unity and try puttting something like GameObject nothing comes up, and its not the intelli thing cos other tthings come up like try and stuff does anyone know why
Thank you so much for this tutorial
You bet hope it helped!
Really nice video, explained everything really well and very clear. I'm still a beginner for unity and my first real project is making the Atari game from the film Ready Player One and this video was an absolute godsend.
Is there a reason you received the inputs and put them into the moveDirection vector only to separate the components again with:
rb.velocity = new Vector2(moveDirection.x * movespeed, moveDirection.y * movespeed);
Could you just do:
rb.velocity = new Vector2(moveX * movespeed, moveY * movespeed);
your tutorials are really short doable and amazing its better than brackeys
brackeys just acts like everyone knows what everything is and does so its not really great for beginners like me so thank you b mo also i love how you reply interact and help people example-
(you helped me on discord with the typo errors and the main menu so i appreciate you BMo
Well I appreciate you watching, thanks! :)
what're your extensions? and how did you show the reference tag on your code?
He is using vscode, im pretty sure its built in. if not try installing the c# exstension
Thank you so much for the quick and easy explanations.
Thanks!
These videos help so much, my mind just gets stuck somedays and its hard to make even a simple start
What Visual Studio Code theme are you using? I really like the one.
I think its monokai
Thanks for the video, even though it was made long ago it is still useful! :)
Thanks! Unity hasnt changed that much so most older videos still apply just fine!
Simple
Easy to follow along
To the point with out any unnecessary assets or utility files to import.
As someone who's just gotten into the gamedev, Thank you!
I've been trying to learn basic concepts and techniques and I keep hitting walls because a lot of "beginner" tutorials will skip explaining/showing 1 or 2 really basic code that is essential to making a script work, or have assets preloaded and then never reference them in the tutorial.
I've had to stop (after much frustration and time invested) a number of them and then look for how to do X, just to move forward. So a big thank you for keeping it short and sweet w/out any other unnecessary dependencies.
Nice video man, clear and concise explanation! Thanks a lot!
this is the most helpful vid in movement thanks
Glad it helped!
There is an error saying " ArgumentExeption: Input Axis horizontal is not setup. To change the input settings use: Edit -> settings -> input "
Make sure its capitalized correctly
hey BMo! It worked perfectly one time, but now it doesn't anymore. There's no error and the sprite is moving but it's moving down without me pressing any buttons. If I press a button it goes in this direction. I don't understand. I have the EXACT same code...
is the gravity in ur rb set to 0
@@glitchcentral2753 yes. In other projects it didn't work either
@@justleo2903 Did you ever figure out the answer to this problem? I'm dealing with the same thing myself. And none of the internet's solutions seem to work.
@@leonaxt611 I don't know how... But after letting this project sleep for an eternity, it suddenly worked. Idk what i did but i just hit run without expecting it to work, but it did
Thanks for this! I can't see the full script at the end..can you share?
So FixedUpdate is basically deltaTime without having to call deltaTime multiple times?
What are you using so vs will predict what you are typing
thanks for showing finally able to get my little rpg going!
In this case using Time.deltatime is necessary or not?
Great video! Short and very clear
Why is my player phase through object even though I allready add a box collider
Does the object have a collider?
5:57 because I used python in the past I k ow how to fix that using math and now I start unity and I still stuck on the way that everything should be code like in python but in unity you got all set up my code before that video was not good and it even didn't work good so thx you
this is really good! is there a good way to add momentum to the movement?
maybe i can somewhere copy all the codes bcause, i have some problems like colors not the same a lot of errors in the console and more...
btw im new in the coding, this is my first time and i dont understand sh!t
When I drag the script to the component list it dosen't give me the option to change any of the scripts attributes
I love the quick pace of this tutorial! Super easy to follow. Do animation plz :))))
Awesome! Animation is definitely one of the upcoming videos
@@BMoDev Looking forward to it :D
I simply can't understand why you have 2 dislikes, thank you so much !!!
Appreciate the kind words! Hope it helped
@@BMoDev i cant add my script to player :/
edit: or i can add it on the player
@@BMoDev i wanted to make movement like in zooba or in brawl stars sry but this didnt help me
Now he has 19
@@alexanderschmid6251 If you can't make use of this video to make such easy mouvements maybe it's time to rethink your programming skills and creativity just saying... This video is perfect since he uses physics and the inputs are perfectly managed (I'm not insulting btw it's just what I think)
I just get a bunch of errors and I can't enter play mode 5:25 (It says compile error)
nvm guys I got it, just remember to alwasy doube checked that you typed everything out correctyl
love it. it really helped
Thanks for the turorial. The best one I found.
Appreciate ya 🙏
The type or namespace name 'RidgidBody2d' could not be found (are you missing a using directive or an assembly reference?)
unity is pretty picky on these type of things, instead of 'RigidBody2d' it is 'Rigidbody2D'
Thank you man! I am making a game and this really helped thank you so much!
Hey! Can you make a video on how to code a diagonal jump? I tried this but the vector in x direction doesn't seem to work 😥
i would like to know how do i make it so like if your close to the wall, you can only see the top, if you get more far away from it, you can see its sides, i know its sounds weird but when you understand it you go "OHHHHHHHH"
Can you do this without the ghost effect?
Ok I know this is a really dumb question, but in 2:20, when you make the first line of code, the text shows up purple and has a line that says “zero references”.
On mine, the text is blue and doesn’t say “zero references”
Sorry for the small brain problem, just started unity
Its probably just my visual studio color theme. The 0 references is just a handy feature visual studio provides.. Which program are you using to write code
@@BMoDev I’m also using visual studio. Im trying to make a floaty-any direction movement for my character (basically just this except a little bit of sliding when you stop moving) and I figured this would be a great place to start
Yeah, no matter where you start theres a ton to learn, just take it 1 step at a time - but this is a great place to start. Were you able to follow the tutorial and get it working?
I'm having trouble I did exactly this and it doesn't work I've gone over it multiple times and it doesn't say there is any issues but then says all issues must be fixed before compiling?
I got this error:
Assets/PlayerMovement.cs(32,12): error CS1061: 'Rigidbody2D' does not contain a definition for 'Velocity' and no accessible extension method 'Velocity' accepting a first argument of type 'Rigidbody2D' could be found (are you missing a using directive or an assembly reference?)
Does anyone know how to fix it?:)
the "v" in velocity might be lower case
why in 5:11 you multiply "moveSpeed" 2 times?
For both x and y. Have to make sure up and down is the same as left and right
at 5:20 after I save the code it says, "error CS0542: 'Move': member names cannot be the same as their enclosing type" After you type the move code into fixed update it cuts before i can see the finished code, so I don't know what is wrong because I followed the tutorial perfectly.
Are you missing void in the Move method?
no
2:03 where did you get this????
Thank you, it helped me, and was pretty simple.
when i type
public float moveSpeed; and
public Rigidbody2D rb;
it does not show anything under the tab and I have not found anything on the forum that can help me.