見出し画像

Minecraft: Education Editionでのプログラミングを大人の人に興味を持ってもらう#1(New Professional Development pathway to engage Adult Learners for "Minecraft Education Edition MakeCode Programming" #1)

教育版マインクラフトとは

世界で最も売れているゲーム。それがマインクラフト。そのマインクラフトには教育用にカスタマイズされたマインクラフトが存在する。それが教育版マインクラフト(Minecraft: Education Edition)である。

What is Minecraft: Education Edition?

Minecraft is the best-selling game in the world. Minecraft has a Minecraft customized for educational use. It is Minecraft: Education Edition.

MakeCodeプログラミング

教育版マインクラフト内蔵コードビルダー

教育版マインクラフトにはMakeCodeと呼ばれるプログラミング環境が内蔵されている。
統合版マインクラフトでもMakeCodeは使用することができるが、Code Connection for Minecraftという外部プログラムによって実現されているためウィンドウ切替がやや煩雑な環境となっている。

ここが教育版マインクラフトの差別化ポイントの1つと言っていいだろう。

MakeCode Programming
M:EE has a built-in programming environment called MakeCode. MakeCode can also be used in Minecraft BedRock Edition, but the environment is realized by an external program called Code Connection for Minecraft, which makes window switching somewhat complicated.

This is one of the points of differentiation of M:EE.

※なお、執筆時点の統合版最新バージョンではWebSocketプロトコルの仕様変更があったためCode Connection for Minecraftが動作しなくなっている。
*Note that Code Connection for Minecraft no longer works with the latest version of the integrated version at the time of writing due to a change in the WebSocket protocol specification.

MakeCodeのオリジナルブロックをつくる

2022年6月にマインクラフトMakeCodeのオリジナルブロックをつくるというワークショップをマイクロソフト認定教育イノベーターの教員向けに開催してみたのでその記録をお伝えする。

Create your own MakeCode block
I would like to share with you a recording of a workshop I held on Teams in June 2022 for MIE Experts teachers on how to make original blocks for Minecraft MakeCode.

※現在、最新版の教育版マインクラフトはこのための機能がバグにより使用できない状況となっているが、公式サポートチームにはフィードバック済みで修正される予定である。
筆者は
マインクラフトグローバルメンターとして活動しており、βテストにも参加してフィードバック活動を実施している
*Currently, the latest version of M:EE is not usable for this purpose due to a bug, but the official support team has been fed back and will be fixed. I am active as a Minecraft Global Mentor and have been participating in beta testing and conducting feedback activities

基本的にはJavaScriptプログラミングの経験が無い方を対象にこのワークショップを実施したのだが、想定していた以上にこの内容に興味を持っていただくことができた。
大人の方がMakeCodeのオリジナルブロックをつくることを通じてプログラミングそのものの関心を高めるきっかけとなることを期待している。
Although this workshop was basically designed for people who have no experience with JavaScript programming, we were able to attract more interest in the content than we had expected. We hope that adults will become more interested in programming itself through creating their own original MakeCode blocks.

今回のテーマ「ロケット花火連射ブロック」

まず、以下のようなロケット花火連射をするブロックコードを作成するところから始める。

This time's theme: "Rocket Fireworks Sequential Firing Block."

The first step is to create a block code to shoot rocket fireworks continuously as shown below.

MakeCodeブロックモード

チャットコマンド"r"を入力すると、その中にあるコードが実行される。ロケット花火を自分の足元から5回発射するという処理が実行される。

JavaScriptのコードを書いたことが無くても、MakeCodeのブロックモードであれば上記のように容易に記述することができる。

そして、MakeCodeコードビルダーの特徴として、ブロックで作成されたプログラムをJavaScriptやPythonに変換する機能がついている。下図のボタンがあるのでJavaScriptボタンをクリックすることで切り替えてくれるのだ。

When you enter the "r" chat command, the code in it is executed. The code
executes the process of firing rocket fireworks five times from the foot of the user.

Even if you have never written JavaScript code before, MakeCode's block mode makes it easy to write code like the above.

MakeCode Code Builder also features a function to convert programs created in block mode into JavaScript or Python. There is a button shown in the figure below, and by clicking the JavaScript button, you can switch between the two.

ブロック-JavaScript切替ボタン

先程のブロックコードをJavaScriptに切り替えることで以下のようなコードが表示される。
By switching the block code from the previous section to JavaScript, the following code is displayed.

JavaScriptモード

ここで、念のためコードの解説を実施した。元のブロックとJavaScriptの記述にどれくらいの違いがあるのかを知る機会とするため、あまり深掘りせずコードの意味の読み解きをするだけに留めておいた。
Here, we conducted an explanation of the code, just to be sure. In order to provide an opportunity to see how much difference there is between the original block and the JavaScript description, we did not delve too deeply into the code, but only read and decipher the meaning of the code.

ここで、ロケット花火の連射を行うコードは上記コードの中2ー4行目になるのでこれをメモ帳などにコピー&ペーストしておいてもらう。

次回(#2)は、いよいよカスタムブロック作成部分を解説する。

The code for firing a series of rocket fireworks is lines 2-4 of the above code, so please copy and paste this code into a notepad or the like.

In the next issue (#2), we will finally explain the custom block creation part.

MakeCodeのプログラミング画面


この記事が気に入ったらサポートをしてみませんか?