Making your First Script
Making your own script is super easy. Here is the classic "Hello, world" to help you get started.
function newLevel() {
clientMessage("Hello, world!");
}
Note the function definition. newLevel is a hook. It is called by BlockLauncher when something happens. In this instance, newLevel means, call this function when we enter a new level.
You can test this by applying the script, then entering a world. "Hello, world!" shall appear.
Also note that clientMessage hasn't been defined. This is a function provided by BlockLauncher that prints something to chat.