File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed
Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change 2929$ startTimeVar = "RaceStartTime " ;
3030// Name of the RequireContext condition for the script to run in-game
3131$ RequiredContext = "CTmMlScriptIngame " ;
32+ // Additional script included for ShootMania, concerning Obstacle to prevent jumps from cp to cp
33+ $ scriptSMObstaclePreventJump = "" ;
3234if ($ ShootManiaCall == true ) {
3335 $ startTimeVar = "StartTime " ;
3436 $ RequiredContext = "CSmMlScriptIngame " ;
37+ $ scriptSMObstaclePreventJump = '
38+ // Little check SM Obstacle specific to avoid any CP jump during a quest
39+ if (LoadedTitle.TitleId == "obstacle@smokegun") {
40+ declare LocalPlayer <=> InputPlayer;
41+ declare netread Net_UsedJump for LocalPlayer = False;
42+ if (Net_UsedJump) {
43+ if (DebugMode) log("Jump used. Quest cancelled.");
44+ clearPersistentData();
45+ return;
46+ }
47+ }
48+ ' ;
3549}
3650// URL used in the few requests done in the script (to get the board, the tokens and register a completed quest)
3751$ urlToRequest = ($ _SERVER ['HTTPS ' ] == "on " ) ? "https:// " : "http:// " ;
489503 return;
490504 }
491505
506+ ' .$ scriptSMObstaclePreventJump .'
507+
492508 declare Text RemoveToken = " ' .htmlentities ($ Token , ENT_XML1 ).'";
493509 // We set the right token state as collected (True)
494510 for(i,0,Pe_LocalTokensIds[G_QuestId].count-1)
You can’t perform that action at this time.
0 commit comments