Blogs


Learn Scratch by Analyzing Others’ Project – Platformer Game with Editing Functionality Part 4

In the previous posts, I introduced the core sprite of the Blocky game, the “Blocks” sprite, which is responsible for adding, deleting or editing the environment blocks. Starting from this post, we are going to switch to the other core sprite – Hitbox. Homescreen UI Sprite Before introducing the code of Hitbox sprite, I would …

Continue reading Learn Scratch by Analyzing Others’ Project – Platformer Game with Editing Functionality Part 4

Python Programming: Use Turtle Library to Realize Animation

In the previous post, I use Scratch 3.0 to create animation with Pen functionality. Could we do the same thing using Python? Definitely Yes. We could use Turtle library to generate the same effect, but with more concise code structure. In this post, Let me introduce how to implement it. If you would like to …

Continue reading Python Programming: Use Turtle Library to Realize Animation

Learn Scratch by Analyzing Others’ Project – Platformer Game with Editing Functionality Part 3

In the previous post, I introduced part of the Stamp block. As I have said, this is a very long code segment and its functionality could be divided into three parts. In the previous Part 2 analysis, I analysed the first functionality – drawing the blocks on the stage. In this post, I will continue …

Continue reading Learn Scratch by Analyzing Others’ Project – Platformer Game with Editing Functionality Part 3

Learn Scratch by Analyzing Others’ Project – Platformer Game with Editing Functionality Part 2

In Part 1 of this project, I introduced how this game realized some stylish visual effects, how to encode its data and store the data in a file, and how to import the data from a file by decoding its data and filling in several lists. In this post, I would like to explain how …

Continue reading Learn Scratch by Analyzing Others’ Project – Platformer Game with Editing Functionality Part 2

Learn Scratch by Analyzing Others’ Project – Platformer Game with Editing Functionality Part 1

In previous post, I summarized the key points of platformer game tutorial video uploaded by well known Youtuber. However, some platformer games could even go further. They could allow user to define the ground, obstacles, checkpoints and then save their level setting information to their computer. When the user plays the game, they could start …

Continue reading Learn Scratch by Analyzing Others’ Project – Platformer Game with Editing Functionality Part 1

Analyze Python Project – Integrate Tkinter and Turtle and Respond to Mouse and Keypress

In previous posts, I introduced some sample projects from Pygame installation folder. Besides Pygame, Turtle and Tkinter modules are also popular for Python learning beginners. Tkinter package is a standard Python interface to Tk GUI toolkit. It could design window and different widgets, such as button, textbox, label, canvas and handle the interaction with user …

Continue reading Analyze Python Project – Integrate Tkinter and Turtle and Respond to Mouse and Keypress

Analyze PyGame Example Project – Music_drop_fade.py – Part 2

In the previous post, I introduced the first part of the project Music_drop_fade.py. It defines functions that would be called by main() function. In this post, I will introduce the main() function and wrap up the whole project. So let’s start now! The main() function starts at line 148. It first defines several global variables …

Continue reading Analyze PyGame Example Project – Music_drop_fade.py – Part 2

Analyze PyGame Example Project – Music_drop_fade.py – Part 1

In this post, I would like to analyze another Python sample project. Its function is to play the music file when dragging and dropping them to the project window. The program could also respond to different keys to change volume, play forward or rewind. Those functions have being listed at the header section of the …

Continue reading Analyze PyGame Example Project – Music_drop_fade.py – Part 1

Design Puzzle Game “Eight Queens” with PyGame – A Detailed Code Analysis

In previous post, I introduced how to use PyGame to convert a Scratch project into a Python project. If you are interested in that project, you could refer to this post: Forest Maze. In today’s post, I would like to introduce another project written in Python and run on PyGame. Compared to previous project, this …

Continue reading Design Puzzle Game “Eight Queens” with PyGame – A Detailed Code Analysis

New LEGO MindStorms – Exploration Rover Model Analysis

In the new released LEGO MindStorms, its app contains multiple models. Some models come from LEGO Community. In today’s post, let’s build one model and analyze its structure. You could find this model from LEGO app shown as below. Model Structure This model is pretty big and heavy. Its body is widely stretched and symmetric. …

Continue reading New LEGO MindStorms – Exploration Rover Model Analysis

Learn Scratch 3.0 by Analyzing Project – Melting Line Puzzle Game Part 2

In the last post, I analyzed those UI related sprite of the Melting Line puzzle game. In this post, I would like to introduce the list structure and how to judge pass/fail condition of the game. All of these functions are implemented by Algorithm Sprite. Algorithm Sprite “when I receive start a level” Code Segment …

Continue reading Learn Scratch 3.0 by Analyzing Project – Melting Line Puzzle Game Part 2

Learn Scratch 3.0 by Analyzing Project – Melting Line Puzzle Game Part 1

In the previous posts, I analyzed many puzzle projects, such as Gliding Puzzle, Game 2048, Tetris, etc. There is much difference between puzzle game and other popular Scratch games. Puzzle games usually have static background and focus less on sprite’s costume and actions. Therefore, some players might feel that puzzle games are not so shiny. …

Continue reading Learn Scratch 3.0 by Analyzing Project – Melting Line Puzzle Game Part 1

The Video Sensing Could not Work in Scratch 3.0? – Allow Scratch to Visit Webcam First

If you are using Video Sensing to make interactive game in Scratch 3.0, you might meet the issue that the camera seems not being able to be turned on. Recently, I met this issue. I searched Scratch discussion forum and noticed someone had reported the same problem but no answer was given in the post, …

