HyperScript
HyperScript is a lightweight scripting language for Paper and Spigot servers. Instead of writing a Java plugin for every idea, you write a few lines in a .hs text file. Save the file and it is live: no compiling, no restart.
What a script looks like
command /daily:
cooldown: 1 day
trigger:
give 3 diamond to player
add 1 to {%player%.claims}
send title "&6Daily reward!" with subtitle "&eClaim #%{%player%.claims}%" to player
on player join:
send "&aWelcome back, %player.name%!"
That is a complete script: a command with a per-player cooldown, an item reward, a counter saved for each player, and a join message.
Features
Commands and events
- Custom commands with permissions, aliases, cooldowns and usage text
- Events for joins, chat, block breaks, damage, jumps, mob spawns, inventory clicks, server list pings and more
- Timers (
every 5 minutes:), delays (wait 3 seconds), if/else, and loop, for each and while loops
Data that saves itself
- Local, global and per-player variables, stored automatically
- Numbers, text, lists, items, durations and locations
- JSON storage out of the box, with optional MySQL or SQLite, automatic fallback and scheduled backups
What players see
- Chest GUIs with clickable slots
- Titles, action bars, boss bars and per-player sidebar scoreboards
- Tab list header and footer, join and quit messages, chat format
- Server list MOTD, player counts and icon
World and effects
- Give custom items with names and lore, summon mobs, set blocks, teleport
- Sounds, particles, particle shapes, floating text and block displays
- Box regions you can test locations against
Connections
- Web requests with JSON reading
- Discord webhooks and slash commands
- Text files inside the plugin folder
Made for editing live
- Scripts reload when you save them
- Mistakes are reported with the file and line when a script loads, in the console and to whoever reloaded
- One broken script never stops the others
/hs disable <file> and /hs enable <file> to switch scripts off and on
Getting started
- Put the jar in your server's
plugins folder and start the server.
- Open
plugins/HyperScript/scripts/ and create a file ending in .hs.
- Save it. The console tells you what was loaded.
An example script, demo.hs, is installed on first start. It is live straight away and adds several commands, so delete or disable it on a production server.
Compatibility
- Minecraft: 1.16.5 to 26.x (estimated)
- Servers: Paper and Spigot
- Java: 8 or newer
A few features need newer versions or Paper: display entities need 1.19.4+, and changing the online count shown in the server list needs Paper.
Status
HyperScript is in active development and has not had a public release before. Syntax may still change between versions, and the changelog lists what changed each time.
Licence
MIT