ScratchMC – make the drone visible

This post is a follow up of the post about Using Scratch with Minecraft.

Playing with Scratch commands to build various things in Minecraft, I “lost” the drone many times when going from one function to another, making it difficult to know the exact position of where the new building will start. I also wanted to be able to follow the progress of each building in Minecraft client without being forced to move the mouse to the expected position of the drone.

To follow the drone I created the turn function (based on teleport) that makes the player look to the desired direction – either to a specific point or to  the drone. I also wanted to make the drone visible. First try was done in Scratch.

The Show drone function makes the block at drone’s position flash 3 times by replacing it with a skeleton skull that has the same orientation as the drone.

The visual effect is quite nice, but it can make undesired changes. In the video you can see how temporarily replacing a dirt block removes the grass on it. The result will be worse when changing a chest: its contents would be lost. The effect is also visible only when the block at the drone position is visible itself to the player.

So I decided to create an entity at drone’s position that can be seen thru opaque blocks. The easiest way was to apply glowing potion effect to this “ghost” (which in fact is an armor stand). The potion effect has the advantage to disappear after the specified amount of time, so there is no need to remove it explicitly in code after a while.

To show how it works I created a Scratch project with a basic pixel editor for 8×8 or 16×16 images that can be then created in Minecraft using one of the colored materials (wool, glass or hardened clay).

The drone movement is easy to follow and usually is synced with building operations for small cuboids, although in this video the server lags at the beginning (because I have on the same machine the MC server + client, Scratch and QTime for video capture). When using instructions to build bigger cuboids or more complex structure it would be a good idea to insert delays between them (using Scratch wait block).

The next step would be to make the ghost change the orientation when using drone turn command, but I wasn’t yet able to set the rotation of the armor stand, so I’m still searching for a solution.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your 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