Continue reading The Video Sensing Could not Work in Scratch 3.0? – Allow Scratch to Visit Webcam First

LEGO Spike Prime – Explanation of Accelerometer Data and Line Graph Analysis

In the App of LEGO Spike Prime, there is an advanced unit category which creates different devices, logs and analyzes gyroscope or accelerometer data. In today’s post, I will use the same model of “Build a Smart Kettlebell” project and introduce how to read and analyze the recorded accelerometer data. I will also update the …

Continue reading LEGO Spike Prime – Explanation of Accelerometer Data and Line Graph Analysis

LEGO Spike Prime – Use PID to Control A Self-balancing Robot and Some Key Points

On YouTube, I just accidentally found a video introducing a self-balanced robot controlled with PID. That is really amazing. However, when I tried to build the model and copied its code, I met some problems. It seems not as easy to get the robot keeping balanced as shown in the video. In this post, I …

Continue reading LEGO Spike Prime – Use PID to Control A Self-balancing Robot and Some Key Points

Which New Model to Choose From – LEGO Spike Prime or LEGO MindStorms Inventor?

In August of 2020, LEGO released a new version of LEGO MindStorms called LEGO MindStorms Inventor, which is released just a few months after the release of LEGO Spike Prime. So what is the difference between MindStorms Inventor and Spike Prime? Does that mean I have to upgrade my LEGO Spike Prime in order to …

Continue reading Which New Model to Choose From – LEGO Spike Prime or LEGO MindStorms Inventor?

Play LEGO Spike Prime – Upgrade Demo Project Security Box – Python Code

In my previous post, I introduced how to upgrade the model and programming blocks of the demo project – Security Box. In this post, I would “translate” the programming blocks into Python code. I would say it is an efficient way to get familiar with LEGO Spike Python module and improve your Python coding skills. …

Continue reading Play LEGO Spike Prime – Upgrade Demo Project Security Box – Python Code

Play LEGO Spike Prime – Upgrade Demo Project Security Box

In the building plans of LEGO Spike Prime software, we could find the building specification of a security box. When Left button is pressed, the box could be unlocked. However, if we want to design a more high-tech security box, simple lock/unlock functionality is not enough. On YouTube, we could find videos on how to …

Continue reading Play LEGO Spike Prime – Upgrade Demo Project Security Box

Use Scratch 3.0 to Make Scrolling Platformer Game – Part 4, Convert to Static Platformer Game

In my previous posts, I explained some key issues when developing a scrolling platformer game by following YouTube tutorial video clips. So how about designing a static platformer game? Static and scrolling platformer game have different characteristics, however, if you have developed a scrolling platformer game, it is pretty easy to convert the code of …

Continue reading Use Scratch 3.0 to Make Scrolling Platformer Game – Part 4, Convert to Static Platformer Game

Use Scratch 3.0 to Make Scrolling Platformer Game – Part 3 – Add Costumes to Your Player

In my previous posts, I summarized some key points when following Griffpatch’s online tutorial to design a scrolling platformer game. However, the Player in video clips is still of a rectangle shape, without any costume change. In many games, Player is a figure which has different poses of running, jumping or falling. How to add …

Continue reading Use Scratch 3.0 to Make Scrolling Platformer Game – Part 3 – Add Costumes to Your Player

Use Scratch 3.0 to Make Scrolling Platformer Game – Key Point Summary Part 2

In the previous post, I explained some confusing points in Griffpatch’s Scrolling Platformer Tutorial Part 1 to Part 5. I will continue explaining some key points in video clips of Part 6 to 10 in this post. If you have watched the video clips of Part 1 to Part 5, you might have understood the …

Continue reading Use Scratch 3.0 to Make Scrolling Platformer Game – Key Point Summary Part 2

Use Scratch 3.0 to Make Scrolling Platformer Game – Key Point Summary Part 1

On YouTube, we could always find some excellent and free resources. Like the following one made by Griffpatch, who taught how to design a platformer game on Scratch. The full tutorial contains 10 episodes and I strongly recommend you to follow them step by step. If you keep patient, you could design an amazing scrolling …

Continue reading Use Scratch 3.0 to Make Scrolling Platformer Game – Key Point Summary Part 1

Use Scratch 3.0 to Make Multiple Player Game – Some Key Points

On Scratch 3.0, you might notice there is one type of variable: cloud variable. This option is available in Create Variable dialog. However, if you are a “New Scratcher”, you will not see this option. So what is the purpose of using cloud variables? Usually we could store highest game score, the user name who …

Continue reading Use Scratch 3.0 to Make Multiple Player Game – Some Key Points

LEGO Spike Prime – “Translate” Programming Blocks into Python Code

In my previous post, I introduced how to set a mission for LEGO Spike Prime and implement the task with LEGO Spike programming blocks. As I mentioned before, Lego Spike Prime supports MicroPython pretty well. Most of the programming blocks could find corresponding Python functions. In this post, I will demonstrate how to “translate” my …

Continue reading LEGO Spike Prime – “Translate” Programming Blocks into Python Code

Play LEGO Spike Prime at Home – Another Mission for Your Robot Vehicle – Part 2

This is the second part of LEGO Spike Prime mission and focuses on the introduction of mechanical structure. If you would like to check how to use program to control your robot, you could refer to my previous post. Top View The following is the top view of the robot vehicle. Since the model needs …

Continue reading Play LEGO Spike Prime at Home – Another Mission for Your Robot Vehicle – Part 2


Follow Our Future Articles

Get new content delivered directly to your inbox.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.