To get started run:
# Replace `<YOUR TRAILMAKERS MODS DIRECTORY>` with the
# actual directory to your Trailmakers mods folder.
cd "<YOUR TRAILMAKERS MODS DIRECTORY>"
# Feel free to change `my-trailmakers-project`
# to your desired project name here
npx degit spidunno/trailmakers-scaffolding "my-trailmakers-project"
# and here
cd "my-trailmakers-project"
Install dependencies with yarn/npm/bun:
npm install
Edit the src/main.ts
file and build your project with:
npm run build
To watch for file changes and automatically re-build:
npm run watch
Copy the generated main.lua
as well as the data_static
folder into another folder and upload as usual. I might make a script that automatically does everything needed to prepare your mod to be uploaded later.