Topic 3: Creating our First ScriptCraft Mods


(Notes updated September 2015.)

Previous Topic: Connecting to Each Other’s Servers.

Our First Mod: sayhi.js

I’ll show you how to write a very simple one, sayhi.js, and then a more complex one, scraper.js. After that, it’s up to you to figure out what you can do!

In the Canarymod folder, find the folder scriptcraft / plugins, then make a new folder with your name (or any unique folder name).

Using Notepad++, type in the code shown below and save it in a file called sayhi.js. Here are explanations of what everything means:


Try it out in Minecraft and see if it works!

NOTE: Every time you create a new ScriptCraft program or edit one, you have to type /js refresh() in Minecraft to update your changes. If no commands run, make sure you are opped. (In the Canarymod window, type op <your_mincraft_name>).

To run it, type /js sayhi() in Minecraft.

A More Complex Mod: scraper.js

This makes the skyscraper shown above. We will figure out together how it works!


4 thoughts on “Topic 3: Creating our First ScriptCraft Mods

  1. Pingback: ModderDojo Topic 1: Getting Started with ScriptCraft and JavaScript | CoderDojo Athenry

  2. Pingback: Topic 2: Connecting to Each Other’s Servers | CoderDojo Athenry

  3. Pingback: Minecraft Modding Taster Session – Week 1 | CoderDojo Athenry

  4. Pingback: ModderDojo Topic 4: Moving from Scratch to JavaScript | CoderDojo Athenry

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 )

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