Simple Pong Clone in Pygame

  • Howdy. Over the weekend, I created a pong clone. It is super simple, 2-player only, and commented like crazy.

    Here’s the file:

    2 thoughts on “Simple Pong Clone in Pygame

    1. Christopher

      i was having some fun and got the ball to follow a consistent path repetitiously. it took only sixteen volleys t break the program. i had the ball continue to gain velocity until it stopped drawing and froze. you were right when you said simple. it would be fun to see the ways in which different people would handle this bug. ill try something and send you an email.

      1. Christopher

        very simple fix as well. the trick i used was to create variable called “volley_counter = 0 ”
        when the variable “volleys” is reset to zero after every third volley, it now adds three to the value of “volley_counter”. the next step is simple to add the condition for which the “volley_counter” can allow only for a maximum “frame_timer” reduction. i chose make this value equal to 15. so now the game can only accelerate up to five times. The commenting you threw in is extremely helpful, thanks !!


    Leave a Reply

    Your email address will not be published. Required fields are marked *

    × six = 6