Learn Python by Building a Snake Game under 10 minutes

แชร์
ฝัง
  • เผยแพร่เมื่อ 30 ก.ย. 2024
  • building a classic Snake game using Python and Pygame. ive left comment explaining what each code does

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

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

    ahh man what an organized and beautiful code good work it also give me some insparation to also make my code organizable

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

    Nice video, just learned things that I didn't know about Python. However, the game as a little error. After you die if you try to play again you instantly die again.

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

      i think its in direction change variables :x1_change and y1_change,when game restarts, snake is likely continuin to move in the same direction it was moving givin to an immediate end game. haven't worked on it just made it up and running, ill put it up on github

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

      @@scriptsonneteer Ok, thank you :D

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

      i fixed it by myself btw

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

    can someone explain at 1:26 how he coded that rectangle ??

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

      using the pygame.draw.rect

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

    Hey! Im new and cannot find where you've assigned 'snake_list' any value. at 1:25

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

      its assigned and managed within the gameLoop function.

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

    Great concept

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

    love how you handled this topic, very insightful!

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

    no background audio

  • @MrSmart-tp8ko
    @MrSmart-tp8ko 3 หลายเดือนก่อน

    Hi bro, which IDE do you use?

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

      its vscode with some custom theme and edited over in premier pro