Start Your Game Creation Journey Today! (Godot beginner tutorial)
Vložit
- čas přidán 9. 06. 2024
- ➡️➡️➡️ Part 2: • LEVEL UP Your Game Des... ⬅️⬅️⬅️
🔥 GET completed project: / 91206232
🤯 Join Coco Code members: / @cococode
💙 More gamedev tips: / cococodeyt
This guide will help you with your first steps in Godot game engine. You will learn how to create a simple 2D platformer game with all the most important features covered: Player sprite setup, 2d movement, background image, tileset (tilemap), character animation and input map.
-----------------------------------------
🔗 LINKS IN THIS VIDEO:
Godot download link: godotengine.org/
Pixel adventure assets: pixelfrog-assets.itch.io/pixe...
C# script: pastebin.com/PmuBTziN
-----------------------------------------
👨💻 SOCIALS:
🔵 Follow me on Twitter: / cococodeyt
💜 Join our Discord: / discord
-----------------------------------------
🎓 YOU WILL LEARN:
- How to create a sprite in Godot
- How to create an animated sprite in Godot
- How to setup a tileset in Godot
- How to create your first game
- How to create game in Godot
- Is Godot easy
- Godot first steps
- Static background image in Godot
- Basic character movement in Godot
-----------------------------------------
⚙️ VIDEO CHAPTERS
0:00 - Intro
0:33 - Godot install and scene setup
2:10 - Background image
3:59 - TileSet (ground design)
6:03 - Character setup (Sprite)
7:46 - Creating sub-scenes
9:30 - Character movement and collision
11:52 - Sprite animation
14:27 - Character movement tweaks
20:09 - Input map
#gamedev #godot #tutorial #2dplatformer
*📣Everyone*
*PART 2* IS NOW LIVE: czcams.com/video/zL__a0Ei6Vs/video.html ⬅⬅⬅
I was just about to finish this video and realised I needed to learn collectables! Thanks for the tutorials they are really helpful :)
Will there also be a part 3 r will this be the last one?
If part 2 will go well (many people will be interested), why not!
I would like to see how to create the characters and other assets you downloaded from scratch if possible. I am a character designer and have some ideas.@@CocoCode
I have a problem at 16:56 I can't tipe "sprite_2d.flip_h" i don't know why, can you help?
To anyone who is getting the unexpected identifier error, you have to add an indent where the code is written so it is in the physics delta class body.
took me a minute to figure it out but thanks a lot man
I ran into that mistake too. No joke … I’m using a Mac so I thought it was a software issue… (new to this so…) I ended up deleting all the code and retyped it to a T using the video as reference to make sure there wasn’t any fault on my part. Finally got it working after half an hour … then i found this comment. At least it’s coding practice lol.
i didnt understand so can you tell it in another way please (i just starded making games)
Please use indentation (using TAB key on your keyboard - above caps lock) to make code appear the same as on the video. GDScript is a language that works only if the code is properly written and organized
@@CocoCode i did it but there is a new error now
Your motion design skills makes everything very easy to understand,this is by far one of the best tutorial chanel out there
Thank you! I'm doing my best to provide the best quality for this and my other videos 💪
Hey, you can learn more about that in my other video:
czcams.com/video/RHcHMRUGDHU/video.htmlsi=m12eEBp3K5WZWB3T&t=694
(timestamp 11:34)
I know!!
I totally agree, animation on video makes learning so much easier
The fact we get rewards for completing each step is amazing, feels like your actually learning and not just a bunch of information thrown at you. this is by far one of, if not the best tutorial i have seen to date.
me who sat here and did nothing:
Hi! I just wanted to let you know that I'm thrilled to see such amazing Godot community response under this video, thank you! 🔥
I would like to confirm that *I STARTED WORKING ON PART 2* of this video. I'm planning to release it in the next 2 weeks. *Subscribe to not miss out ❗*
i cant put images in godot web editor
Still working on it? Really enjoyed this video and I'm looking forward to the next one.
@@ChainPenguin Yes, I'm planning to release it in the next 2 weeks
God bless you for this video. Its a huge help
When it is coming my friend
I've gotta say, after several years of watching game engine development tutorials, this is probably the best one I've ever seen. Seriously. And I'm talking out of hundreds. Excellent job, and thank you for providing this.
17:00 *_To fix the character automatically switching back to its original not_flipped position:_*
if Input.is_action_just_pressed('ui_left'):
sprite_2d.flip_h = true
if Input.is_action_just_pressed('ui_right'):
sprite_2d.flip_h = false
tysm
@@GodSahil im sorry, but im not good, i just started and i have to learn. But thanks for the propose!
@@Gootag_vr actually i'm a beginner too just started yesterday
Where in the code does this go, or what does it replace?
@@myshrinkingviolet2 in the physics loop at the bottom with proper identation
THIS VIDEO IS TOO UNDERRATED. I tried to use that 1 hour "Godot Crash Course for Beginners" tutorial video and it was NOWHERE as considerate and well-edited as this video and I took 4 hours to digest not even a third of it and learned only how to move a tiny character, on a bleak, gray screen. It took me 4 hours to digest this video, and it was much, MUCH more fulfilling and concise. thank you, from the bottom of my heart
Agree!
I was deciding between these two videos right tf now, literally have the other open in the another tab. Thanks for the comparison I'm going with this one.
@@exoZelia youre welcome! im now 3 more months into developing with godot now, and this video was exactly the thing that got me out of the "confused beginner" phase. i wish you luck on your journey!
Agreed. This is the ideal tutorial video. That crash course video is torture.
I've been looking for a good 2D Godot game tutorial and this is the best one I've seen. You made it so clear to understand and it was in only 20 minutes! Thank you man.
An alternate code to the flip_h argument to keep it facing the direction pressed is;
if velocity.x < 0:
sprite_2d.flip_h = true
if velocity.x > 0:
sprite_2d.flip_h = false
This will make it so that if the left key is pressed, that the flip_h is turned on, flipping your direction and keeping it, and only flipping it back to right when the right key is pressed.
ty
Thank you 😊
Godot 4.2.1 will break your tut @ 4:37, after choosing "new tileset" in the Inspector, Godot won't go to the "Tileset" options at the bottom part of the screen. For first-timers like me, it's odd that the tab's names are not above the content, but in the bottom ruler in UI ( alongside "Output").
Thanks for pointing that out!
Tysm this was helpful
I'm confused what am I supposed to do
@@lstudios3237 at the bottom of the screen there are a lot of options and if you keep looking you'll find tileset
I was looking for this specific comment, for 4.2.1 thank you
When I was able to get my character to walk with my controller, I got very emotional. Thanks for this amazing video! A hug from Brazil! (waiting for part 2)
mano, brasileiro tem em tudo quanto é canto kkkkkkkk tbm fiquei emocinado quando meu personagem andou
@@tris_dublagens Sim kkkk, os videos desse mano são muito bons.
These videos are very well edited and I cant wait for more! I tried learning godot a year ago but it failed due to problems I couldnt understand but now I’m back and ready to pursue godot once more. Thanks for the basics and dont push yourself ❤❤
this is actually the tutorial every beginners need. I've been learning godot for almost 2 weeks and watched every beginners tutorial, but most of them are just " do this and do that " and it feels like I don't learn anything, I just followed it and imitate everything from start to finish, coding is not an issue, godot UI itself is giving me a hard time to learn, but this is different, your explanation and process is very neat and simple,it's like reading a book with a large font size in broad daylight 😂. Hoping and waiting for you part 2 sir, thanks for this tutorial.
This tutorial was the best one I've found on YT! Your teaching process is amazing, and I love the badges. Please consider making a top down tutorial!!
This is one of the best and most didactic Godot videos on CZcams. Congratulations for your amazing work.
I'm someone who's wanting to get into game development, and really thought about Godot as it can export to Android.
A lot of other tutorials for Godot are either fast paced, giving too much information for someone new, or not enough information.
This tutorial really was at the perfect pace, and the right amount of information for someone new.
I loved the idea of mental badges you've given us while you complete a lesson, as we followed along.
Great video. Feels like a breath of fresh air getting these very in-depth descriptions on every item.
Awaiting for pt 2 😁
Part 2? For Enemies? Love the badge system! It keeps you going and release dopamine when we achieve it! Finished my first game in less than one day! Love it Coco Code!
I had so many issues but just kept going back until I figured out what I was doing wrong. I hope there will be a Part 2 in the future! More enemies, more levels, maybe dialogue? Love it @CocoCode
Finally finished. Was having an issue with tabbing and indentation. Didn't know that was important. Thank you for the video! Can't wait for the next one.
So glad I found this tonight. Been wanting to try my hand at making something for years. Last time I made a game it was in machine code on a ZX Spectrum. This tutorial was very easy to follow for someone like me who had never even opened up Godot before. Thank you
This tutorial is the first to ever make me feel so good and accomplished. It made me feel like a real game dev. Thank you
This is the best tutorial I’ve seen! I love the badges to help mentally break it down and that there are badge timers in the upper right hand side. This series is so creative and professional!
Ive tried a few different beginner tutorials now. This is the first one that didnt leave something minor out and cause me to hit a road block wondering what I did wrong. Awesome tutorial, keep them coming! Look forward to trying part 2 now :D
What a fantastic teacher you are. Amazing video format, easily digestible chapters, pats on the back style rewards to keep the student engaged and clear, concise directions... Absolutely loved it
16:00
This is literally *THE* best Godot tutorial I have ever found. Thanks!
Bro you are a talented your way of clarifying and simplifying things is comforting and satisfying ,I actually enjoyed while learning from your tutorials
This video and part 2 are fantastic. So well explained. I really like how you break up new features into a few steps. Keep up the great work!
In the new version, you're not directly on the right tab, so you need to go to "tile set" to add the terrain.
This tutorial was gold when I was seeking silver on CZcams, thank you a lot, and hope you will keep guiding us!!! Also, I love the achievement part of your video, it really motivates
This is really the best Tutorial for Godot on YT right now! Thank you so much, I learned many cool things.
Thank you so much, I really had no idea where to start with Godot and your video is exactly what I needed. Also the attention to detail and overall quality of the video is amazing.
i cant imagine how much time and efort this video took it was amaizing keep up the good work and i hope to see a part 2 for this
Real good kickstart tutorial!
For anyone wondering why their animation only plays a single frame, remember to click the auto-play on load button in the top left of the sprite-frames window. You can see it at 14:10. Missed it the first watch, hope that saves a few minutes of bugfixing
Thanks! In my case i used the .play() and it also worked for me
Thank you so much I was stuck for a while and finally found this divine comment.
Thank you! How do you get all of the animations to play every frame when they're called, for example, if I copy the video for the jumping animation, it only plays the first frame for my jumping animation ( my jump animation consists of 6 frames)
This video was edited fantastically, good job!!! And thank you for the tutorial, I saw a comment recommending a Part 2 for enemies and that would be fantastic, as I've tried getting my enemy character to follow my main character (like a game of tag) and failed pretty miserably!
This was the first tutorial I could follow start to finish and actually understand what I just did. I loved the badge method!
The badges are a nice idea. I think you could expand that idea into a larger tutorial website that tracks profile badges. Would love to watch similar video editing style for 2.5D & 3D in Godot -- though I'm usually watching while using Unreal, Godot has a certain charm.
The badges idea is crazy original...
Your editing and style make everything very easy to follow. For someone like me with adhd, its a blessing that keeps me engaged.
yeah i agree. Alot of tutorials for coding or anything are very similiar. They're instructional. They're not made by someone who clearly has an eye for editing. :)
Incredible video. Amazing pacing, animations, and even badges - what a fun idea! Thanks, you've easily earned a subscriber here!
this is rediculously high quality, thanks a ton for the video!!
I must say this tutorial is very good for:
* Beginners
*Kids
And
* ADHD/Autism people like myself
Because the badges want me to keep going to collect them all. And what's good is he actually explains what settings to use in the beginning, he compare things symbolic with pictures like the root of the tree etc he uses good visual explaining with camera angles and visual effects like when he explains what the scene window is etc.
how da fuh do i fix the unexpected identifier thing
i have same problem@@garythepigeon8600
As someone with ADHD - can't relate. This feels awful. Pacing is too slow, there are zero explanations as to what's actualyl happening / what you are doing. It's pure monkey see, monkey do like any other youtueb tutorial. I really dislike humans at this point. You see a shiny badge and are all "woah woah me good". Monkey brains much?
Noice, I want more videos like this 😍, Keep it up
This video was so clear and understandable! You are truly talented when it comes to this! I am just starting with Godot and this is the first tutorial I found. Thank you so much for this. This is by far the best game engine tutorial I have followed.
Man this is great! I will be keeping an eye out on all future godot videos you post this was top notch with out a doubt.
The juiciest videos and thumbnails in the game.
You made a whole game with minimal scripts good job 👍
Best Godot tutorial I have found yet. One of the best beginner tutorials for game dev in general in fact. First time I feel like I actually understand what is happening.
This is the best tutorial I seen for making your first game. I eagerly await more guides!
Would love to see a tutorial for transitioning between levels
the code isn't working when i type in sprite_2d.flip_h = isleft and my game screen is just black
same
yes, just says unepected "identifier" in class body in red under the script
This is the best intro to Godot tutorial I've seen, the organization by chapters makes it very easy to follow. I'm a relatively experienced programmer with some familiarity in unity and I felt the pacing was perfect
I really appreciate the feedback! 💙 Also, if you enjoyed this one, the second part is now live on my channel
It is my first videos of yours that I have watched. Wow, such quality. Man, you deserve more than you have. Subscribing and will continue watching!
More details:
Badge system - awesome, gives different feel how long video will take and also gives sense of achievement that I am actually learnt something.
Giving tasks and asking pausing video - great way to put learnt things into practice, would love to see a tiny project you could offer for "homework".
Voice and speed - voice is reassuring, easily understandable and you are not rushing resulting in great learning speed (at least for me). Your voice is beautiful for such type of videos.
Thanks again! I understand you would appreciate tips, but if I will create something worth money - will share some with you
Best tutorial ive seen on anything. Not kidding. This is great
Quick tip -
If you're on mac, at 16:18 instead of control, hold down command!
Perfectly structured. Easy to follow.
I love this tutorial! Please more of this!
Such a neat and tidy, short and educational intro to Godot!
I've just come from making a farming simulator using only PyGame for my A-Level school project and now need some more programming to feed my addiction. Thanks for making this sub 1hr intro video it has really helped!
I am having an issue, hoping anyone can help. When I am using 'flip_h' to flip my character, it only flips the image and NOT the collision object. This leads to issues obviously when trying to interact with collectables, enemies, and environment. Can anyone offer advice?
at 16:58 im stuck as it keeps saying unexpected "identifier" what do i do to fix this
me too!
@@HunyBread_ Same
@@marius3020 same
I must say... great job man. From all tutorials,your tutorial was best. Easy to follow and explain everything. I like this style like in school, do one part ,and then let kids do other, that style is perfect. Great job again!
I've watched tons of godot videos but i felt like i actually learnt something with this one! thank you Coco
I am an aspiring software engineer, not a huge gamer but wanted to dip my toes into gameDev. After reading the comments about Unities latest actions I decided to go with Godot. This is so far the best tutorial I’ve found, please make more of these tutorials for Godot. Would like an enemy tutorial for the 2D platformer pls 🙏Thank you
This is awesome to hear! "Software Engineer" Can be a pretty broad term. In fact in parts of Canada recently you cant even use this title without a license!! That aside I am just going to assume python or JavaScript! I am an app/web developer I would defo recommend maybe learning a language before you delve into godot. Maybe someone could weigh in :) But Godot uses its own language (or C# which if you use ignore my whole theory) which is so easy to pickup if you already know a language like javascript or python BUT I would worry for a beginner it would be confusing the other way around! That being said at least you would learn variables, functions, conditionals and loops.
I actually have been learning Python the past year, went back to college in August and learning Java/C++ in school as well. I really like Godots language, it’s very intuitive
Thanks for this great tutorial!
If you want to permantly face your character in the correct direction, you can do this:
if Input.is_action_pressed("left"):
sprite_2d.flip_h = true
if Input.is_action_pressed("right"):
sprite_2d.flip_h = false
Hi, hope you are well! Where should I insert this line of code?
Fantastic tutorial. Many thanks - also for the detailed descriptions and great examples that you keep showing (e.g. with the collision body for Mario)
Very clear, easy to follow, packed with a lot of info in a short, well paced tutorial. Thank you!
Thank you! Hope you learned something and watched the 2nd part as well ;)
i cant add background :(
One of the latest, best and concise tutorials out there for Godot now, thanks a lot!
For some reason the sprite_2d.flip_h = isLeft is saying unexpected identifier in class body? I held control and dragged the Sprite2D into the script editor. Not entirely sure the bug here. Otherwise, as a brand new learner, your tutorial is phenomenal.
Hi, had the same issue and the user @litt1epenguin552 gave a solution that worked from me under an another comment, i'll copy paste his response below (all credits to him)
Ahoy friend, I had the same problem but I just figured it out. delete the codes on the bottom that he tells you to do (var isLeft = velocity.x < 0, sprite_2d.flip_h = isLeft) hover over "move_and_slide()" click the end of the code then click enter twice. what should happen is should get two spots that should has this " >I " in the beginning of the spots
i think clicking tab should also get the ">I " symbol in front of the spots as well
( I hope this helps)
For those surfing comments looking for the answer: make sure those 2 lines are inside of _physics_process(delta)
just in case anyone else do the same as i did : don't forget to reference the object like it is said at 16:10, otherwise the code won't work
Great video!
I look forward to more tutorials in the future and the C# script was great for anyone looking to try out the language.
Im just getting started in game development and this tutorial has been so helpful dude thanks
When trying to have the character flip following the code @16:57 I am getting the following error and the game won't run with it "Error at (33, 1) : Unexpected "Identifier" in class body." Line 33 corresponds to the 'sprite_2d.flip_h = isLeft' line of code. I also made show to hold ctrl etc when importing the sprite body into the script as instructed so my code mirrors that seen here in the tutorial (I tried with and without holding 'ctrl' to see what difference it made to script/game). Any help appreciated here as I'm sure I'm doing something really stupid somewhere.
I'm getting the exact same error. Did you figure it out?
me to@@CT2507
i pressed tab before the last line of code he writes and it worked@@CT2507
Me too. I can´t seem to find what the problem is
Figured it out. need to press tab to add an indent (little arrow at the left of your line)
Is this outdated the “sprite_2d.flip_h = is left” it’s saying it’s an error
yeah i get the same problem
it seems like i fixed it by doing this:
var isleft = velocity.x < 0
if isleft:
sprite_2d.flip_h = true
else:
sprite_2d.flip_h = false
Remember to put in the indent blocks (TAB) in the same way as the code above
hope it helps :)
@@newbiesk8ter thanks ill try it!
just in case anyone else do the same as i did : don't forget to reference the object like it is said at 16:10, otherwise the code won't work
Great video man 👍 tried to play around myself as well as following their getting started project turtorial, this video nicely summarizes what a beginner needs to get started
Thank you. This is the first tutorial I've watched and it was very satisfying. I'm new to Godot and game development. I just started to do research on how to learn game development and this video was spot on. (side note: in 16:16 on Mac the "control" key is "command" when dragging the Sprite2D before release the mouse button)
As I'm new I wonder where to go next? (waiting for part 2) 😀
I have started preparing for my dream game. The written part is under way, while starting to learn the tools to make it possible.
Thank you once again, I subscribed and look forward to learning more from you Coco Code!
creating this with you was very fun. thank you!
Thank you so much I’m new to game development and this is the best tutorial I will definitely recommend to other people!
honestly the best tutorial for this ive seen bro good job. Will be coming back to this video for sure.
all i can say is that this video explains every single component in making a game in which is very helpful for someone who wants to try making a game
one of the best tutorial and god-like editing skills
Man youre edit quality is great keep up the work man!
Absolutely the best first tutorial I've seen! Thank you
Thank you so much, I’ve tried unreal and unity before but unity wouldn’t work and my pc was too bad for unreal so I checked out your video, and now I have my first game, thank you for taking the time to make a quality tutorial for new godot devs
Thanks for covering Godot. there are a large number of new Godot users, myself included... who needed more tutorials 😍
This is the best Tutorial I have ever seen! Not just for Godot, for ANYTHING EVER. Thank you so much for this absolute perfect introduction to Godot
Thank you! Be sure to check out part 2 on my channel ;)
I really liked this tutorial. Now I can start making my first game slowly. Thank you and I wish you the best! :)
One of best tutorial/courses I've seen the way you built the dynamic of the content is top notch
Thank you!
You just made Godot my first option for game developement, such a nice tutorial!
That's awesome, I'll try to make a little video game for the first time and this helps a lot, so thank you!
By far the most useful tutorial i have seen so far! Thank you!
the editing on this is insane literally the best video to learn
Thanks Coco Code! Your Unity tutorials are super useful and hope you continue making Godot videos as well!
Wow, you explained the basics for a newbie like me very well! Thank you so much.
Hi! I just followed this tutorial. As a guy with pre-existing software skills, I would've been comfortable with more code, but this was an incredible introduction to the toolset. Thank you very much, I am excited to try and make a game!
Just in case anyone for some reason is having the same problem that I was having, if at 16:50 you could not get sprite_2d to pop up as a variable and keep getting the error that an unexpected identifier is in that line, that may be because the because the indentation of the line is missing. Notice the arrow with a line on the left, make sure yours are on the same lines as his. If they are not, just hit tab to indent those lines and sprite_2d should show up as a variable when you type it.
This was an amazing intro to Godot! Thank you for the time and effort you gave to use I’m thankful 🙏
Very simple, very easy, and love the badge sys. ty sir
Thank you so much for your time, this is a really good video, really good explanation of the engine and pretty straightforward tutorial for beginners.
much appreciated
Very comprehensive. Appreciate your massive effort.
this is one of the best tutorials out there for beginners!
OMG Finally Someone who knows How to teach Godot. I Tried for decades to Learn! Ty SO MUCH!!!
How is he dragging tile set to tile map. Iam unable to do that
Thank you for your amazing video! Very helpful!
these tutorials are so in depth i love them its a shame your not that famous