“Convert” Python Game Star Pusher to Scratch Game and Solve Some Design Issues

In my previous post, I mentioned that I "converted" a Python game made from PyGame module into Scratch project. In this post, I will introduce some key design issues when "converting" it to Scratch project. After all, there is not any convenient magic conversion. However, if we read through the Python code and utilize its …

Continue reading “Convert” Python Game Star Pusher to Scratch Game and Solve Some Design Issues

Where Do I Find Game Ideas for Scratch and Python Game Development?

Game development is an important method to help learning a programming language, no matter it is learning Scratch, Python or Javascript. When I am developming code lessons, sometimes I am facing the problem of running out of game ideas, here are a few channels I use to ignite my ideas: Note: all the recommendation here …

Continue reading Where Do I Find Game Ideas for Scratch and Python Game Development?

Use PyInstaller to Create Executable of Python PgZero Game – Windows Version

If you develop a game with Pgzero or PyGame, you might want to invite your friends to play it. However, some of your friends do not use Python, so they do not have the Python development environment, or you do not want to share your Pgzero code at that moment. How do you wrap your …

Continue reading Use PyInstaller to Create Executable of Python PgZero Game – Windows Version

Code Structure Change When Converting Blockly Language into Pyton Code for LEGO MindStorms

When we start to write Python code for LEGO MindStorms models, we tend to convert existing Scratch blockly code into Python version and check if it works. Although LEGO has made effort to create Python methods which could match the functionality of Scratch programming blocks, the Python code structure is much different from that of …

Continue reading Code Structure Change When Converting Blockly Language into Pyton Code for LEGO MindStorms

Use LEGO MindStorms Inventor to Create a Rolling Pattern – With Python

As we know, LEGO MindStorms Inventor provides animation functionality. In the Animation Editor, we could specify the light matrix pattern, then call the "play animation" block to play it. However, how about we want a pattern rolling freely on the light matrix? just like what the below video shows. We could not use the built-in …

Continue reading Use LEGO MindStorms Inventor to Create a Rolling Pattern – With Python

How to Store and Run Multiple Programs on LEGO MindStorms Inventor or Spike

If you have a LEGO MindStorms Inventor or Spike Prime set, you might wonder how to store multiple programs to the smart hub and then switch to the program you want to run. In this post, I will demonstrate how to download and store multiple programs. Now I have a project called "pet dog", as …

Continue reading How to Store and Run Multiple Programs on LEGO MindStorms Inventor or Spike

Use LEGO MindStorms Inventor to Build a Pet Dog – Code it with Both Blockly Language and Python – Part Two

In the previous post, I introduced how to use blockly language to control LEGO MindStorms Inventor, and write code for the pet dog. As I have already mentioned, we could accomplish the similar functionalities by using Python. In today's post, we will use the Python editor of LEGO MindStorms Inventor App to implement the same …

Continue reading Use LEGO MindStorms Inventor to Build a Pet Dog – Code it with Both Blockly Language and Python – Part Two

For Those Who Could Not Run MakeCode for Maqueen Plus 2.0, here is the Solution

If you bought the Maqueen Plus 2.0 recently, you might meet the same issue which I encountered. I spent several hours trying to make it work, but it seemed the motors were not working properly at all. The program could not control either the movement direction and speed of the motors. The most possible reason …

Continue reading For Those Who Could Not Run MakeCode for Maqueen Plus 2.0, here is the Solution

Use LEGO MindStorms Inventor to Build a Pet Dog – Code it with Both Blockly Language and Python – Part One

If you once played the LEGO MindStorms EV3, you might have built one of its sample projects Puppy, which I explained in my previous posts. Several years ago, when EV3 has not yet supported the Scratch blockly language, the puppy code is pretty complicated and confusing. In this post, I will use LEGO MindStorms Inventor …

Continue reading Use LEGO MindStorms Inventor to Build a Pet Dog – Code it with Both Blockly Language and Python – Part One

Create a Dodge Game on Micro:bit by Using Python

In my previous post, I introduced how to create a dodge game on the smart hub of LEGO MindStorms by using MicroPython. In this post, I would like to introduce how to write a Python version of dodge game on micro:bit by using its new Python Editor (beta version). The final effect could be like …

Continue reading Create a Dodge Game on Micro:bit by Using Python