Beginner Godot Tutorial - Make Flappy Bird in 12 Minutes!

แชร์
ฝัง
  • เผยแพร่เมื่อ 6 ก.ย. 2024
  • Learn the basics of Godot by making a flappy bird clone in this tutorial.
    The code for the game is built from scratch and will cover setting up the different scenes and their nodes as well as linking everything together using signals. I will add a pipe generator as well as collision detection for the pipes and ground.
    Code and assets for this video: github.com/rus...

ความคิดเห็น • 118

  • @bedang1058
    @bedang1058 2 หลายเดือนก่อน +11

    Annnnd thats how you watch a 12 minutes video in 1.5 hours !

    • @jankutac9753
      @jankutac9753 5 วันที่ผ่านมา

      hell yeah. I mean would it kill him to pause a little bit between actions, and show what he is clicking on a bit longer than half a second? :-D

  • @Sabbalab92
    @Sabbalab92 11 วันที่ผ่านมา +3

    Thanks for this. I've been trying to learn GDScript. I didn't understand everything you showed, but this is definitely a good start for when I make more progress.

    • @CodingWithRuss
      @CodingWithRuss  10 วันที่ผ่านมา

      Thanks! Yea this video is a little bit fast, I probably shouldn't have called it a beginner tutorial as it's difficult to follow if you've never used godot before.

  • @ilhomsoliev275
    @ilhomsoliev275 8 หลายเดือนก่อน +13

    Keep doing complete projects on Godot 4, you are gold!

  • @zigzag.ahmed2209
    @zigzag.ahmed2209 5 หลายเดือนก่อน +4

    extends CharacterBody2D
    const GRAVITY : int = 1000
    const MAX_VEL : int = 600
    const FLAP_SPEED : int = -500
    var flying : bool = false
    var falling : bool = false
    const START_POS = Vector2(100, 400)

  • @yeaglaceshorts546
    @yeaglaceshorts546 4 หลายเดือนก่อน +3

    I used this to spawn in a ball for a new plinko clicker I am making. It was super helpful. Thanks!

  • @dragosilies5764
    @dragosilies5764 4 หลายเดือนก่อน +3

    Great tutorial, I like that you didn't spend too much time explaining concepts. Great when coming from Unity

  • @FriskTemmieGoogle
    @FriskTemmieGoogle 2 หลายเดือนก่อน +7

    really good tutorial! It was perfect as a "hello world" to get me used to this game engine. I was easily able to change things to my liking and even add a
    "Get Ready!
    "TAP TAP"
    screen, like in the original game. I'll probably add the ability of changing the color of the bird next as a little challenge

    • @CodingWithRuss
      @CodingWithRuss  2 หลายเดือนก่อน +1

      Thanks! I like the little tweaks you're adding :)

  • @moza1793
    @moza1793 6 หลายเดือนก่อน +4

    Thank you so much for the guide!
    I just tried godot this year and haven't fully grasp the UI yet. But, this video explained it very well for a beginner. of course it's probably will be better if you can slow it down at some specific point.
    I'll definitely watch the other guide to make games!

  • @excelucate
    @excelucate 5 หลายเดือนก่อน +3

    Thank you very much, I'd say one of the best explained. You do need a high level of attention to detail, it took me two attempts to make it work (says a lot about me i guess).
    I can understand the editing took a lot of time and effort but in some places it was not easy to follow so lowering the setting playback speed helped.
    Having said that this was a brilliant video and great to see someone make a complete game with all of the code available.
    Keep up the great work it is appreciated!

    • @CodingWithRuss
      @CodingWithRuss  5 หลายเดือนก่อน +1

      Thanks! The funny thing is that with all the editing, this video took me about as long to make as it would have if I made a full length tutorial 😅
      Glad you found it useful though!

  • @CadeHLife
    @CadeHLife 2 หลายเดือนก่อน

    After following a few other in depth tutorials to get a basic understanding of core Godot features, this was a fantastic next step for me! Such a fast and rewarding way to help grasp concepts and actually prove to people that they can make a game. As I was pausing and copying code it had me thinking "oh yeah that makes sense" and "OH so this is connecting from what we already implemented here" I will definitely be checking out your other videos. Thank you!

  • @Cyynapse
    @Cyynapse 5 หลายเดือนก่อน +2

    i really like how concise this is. it encourages you to actually learn the software instead of just copy what you see

  • @Swagster1000-sy3ng
    @Swagster1000-sy3ng 3 หลายเดือนก่อน +2

    These tutorials are really good.
    I do have one issue though.
    In this game and the dino run, when I plug the same data, the game movement speed is way faster.
    Example, I had the same numbers, and the pipes moved at blistering speeds.

    • @alekkrustev2069
      @alekkrustev2069 17 วันที่ผ่านมา

      It was the same for me, try to change the SCROLL_SPEED from 4 to a lesser number like 2 for me it should help

  • @rohitsoni2109
    @rohitsoni2109 2 หลายเดือนก่อน +1

    Great tut. On point, no time wasted.

  • @benderrodriguez91
    @benderrodriguez91 7 หลายเดือนก่อน +1

    This was very well done, although 12 Minutes video turned into 1.5h of actually doing the steps :P

  • @alexxgg9208
    @alexxgg9208 2 หลายเดือนก่อน +2

    idk 12 min. rebuilding and really understanding hours xD. very good video but i like longer videos with more explanations!

  • @vegasdealer777
    @vegasdealer777 11 หลายเดือนก่อน +2

    Thanks, Russ, for sharing your knowledge. I'm trying to convert a video poker app I wrote in Python/Pygame to Godot 4. After Snake and TicTacToe, I'm finally 'getting' Godot a little bit. I haven't watched Flappy Bird yet, but I'm sure it'll be helpful.

    • @CodingWithRuss
      @CodingWithRuss  11 หลายเดือนก่อน +1

      Glad to hear it's starting to come together. I switched from pygame to Godot not too long ago so it's a learning curve for me too!

  • @FriskTemmieGoogle
    @FriskTemmieGoogle 2 หลายเดือนก่อน +1

    Idk if this bug is because of the new Godot version, but 5:28 didn't work for me. After messing around a little, I figured that the reason was that the variable "scroll" didn't have a type assigned to it (I'm sorry if I'm making some kind of mistake with the proper names), so changing the line 5 from "var scroll" to "var scroll : int" fixed the problem and let me run the game with the ground moving

    • @FriskTemmieGoogle
      @FriskTemmieGoogle 2 หลายเดือนก่อน

      09:05 I found another bug here which could also be from the version. My pipes still didn't have collision and the pipe scene had a yellow triangle on the collisions, saying that they couldn't be connected to a sprite2D node. I changed the order, connecting them directly to Area2D "Pipe" node and that fixed everything. I ofc changed the names for better understanding of what was what

    • @FriskTemmieGoogle
      @FriskTemmieGoogle 2 หลายเดือนก่อน

      09:57 now I realize that I just did it wrong when I was setting it up, mb

  • @cccornel5965
    @cccornel5965 10 หลายเดือนก่อน +1

    After following the video and doing everything in it, I found out I suck a FlappyBird
    Thanks for the video

  • @uh7123zz1azxcv
    @uh7123zz1azxcv 11 หลายเดือนก่อน +4

    thanks for the tuts Russ...
    I really don't like the copy paste approach that you've been using in your latest couple of vids. The old coding along style was much better imho. hope you can return to using that instead

    • @CodingWithRuss
      @CodingWithRuss  11 หลายเดือนก่อน +3

      Thanks for the feedback, it's good for me to know whether people like the new approach or not. I thought people would find the code along style repetitive plus those videos take much longer to make so I switched it up. I have a few more short style tutorials planned so once they are done, I'll look at which style is preferred and try to find a balance.

  • @Wallee580
    @Wallee580 11 หลายเดือนก่อน +2

    I've been playing Marshmallow Land (it's a built-in hidden Android game) so it's quite good timing that you make this. xD

    • @CodingWithRuss
      @CodingWithRuss  11 หลายเดือนก่อน +2

      I had to google that, can't believe I never heard of it before...I've had an android phone for years 😅. Looks like a very similar concept game.

  • @Multifandomguy
    @Multifandomguy 2 หลายเดือนก่อน +1

    4:07 hey I got an error here
    when I clicked play, the engine says to me there's an error, which is the reset() function isn't declared in the original Bird scene
    is there any solution to this glitch ???

    • @BenitoBeni1414
      @BenitoBeni1414 หลายเดือนก่อน +1

      I have the same glitch, idk what to do

    • @tjjfhdgdhtfwtwthdjffgxhfhxhwjn
      @tjjfhdgdhtfwtwthdjffgxhfhxhwjn 12 วันที่ผ่านมา

      this error should mean that you haven't created the function reset in the Bird.gd script. when you declare it it should look like this:
      func reset():
      falling = false
      flying = false
      position = START_POS
      set_rotation(0)
      You may have accidentally declared it inside another function (for example the _ready() function)

  • @ZackSadlygrove
    @ZackSadlygrove 5 หลายเดือนก่อน +1

    When I press the mouse button nothing happens

    • @BAD_GAME_DEV
      @BAD_GAME_DEV 4 หลายเดือนก่อน

      Did you set up the input correctly in project settings?

  • @gaWalt
    @gaWalt 4 หลายเดือนก่อน +2

    Hello Russ, who did all the graphics for you?
    I'm still working on your pygame tutorials but I like the look of the Godot games much better. I'll see if I can follow along on this tutorial and just might switch over to Godot for my future games.
    Thanks, Gary

    • @CodingWithRuss
      @CodingWithRuss  4 หลายเดือนก่อน

      Hi Gary, I just find them online, there are lots of open source images that can be used with or without attribution. I try to credit all my sources in the video description although I couldn't remember where I got the images for this game so I couldn't reference them.

    • @gaWalt
      @gaWalt 4 หลายเดือนก่อน

      Thanks Russ and keep on making these great tutorials!

  • @YankaZabka
    @YankaZabka 9 หลายเดือนก่อน +2

    Hey Russ, I'd like to ask about the formulas in your tutorial, like:
    `if flying:
    set_rotation(deg_to_rad(velocity.y * 0.05))`
    or
    `pipe.position.y = (screen_size.y - ground_height) / 2 + randi_range(-PIPE_RANGE, PIPE_RANGE)`
    As a newcomer to game development, I'm curious about their origin. Are these from your game dev experience, established best practices, or custom calculations for this project? Those techniques work great, and I'd like to learn more about them. Thanks!

    • @CodingWithRuss
      @CodingWithRuss  9 หลายเดือนก่อน +4

      Hello. I'm self taught so this stuff comes from previous experience making these kinds of games (I made flappy bird in pygame a couple years back) and also just trying different things and refining them until they work.
      I try to avoid manually entering numbers and instead use the data available in the game, so that's what is going on with the second formula. I sketched out the position that I wanted to calculate, then looked at what existing variables I can use for reference and came up with an equation to tie them together.

  • @JacobVega
    @JacobVega 2 หลายเดือนก่อน +1

    A really great tutorial. I had managed to get everything working, but after customizing the textures of the pipes to my own designs, the game keeps crashing (freezing/Not Responding) when the "generate_pipes()" function is run. Whenever the timer first ends, it freezes and in the "Stack Trace" window, it says "Cannot call method 'instantiate' on a null value. And then in Stack Frames are below that message in the window, it lists the "at function: generate_pipes" and "at function: _on_pipe_timer_timeout" in the list. I've looked through the tutorial and can't seem to find what's different between the code. Any ideas what could be the problem or how to fix?
    Note: I don't really know what caused the crashing, because I did get it to work with the different textures for a couple runs of it.

    • @JacobVega
      @JacobVega 2 หลายเดือนก่อน

      Update: I fixed it. For some reason, the problem was that the pipe scene got unlinked from the variable. Idk how it happened, but I linked it back and it works now. Again, thanks for the great tutorial!

  • @txmasgxmes3597
    @txmasgxmes3597 8 หลายเดือนก่อน +2

    Very helpful and I did learn! Thank you!

  • @MoviesManiac-u7r
    @MoviesManiac-u7r หลายเดือนก่อน

    i have a problem my charecter is stuck at one place and doens not go up nor done when clicked it just rotates but does go up or down please help

  • @user-dt9xm3su8r
    @user-dt9xm3su8r 9 หลายเดือนก่อน +2

    Thank you for sharing your knowledge and for being straightforward.

  • @BenitoBeni1414
    @BenitoBeni1414 หลายเดือนก่อน

    Im trying to make it go to the center but it just stays on the corner

  • @MahmudShuaib
    @MahmudShuaib 10 หลายเดือนก่อน

    this short video style is awesome. But it helps if one knows a little Godot. i have used Godot 4 for just a week and i can easily follow along. However the classic ross will work effectively for non beginners. either way this is super cool.

  • @Multifandomguy
    @Multifandomguy 8 วันที่ผ่านมา

    I have a glitch where the pipes don't appear at all, is there any reason ?

  • @diegoandradex12
    @diegoandradex12 8 หลายเดือนก่อน

    Nice and clearly explained! Everything worked here

  • @kshawn2579
    @kshawn2579 10 หลายเดือนก่อน +2

    THIS MAN IS SO UNDERRATED! HOW DOES HE NOT HAVE 1 MILLION SUBS??

  • @paykol3280
    @paykol3280 6 หลายเดือนก่อน +1

    I love the vid dude but i have one problem when i try to run the game it has a error with $Bird.reset() and the error it gives is
    main.gd:24 @ new_game(): Node not found: "bird" (relative to "/root/Main").
    i tried for so long how do i fix this?

    • @dezatoosweet
      @dezatoosweet 5 หลายเดือนก่อน

      I think it's because your 'bird' has a lower case b. Make the node Bird and it should be okay.

    • @paykol3280
      @paykol3280 5 หลายเดือนก่อน

      @@dezatoosweet I'll try thanks

  • @hownotto4067
    @hownotto4067 10 หลายเดือนก่อน

    I would definitely do code along. it seems like your niche. because people like me who are web developers and want to dabble in video game creation... so those people will love code explanations and walk throughs to increase their knowledge

  • @PabloJFerri
    @PabloJFerri 7 หลายเดือนก่อน +1

    Hello im making this in Godot 4.2 and i did all the same and this happen
    Invalid get index 'position' (on base: 'previously freed'). and the game instantly crash and doesnt let me even execute it.
    2 breakpoints are marked.
    1) Line of code 10: var screen_size : Vector2i
    2) Line of code 60: for pipe in pipes:
    pipe.position.x -= SCROLL_SPEED

    • @itsCH4PO
      @itsCH4PO 5 หลายเดือนก่อน

      I had this same issue.
      Be sure to add the "pipes.clear()" function below this call.
      It did this because the "queue_free" method removes the pipes from memory, so it's basically looking for a "null" value when accessing the position.x of the pipe in the pipes array (even tho we're generating new pipes... idk memory management 101 I guess).
      Not sure if this exactly helps, I'm still learning myself! LMK what happens.

  • @JetFireHawk
    @JetFireHawk 2 หลายเดือนก่อน

    my bird doesnt go up and down and i am unsure why i have written your code exactly but my bird just flaps once for a second and then just stays in the animation and doesnt move properly he kind of jolts and tilts a bit but its llike he is stuck with a pin to a certain place. is this because i used a different texture than you?

  • @Aoi_Hikari
    @Aoi_Hikari 2 หลายเดือนก่อน

    the amount of times i pause in this video prob equivalent to me watching a 1 hour tutorial, but still, i pretty much prefer this type of fast pace tutorial

  • @gamepatio1010
    @gamepatio1010 4 หลายเดือนก่อน

    do you know why when pipes spawn sometimes there are space between pipes and ground ? and when new game pipe spawn in front of bird ?

  • @gustavk5331
    @gustavk5331 2 หลายเดือนก่อน

    Hi - When creating the bird you say "Save the scene in that same folder". What do you mean? When I try to save the scene in the same folder as the background, I just get an errorr.

  • @algorif4715
    @algorif4715 5 หลายเดือนก่อน

    hopefully with this i can finally get the grade i need to pass one of my tech classes, thank u for giving what was supposed to be gave

  • @simranjhahere
    @simranjhahere 8 หลายเดือนก่อน +1

    loved it !💯💯

  • @GhostGirlBlues
    @GhostGirlBlues 7 หลายเดือนก่อน

    been struggling along for hours. more and more issues as i got deeper in. double and triple checked the code compared to the gdscript provided and shown in video. can't get the pipes to appear. and the bird falls through the floor for a very very long time. and the ceiling area detection doesn't seem to be at the right height

    • @GhostGirlBlues
      @GhostGirlBlues 7 หลายเดือนก่อน +2

      started over from scratch and spent another day struggling through. i finally got it to work. thank you for this and the pong tutorial. what i've learned is that you have to be extremely exactly perfectly precise. part of the difficulty for me is that this one felt a bit too fast. "blink and you miss it" kind of stuff threw a wrench in things several times

  • @brianmcelroy9922
    @brianmcelroy9922 3 หลายเดือนก่อน +1

    I love these videos, but sometimes you go too fast and I miss some code lines or something

  • @G-Major
    @G-Major 10 หลายเดือนก่อน

    I'm new to Godot and I appreciate the example here, thank you. I do have a quick question. Is it normal for autocomplete to sometimes not work? Like while I was following along, when I typed pipe.position or $Bird.falling, it wouldn't autocomplete position or falling. Does it behave that way for you too?

    • @saifee7899
      @saifee7899 9 หลายเดือนก่อน

      yeah it did the same thing for position for me
      im pretty sure its jsut random

  • @ArthurHuizar
    @ArthurHuizar 2 หลายเดือนก่อน

    how do i stop Godot from anti-aliasing my pixel art?

    • @dodsonboys
      @dodsonboys 2 หลายเดือนก่อน +1

      Go into the project settings, under rendering and textures set the default texture filter to nearest instead of linear

  • @thesomeone2nd
    @thesomeone2nd 5 หลายเดือนก่อน +1

    Well done thx dude

  • @oxxn111
    @oxxn111 10 หลายเดือนก่อน +1

    thank you!

  • @azariasbarboza9774
    @azariasbarboza9774 9 หลายเดือนก่อน +2

    Tengo un problema, mis tubos se colocan muy abajo dejando poco y casi nada de espacio para que el ave pueda pasar, cómo lo puedo solucionar?

  • @soup_bone
    @soup_bone 8 หลายเดือนก่อน +2

    I think I'm cursed i followed this to the exact and i got to 4:05 mins and nothing happened lmao

    • @Mosaeedaly
      @Mosaeedaly 7 หลายเดือนก่อน +1

      same

    • @Mosaeedaly
      @Mosaeedaly 7 หลายเดือนก่อน

      found the solution . in bird script i changet this line from = to += ( velocity.y += GRAVITY * delta)

  • @CubeOrSomething
    @CubeOrSomething 8 หลายเดือนก่อน +15

    Hard to follow along, try to show slower steps.

  • @crowxar
    @crowxar 5 หลายเดือนก่อน +1

    I wish you would explain why instead of just a step-by-step.

  • @Cr7isthenumber1
    @Cr7isthenumber1 4 หลายเดือนก่อน

    where can i get the animation

  • @paulpenguin1985
    @paulpenguin1985 7 หลายเดือนก่อน

    i'm learning godot but it is just so Madding!

  • @usateam.
    @usateam. 2 หลายเดือนก่อน

    Мне кажется или спрайты дергаются?

  • @user-lu8nr9uf9l
    @user-lu8nr9uf9l 9 หลายเดือนก่อน +1

    its says that it doesnt exist

    • @PaulJonesy
      @PaulJonesy 9 หลายเดือนก่อน

      Deep.

  • @TechnicalParadox
    @TechnicalParadox 7 หลายเดือนก่อน

    Bird_hit doesnt work for me, My bird continues flying through pipes even after 9:00

    • @MannaHay
      @MannaHay 6 หลายเดือนก่อน +1

      I had the same issue. Turns out I'd created the node in the Main scene as a "Node2D" instead of just a "Node"

    • @aija_papaya
      @aija_papaya 6 หลายเดือนก่อน

      Have the same issue. I am trying to make a computer game for the first time at all. Don't understand whats nok... My main scene is "Node". @TechnicalParadox did you solve your issue and how?

    • @TechnicalParadox
      @TechnicalParadox 6 หลายเดือนก่อน

      @@aija_papaya I didn't specifically fix this issue but I took a Godot course on udemy. Make sure the area or body of the bird has the on_area_entered or on_body_entered linked to the script. If that's good then check the collision properties of the bird and of the pipes, other than that I can't think of anything else it wouldve been

    • @aija_papaya
      @aija_papaya 6 หลายเดือนก่อน +1

      I found my issue :) In Pipe script the function "func _on_body_entered(body):" was not connected. :)

    • @TechnicalParadox
      @TechnicalParadox 6 หลายเดือนก่อน

      @@aija_papaya sorry I had typed out a reply earlier but must not have sent it. I never fixed this issue in this project but I took a udemy course for godot since and yeah it's either that the script wasn't connected to the signal or the collision layers are messed up, or you have a mix up between area/body and are using wrong function

  • @SoledadGamingofficial
    @SoledadGamingofficial 4 หลายเดือนก่อน +1

    Is this work on mobile?

  • @mrfrog0913
    @mrfrog0913 7 หลายเดือนก่อน

    Thanks

  • @Vertigo97
    @Vertigo97 3 หลายเดือนก่อน +2

    Please actually explain what your doing at a slower pace, if I just blindly follow along as a beginner I won’t actually learn anything.

  • @kamnachhoker6860
    @kamnachhoker6860 11 หลายเดือนก่อน

    Plz make a 3d foghting game in ursina of guns plz

  • @saposabio03
    @saposabio03 4 หลายเดือนก่อน

    it works!

  • @Hello-cy4gx
    @Hello-cy4gx 11 หลายเดือนก่อน

    @Coding With Russ
    Can you make tutorials for roblox studios please?
    I wanna learn how to make games in roblox but I don't have that much money. Thanks

  • @vietlongpham
    @vietlongpham 7 หลายเดือนก่อน

    6:48

  • @TheTiger4343
    @TheTiger4343 20 วันที่ผ่านมา +1

    TERRIBLE tutorial, I just started Godot 4.3, and I was looking for a simple tutorial to fit my needs. I have some experience with python so I thought it would be easy. I found this tutorial, and it went WAY too fast for an absolute beginner. He 'explained it' and what I mean is he said what the code would do and not what the code actually does functionally. Not recommended for anyone with no Godot experience, like me.

  • @user-ll7ln2ix5w
    @user-ll7ln2ix5w 7 หลายเดือนก่อน

    Hello nice video, would it be possible to send me the entire code please?

  • @user-lu8nr9uf9l
    @user-lu8nr9uf9l 10 หลายเดือนก่อน

    this is a lot of code

  • @chrisnorthall8317
    @chrisnorthall8317 11 หลายเดือนก่อน

    I actually find this more complex than just coding the game from scratch!😅

  • @The-MaliX
    @The-MaliX 9 หลายเดือนก่อน

    you cant just copy and paste it in the video you gotta type with us

    • @MEMEBEAN6960
      @MEMEBEAN6960 8 หลายเดือนก่อน

      You see what is written, just read

  • @itscine
    @itscine 7 หลายเดือนก่อน +2

    my pro hacker coder friend says ur code is DOODOO please make easier code for us beginners UwU!!!!! TY DADDY mwahh!!!

  • @sleepy_b0iz
    @sleepy_b0iz 9 หลายเดือนก่อน

    thank you for the tutorial but when i opened it up it said
    E 0:00:00:0637 Main.gd:28 @ new_game(): Node not found: "ScoreLabel" (relative to "/root/Main").
    Method/function failed. Returning: nullptr
    scene/main/node.cpp:1634 @ get_node()
    Main.gd:28 @ new_game()
    Main.gd:20 @ _ready()
    i did just copy paste the code so im guessing thats where i went wrong but how do i fix it or do i just gotta redo the code parts?

    • @CHHATRAPHULARA
      @CHHATRAPHULARA 9 หลายเดือนก่อน

      yeah, really wanted solution to this. I also copy and pasted code and followed all the tutorial but same error is occuring. Please explain whats the issue

    • @CHHATRAPHULARA
      @CHHATRAPHULARA 9 หลายเดือนก่อน

      finally found the error, in code of github underscore"_" was missing like _body, _delta and another mistake was i wrote names of node in small letters but in code it was capital

  • @rezashir3873
    @rezashir3873 11 หลายเดือนก่อน +1

    really nice. thanks a lot