-
Notifications
You must be signed in to change notification settings - Fork 23
Scripting
Cannot Be Used In Menus Or States.
Lua Modcharts Cannot Be Used With Modcore. The Game Scans Using FileSystem Instead Of OpenFlAssets. This Means That The Game Cannot Detect Modcharts Using Modcore.
The Game Will Scan A Chart Folder And See If It Contains A .hx File. It Shouldn't Matter What The Script Is Named (i.e : test.hx, script.hx).
If You Want To Have A Script On Every Song, You Can Put A Script In Assets/Shared/Data/Scripts
.
You Cannot Use Scripts In Other States. No MainMenuState. No FreeplayState. No Nothing.
Functions. You Need Them. In Your Script, You Need These 4 Functions As A Base.
function create()
{
}
function update()
{
}
function beatHit()
{
}
function stepHit()
{
}
These Functions Will Be Executed Depending On The Function (i.e : update will update every frame. stepHit will update every step. etc.).
A Neat Function To Call Whenever Debugging Is
Debug.logTrace();
. The Trace Will Appear In The Logs Folder In The Current Log.
Note : There Are Other Functions That Exist Too.
create
createPost
update(elasped)
stepHit(curStep)
beatHit(curBeat)
sectionHit(curSection)
countdown
countTick(3,2,1)
ghostTap(what key was pressed)
startSong
notesUpdate
noteMiss(note)
updateAccuracy
opponentNoteHit(note)
goodNoteHit(note)
playerOneTurn
playerTwoTurn
bpm
step
mustHitSection
PlayState
game
health
camGame
camHUD
camFollow
camZoom
boyfriend
dad
gf
notes
strumLineNotes
unspawnNotes
Some Of These May Be Broken. You Can Also Get Variables / Call Functions From PlayState That Aren't Listed By Doing game.FUNCTION
Or game.VARIABLE