DX MODDING GUIDE
  • Welcome to the DX Modding Guide!
  • File Structure
    • Folder Structure
    • Mod File
    • Metadata
  • Lua API
    • Working with GML
    • Callbacks
    • Assets
      • Sprites
      • Sounds
      • Fonts
    • Properties
    • Modcharts
    • FNFFD Functions
  • basic tutorials
    • Custom Songs
    • Example Mods
Powered by GitBook
On this page
  • Start/End
  • onCreate()
  • onCreatePost()
  • onSongEnd()
  • Events
  • onStep()
  • onDraw()
  • onDrawGUI()
  • onBombNote(note: Int)
  • onEventNote(event: Int)
  • onBadguyNote(note: Int, type: Int)
  • onPlayerNote(note: Int, type: Int)
  • onNoteMiss(note: Int, type: Int)
  • COMPATIBILITY CALLBACKS
  • onStageLoad()
  • onStageDraw()
  • customChar()
  1. Lua API

Callbacks

callbacks are functions that get called whenever something happens ingame EXAMPLE

function onStep()
      show_message(“hello!!”) -- super annoying popup >:(
end

Start/End

onCreate()

triggers as soon as lua is finished initialising (dont set song variables in this one! they wont apply)

onCreatePost()

triggers after obj_song is created

onSongEnd()

triggers whenever the song ends

Events

onStep()

triggers every step event

onDraw()

triggers every draw event

onDrawGUI()

triggers every draw gui event

onBombNote(note: Int)

triggers when a bomb note is hit

onEventNote(event: Int)

triggers when an event note is hit

onBadguyNote(note: Int, type: Int)

triggers whenever a note is pressed by the opponent

onPlayerNote(note: Int, type: Int)

triggers whenever a note is pressed by the player

onNoteMiss(note: Int, type: Int)

triggers whenever a note is missed

COMPATIBILITY CALLBACKS

i dont recommend you use these because the names dont really make sense!!

onStageLoad()

same as onCreatePost()

onStageDraw()

same as onDraw()

customChar()

legacy function from when character.lua was required!! just use onCreate lmao

PreviousWorking with GMLNextAssets

Last updated 5 months ago