Algorithmics learning in games without secrets. Part 1. How to learn coding using apps on the interactive floor?

Is algorithmics interesting? Is it difficult? Does code development in the game take a lot of time?

Kodi is asking: - Where to go? What to do?

Kodi is asking: - Where to go? What to do?

With this post, I am starting a series of articles devoted to the issues of algorithmics and code formation by players in computer games. Today's article introduces us to the world of Motioncube games, in which we program the behaviour of the characters on the boards. During this journey, students learn to code independently and are introduced to smart programming concepts.

When we talk about algorithms in Motioncube games, we mean analyzing the situation on the board and designing the algorithm, i.e. the character's behaviour that will lead him to the finish line.

Board analysis and game strategy

At the beginning of the game, players are introduced to the tasks of the heroes on the board, for which they are to create an action plan in the form of a code with instructions.

Maze - Competitive mode in Kodi Challange Team

Maze - Competitive mode in Kodi Challange Team

Our games consist of sets of boards to be solved. When designing game boards, we take into account several factors:

  1. Length of the algorithm - how many steps it will be built of, is there a limit to its length?
  2. The number of different programming constructs that need to be used.
  3. Events on the board that need to be handled.
  4. The number of heroes for which you need to arrange sequences of commands.
  5. The principle of sharing or competing for resources on the board.

These aspects determine the degree of difficulty of the task. When you choose a game board, it is worth starting with the first one in a given thematic block. It is the easiest to solve, it helps to introduce the user to new issues, and it may contain partially arranged code with gaps to be filled.

Before you code...

  1. Analyze the board.
  2. Read the tips in the Help Centre.
  3. Set up a game strategy with your team or another player (in a cooperation mode).

A friendly way of coding - it matters!

No writing or scripting, juz arranging the pictures on the floor, table or tablet.

Friendly instructions - easy understanding

Friendly instructions - easy understanding

In games, we focused on a visual interface for arranging the code. It is widely used in well-known online games, e.g. CodeMonkey, and Scratch Junior. Here, the player composes the algorithm linearly, selecting the necessary picture blocks from the list at the bottom of the board, which express the commands for the character. The linear scheme is also used in the Scratch Junior solution. On the other hand, the complexity of algorithms that can be arranged with our blocks is comparable with the Scratch solution, which gives a lot of possibilities.

Game interface - Kodie and the Secret Castle

Game interface - Kodie and the Secret Castle

Advantages of the visual interface for coding:

  • accessible to people of different ages and degrees of initiation into programming,
  • makes it easier to remember the meaning of the instructions,
  • makes it easier to visualize the operation of the algorithm,
  • looks nice, and it is nice to look at!

Ready tasks to solve

The strength that should be emphasized in Motioncube games are the designed tasks to be solved, which are quite a lot - 422 boards in Kodi and the Secret Castle, and 120 boards in the Kodi Challenge Team. There is a lot to choose from, and this amount will provide students with many hours of pleasant and valuable entertainment.

In addition, we created characters to be interesting for game players, and the boards and their surroundings visually attractive. What's more, the gaming interface is adapted to high-definition projectors for interactive floors, and to work on an interactive whiteboard and a desktop computer with mouse or touchscreen operation.

Arrange the algorithm on the tablet - watch the execution on the floor or whiteboard

A technological novelty that we have introduced in the Kodi Challenge Team is the support for the game on tablets, on which players arrange codes and send them to the game on the host device - i.e. to the interactive floor or the computer. We can choose a board with a competitive mode or a two-player cooperative mode.

The player on the tablet chooses the hero for whom he will write the code - the order of submissions decides - Kodi Challenge Team

The player on the tablet chooses the hero for whom he will write the code - the order of submissions decides - Kodi Challenge Team

Learning programming while playing

While traversing the boards in Kodi and the Castle of Secrets, players have the opportunity to learn and apply basic programming constructs, such as:

  • a sequence of commands controlling the character on the board,
  • an iterative loop where the character performs several repetitions of the same commands,
  • a function with which the player defines a set of frequently used commands and then uses it in his main code, shortening its notation,
  • conditional statements- If the condition is true, execute the command; and If the condition is true, execute the command, otherwise execute another command,
  • a variable in which the player stores, for example, a number or item from the inventory, and which he will use in a function, loop or conditional expression.

In the Kodi Challenge Team, we use some of the above programming constructs. The board analysis aspect is paramount here, as a player's error results in the immediate defeat of the game unless both players have made a mistake in competitive mode.

The player will learn the above constructions gradually, and over time he will start combining them in one algorithm until he becomes proficient in nesting them, e.g. a loop within a loop, a conditional statement in a loop, a function with a conditional statement, etc.

What's more, both games, apart from the aspect of sequential programming - i.e. executing algorithms in sequence when there are more than one of them - introduce students to the topic of parallel programming, i.e. executing two or three algorithms simultaneously. We then observe the parallel movements of two or three characters on the board.

Motivation and fun - that is, we play to the fullest!

Each game is accompanied by emotions caused by, for example, the desire to win, the intention to hinder the rival, curiosity about the development of events or an attempt to face a task. When working in a team, there are issues related to communication in the group, coping with stress and responsibility for the team and self-decisions.

Cooperation mode - stress or fun? Two players, two tablets, one common board. Kodi Challenge Team

Cooperation mode - stress or fun? Two players, two tablets, one common board. Kodi Challenge Team


Helpful extras - worth using!

Both games are equipped with tutorials, thanks to which players get acquainted with the picture code notation at the start. For each board, they can familiarize themselves with the objective, type of quests and new elements in the game.

There are also sample solutions (!) for Kodi and the Secret Castle, which we send at the request of users.

I recommend trying both games on the interactive floor or on a computer (instructions are presented on the game's page in the store in the Try it out section). We have also prepared a demo version of Kodi and the Secret Castle for quick download to the computer to get familiarize users with the content and play several game levels - we will announce it on our website soon.

I hope that the topic of algorithmics in games will be friendly to You and even become the beginning of your coding adventure, to which you will invite your students.

With children and their good development in mind, we create games, sharing our passion and experience.

To be continued...

In the next article, I am going to introduce you to the programming language in our games, i.e. the picture blocks with which the player arranges a sequence of instructions for the characters on the board. Let's read soon!

Picture blocks

Picture blocks

Message the author at magda@motioncube.io

Useful links:

Kodi and the Secret Castle - game description

Kodi Challenge Team - game description

Interactive floor - a projection device description


MOTIONCUBE NEWS

☝ We will send to your inbox

The latest articles, class materials and news. You won't miss any promotions either!

Please accept our Privacy Policy.