Flappy Bird in Python & Pygame | 40 minutes | Updated 2022

Sdílet
Vložit
  • čas přidán 22. 07. 2024
  • Let's build FlappyBird with Python and Pygame.
    ◾◾◾◾◾ Resources ◾◾◾◾◾
    📝 Get the Code: github.com/maxontech/flappy-bird
    ⚙️ Assets & Images: github.com/maxontech/flappy-b...
    ◾◾◾◾◾ Timestamps ◾◾◾◾◾
    00:00 | Part 1.0: Introduction
    01:21 | Part 1.1: Setup Project in PyCharm
    03:20 | Part 1.2: Blank Pygame Canvas
    05:40 | Part 1.3: Draw Background & Ground
    12:28 | Part 2.0: Making the Flapping Bird
    15:07 | Part 2.1: Animating the Bird
    17:40 | Part 2.2: Adding the Flap aka. Jump
    23:55 | Part 2.3: Rotating the Bird
    24:15 | Part 3.0: Creating the Pipes
    28:16 | Part 4.0: Collisions & Score
    31:06 | Part 4.1: Score
    35:15 | Part 4.2: Collisions
    37:15 | Part 5.0: Menu Screen
    ◾◾◾◾◾ Related Content ◾◾◾◾◾
    🚗 Self-Driving Car in Python: • A.I. Learns to DRIVE #...
    🕹️ Pygame Tutorials: • Pygame Tutorials
    🐍 PyCharm Tutorials: • Flappy Bird Tutorial
    ◾◾◾◾◾ 🌎 Let's Connect! ◾◾◾◾◾
    🐦 Twitter (X): 🔗 / @max_on_tech
    📂 GitHub: 🔗 github.com/maxontech
    🔊 Discord: 🔗 / discord
    🏹 ProductHunt: 🔗 www.producthunt.com/@m4x
    ✅ Blog: 🔗 maxontech.io/courses
    ◾◾◾◾◾ Hashtags ◾◾◾◾◾
    #pygame #flappybird #pythonbeginners

Komentáře • 27

  • @oxigeniocozido4607
    @oxigeniocozido4607 Před 7 měsíci +6

    hello, i am andre, from portugal, i am doing a school project and i needed do create a game in python. I am an absolute shit in programming so i needed someone to explain me everything (my teacher is an asshole). I am very happy that I found your video, the only changes that I made was substituite the bird imaagem for cristiano ronaldo´s and pipes for messi ahahaha. Thank you for everything. Enjoy, hugs

    • @MaxOnTech
      @MaxOnTech  Před 7 měsíci

      Hey, that's awesome! Haha and a very creative choice of images. Love it!

  • @FabledNarrative
    @FabledNarrative Před 2 lety +2

    Max, you're a great teacher!
    Keep up the work. :D

    • @MaxOnTech
      @MaxOnTech  Před 2 lety +1

      thanks :) will definitely keep posting!

  • @subarunatsuki1902
    @subarunatsuki1902 Před 2 lety +3

    Awesome!

  • @realcontentgamer
    @realcontentgamer Před rokem +1

    really liked it!

    • @MaxOnTech
      @MaxOnTech  Před rokem

      stay tuned. adding an AI to this game next. No libraries!!

  • @extremoleste8310
    @extremoleste8310 Před 2 lety +1

    Max theaches, I honestly thought it was better like you did, a tutorial in a single video,
    It was very good

    • @MaxOnTech
      @MaxOnTech  Před 2 lety +1

      Okay, so all in one is better than separate videos. I think that you are right

    • @FabledNarrative
      @FabledNarrative Před 2 lety

      @@MaxOnTech You probably could do separate videos as well, in a playlist, but the complete tutorial helps a lot, too.

    • @MaxOnTech
      @MaxOnTech  Před 2 lety

      For this episode I did both so a split version and a merged one. I'm not entirely sure what is best long term...

  • @partorg4741
    @partorg4741 Před rokem +1

    Awesome tutorial!!!!

  • @moonknight355
    @moonknight355 Před měsícem +1

    Hi I did all the same but I dont know why I when I click space bar 2nd time bird doesnt react and just fall down it is because of cooldown and if so how to fix it?

  • @elarvis
    @elarvis Před rokem

    Hey. great toturial.
    quick question.
    why would you add the score measuring the birds position relative to the pipes instead of just saying
    if bottom_pipe_x == 100;
    score += 1

    • @MaxOnTech
      @MaxOnTech  Před rokem

      jo, that's a lot smarter haha! I'll probably do that when I release the ai flappy bird video :D thanks!

  • @speedfusionx
    @speedfusionx Před 2 lety +2

    👾🔥🔥🔥🔥

  • @FusionEpicGamer
    @FusionEpicGamer Před 2 měsíci

    Hey max, could i do this in visual studio? if so is there anything i need to change to make it work?
    I will come back to this video when i have that answer, thanks

    • @MaxOnTech
      @MaxOnTech  Před 2 měsíci

      hey, yes, should also work. You probably need to install am extension that runs python in visual studio.

  • @theslayer9164
    @theslayer9164 Před 2 měsíci

    im getting an index out of range error with the bird

  • @suhay1a
    @suhay1a Před rokem +1

    Hi, this was a very useful vid! Do you know how to code a high score?

    • @MaxOnTech
      @MaxOnTech  Před rokem

      hey :) quite honestly, I'm not quite sure how to...haven't tried that yet 🤔

    • @FusionEpicGamer
      @FusionEpicGamer Před 2 měsíci

      it probably isn't that simple but think you could do something that works like this:
      if (score variable) > (high score variable) then
      (high score variable) = (score variable)
      end
      I'm very new to python but i have done other languages and this should work, due to me not knowing python so well its beyond me how to put it on screen but you could probably use the same steps as the score just instead label it high score, hope this helps!

  • @VasileTraian22
    @VasileTraian22 Před 5 dny

    does it work in 2024?

  • @user-ll7ln2ix5w
    @user-ll7ln2ix5w Před 5 měsíci

    Hello very nice video, would it be possible to send me the entire code? thank you.