File tree 2 files changed +8
-5
lines changed
2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -1901,7 +1901,7 @@ class PlayState extends MusicBeatState
1901
1901
}
1902
1902
1903
1903
if (generatedMusic ) {
1904
- Scripting .runModchartUpdateOnScripts ();
1904
+ Scripting .runModchartUpdateOnScripts (" modchartUpdate " );
1905
1905
var speed = (0.45 * FlxMath .roundDecimal (scrollSpeed , 3 ));
1906
1906
if (Options .instance .downScroll )
1907
1907
speed = 0 - speed ;
@@ -1989,6 +1989,7 @@ class PlayState extends MusicBeatState
1989
1989
break ;
1990
1990
}
1991
1991
}
1992
+ Scripting .runModchartUpdateOnScripts (" modchartPostUpdate" );
1992
1993
}
1993
1994
1994
1995
if (camIsFollowing ) {
Original file line number Diff line number Diff line change @@ -207,11 +207,11 @@ class Scripting {
207
207
}
208
208
}
209
209
210
- public static function runModchartUpdateOnScripts () {
210
+ public static function runModchartUpdateOnScripts (name : String ) {
211
211
if (! Options .instance .modchartEnabled )
212
212
return ;
213
213
for (script in scripts ) {
214
- script .runValidFunction (" modchartUpdate " , [FlxG .elapsed ]);
214
+ script .runValidFunction (name , [FlxG .elapsed ]);
215
215
}
216
216
}
217
217
@@ -279,6 +279,7 @@ class Scripting {
279
279
" update" ,
280
280
" updatePost" ,
281
281
" modchartUpdate" ,
282
+ " modchartPostUpdate" ,
282
283
" destroy" ,
283
284
" beatHit" ,
284
285
" stageInit" ,
@@ -291,6 +292,7 @@ class Scripting {
291
292
" noteMiss" ,
292
293
" goodNoteHit" ,
293
294
" charNoteHit" ,
295
+ " opponentNoteHit" ,
294
296
" preCreateMenuButtons" ,
295
297
" checkUnlocks" ,
296
298
" titleText" ,
@@ -328,9 +330,9 @@ class Scripting {
328
330
return Reflect .isFunction (interp .variables .get (funcName )) ? Reflect .callMethod (this , interp .variables .get (funcName ), args ) : null ;
329
331
}
330
332
331
- public inline function runModchartUpdate () {
333
+ public inline function runModchartUpdate (name : String ) {
332
334
if (Options .instance .modchartEnabled )
333
- runValidFunction (" modchartUpdate " , [FlxG .elapsed ]);
335
+ runValidFunction (name , [FlxG .elapsed ]);
334
336
}
335
337
336
338
/* public inline function runStatePostInit(arr:Array<String>) {
You can’t perform that action at this time.
0 commit comments