Skip to content

Lua Script API

Meme1079 edited this page Jul 24, 2023 · 14 revisions

Running a script

They're six types of LUA Scripts you can run:

  1. Stage Script - It will only run if the song's stage has been set to the same as its name, it should have the same name as your stages json file and should be located inside mods/stages/ folder.
  2. NoteType Script - It will only run if the said Note Type is being used on the chart, it should be located inside mods/custom_notetypes/ folder.
  3. Event Script - It will only run if the said Event is being used on the chart, it should be located inside mods/custom_events/ folder.
  4. Song Script - They should be saved inside the songs chart folder, it will only run on this specific song, no matter the difficulty, stage or whatever else.
  5. Character Script - It will only be run if the specified character is used on the current song. You can use variables dadName, boyfriendName and gfName.
  6. Global Script - It should be saved in mods/Your-Mod-Name/scripts/ folder, it will run in all songs/difficulties, with no exceptions.

MOD FOLDER TEMPLATE

Example Scripts

Basic

Advanced

Clone this wiki locally