7 comments for “Tetris on a Raspberry Pi using the PiLite

  1. 25 November 2014 at 7:41 am

    Hi Michael,

    Thanks for the plug. Stephen’s the name.

    Guess I need a bio on the blog!

    Cheers,

    Stephen

    • recantha
      25 November 2014 at 7:43 am

      No worries – brilliant project 🙂 I shall update with your name!

  2. Steve
    30 November 2014 at 6:10 pm

    Thank you for publishing this, really works well 🙂
    Been looking for things to show off the Pilite and this does it very well.
    Steve

    • 30 November 2014 at 7:49 pm

      You’re very welcome, glad you enjoyed it!

      Stephen

  3. 23 May 2015 at 11:05 pm

    Hi – thanks for sharing the game! I`m a beginner in Python and now I try to figure out what each line does by messing around with the code. For example, I tried to make the game start again after it ends, but I couldn`t figure it out. Could you please tell me how to do that? Love your blog – greetings from Germany!

    • recantha
      25 May 2015 at 11:31 am

      Hello Germany! 🙂 I *think* you want to put the main game loop (129-225) inside a function. Then, call that function to start the game off. You then need to NOT call pygame.quit() and sys.exit() but instead have the function call itself again. Or, you have the initial function call inside a While True: loop. There’s a couple of different ways to do it. I haven’t got a PiLite myself to try it out otherwise I’d do it and show you. Let me know how you get on!

      • 25 May 2015 at 2:30 pm

        Hi guys,
        I’d advise against the function calling itself over and over again, because resources will be used on each call and never freed. Using ‘While True’ would definitely be better.
        Stephen

Leave a Reply

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