Skip to content
This repository was archived by the owner on Feb 8, 2025. It is now read-only.

Scripting: beginning

smokingplaya edited this page Jul 25, 2024 · 1 revision

As you may have already realized, JointJS adds a JavaScript interpreter to minecraft, thus allowing you to make it faster and easier to develop plugins. So let me explain to you how to start writing plugins in JointJS.

First step: install JointJS

The installation process for JointJS is exactly
the same as for other plugins for Spigot:
Download the jar file of the plugin from here
and drop it into the plugins folder in the root of your server.

Second step: set up dependencies

All right, when you have installed the plugin on
your server, you need to install bun.sh - it will
compile your TypeScript code. Then install npm. After installing npm, go to the root folder of your server,
then create and open folder with name joint-js
open a terminal and type the following command into it:

npm init

then run:

npm install @joint-js/modules

Third step: create a plugin

Go to the joint-js/plugins folder (create it if it doesn't exist)
in the root folder of your server.
Create a folder with the name of your plugin in it.
Inside the newly created folder, create the plugin.ts file.
plugin.ts is the entrypoint of your plugin.
In it you can write your code.

Clone this wiki locally