diff --git a/.vscode/settings.json b/.vscode/settings.json
index d7433698d..dd4cd7aef 100644
--- a/.vscode/settings.json
+++ b/.vscode/settings.json
@@ -1,84 +1,120 @@
{
- "[haxe]": {
- // Automatically keep Haxe files formatted.
- "editor.formatOnSave": true,
- "editor.formatOnPaste": true,
- "editor.codeActionsOnSave": {
- // Compilation server issues can cause auto-cleanup to remove valid imports.
- "source.organizeImports": false
- },
- "editor.defaultFormatter": "nadako.vshaxe",
- "editor.tabSize": 2
+ "[haxe]": {
+ // Automatically keep Haxe files formatted.
+ "editor.formatOnSave": true,
+ "editor.formatOnPaste": true,
+ "editor.codeActionsOnSave": {
+ // Compilation server issues can cause auto-cleanup to remove valid imports.
+ "source.organizeImports": false
},
-
- "[json]": {
- // Automatically keep JSON files formatted.
- "editor.formatOnSave": true,
- "editor.formatOnPaste": true,
- "editor.defaultFormatter": "esbenp.prettier-vscode"
+ "editor.defaultFormatter": "nadako.vshaxe",
+ "editor.tabSize": 2
+ },
+
+ "[json]": {
+ // Automatically keep JSON files formatted.
+ "editor.formatOnSave": true,
+ "editor.formatOnPaste": true,
+ "editor.defaultFormatter": "esbenp.prettier-vscode"
+ },
+
+ "[jsonc]": {
+ // Automatically keep JSONC files formatted.
+ "editor.formatOnSave": true,
+ "editor.formatOnPaste": true,
+ "editor.defaultFormatter": "esbenp.prettier-vscode"
+ },
+ "prettier.tabWidth": 2,
+
+ // XML formatting style configuration
+ "xml.format.enabled": true,
+ "xml.format.legacy": false,
+ "xml.format.emptyElements": "collapse",
+ "xml.preferences.quoteStyle": "double",
+ "xml.format.enforceQuoteStyle": "preferred",
+ "xml.format.preserveAttributeLineBreaks": false,
+ "xml.format.preservedNewlines": 0,
+ "xml.format.splitAttributes": false,
+ "xml.format.joinCDATALines": true,
+ "xml.format.preserveEmptyContent": false,
+ "xml.format.joinCommentLines": false,
+ "xml.format.joinContentLines": false,
+ "xml.format.spaceBeforeEmptyCloseTag": true,
+ "xml.format.xsiSchemaLocationSplit": "onPair",
+ "xml.format.splitAttributesIndentSize": 2,
+ "xml.format.closingBracketNewLine": false,
+ "xml.format.preserveSpace": [
+ "xsl:text",
+ "xsl:comment",
+ "xsl:processing-instruction",
+ "literallayout",
+ "programlisting",
+ "screen",
+ "synopsis",
+ "pre",
+ "xd:pre"
+ ],
+ "xml.format.maxLineWidth": 0,
+ "xml.format.grammarAwareFormatting": true,
+
+ // Generic file formatting style configuration
+ "files.insertFinalNewline": true,
+ "files.trimFinalNewlines": false,
+ "files.trimTrailingWhitespace": true,
+
+ // Automatically detect indentation.
+ "editor.detectIndentation": true,
+ "editor.insertSpaces": true,
+ "editor.tabSize": 2,
+
+ // Automatically enforce Linux style line endings.
+ "files.eol": "\n",
+
+ "haxe.displayPort": "auto",
+ "haxe.enableCompilationServer": true,
+ "haxe.displayServer": {
+ "arguments": ["-v"]
+ },
+ // Fix file associations for HScript.
+ "files.associations": {
+ "*.hxp": "haxe",
+ "*.hscript": "haxe",
+ "*.haxe": "haxe",
+ "*.hxs": "haxe",
+ "*.hxc": "haxe"
+ },
+ "projectManager.git.baseFolders": ["./"],
+
+ "haxecheckstyle.sourceFolders": ["src", "Source"],
+ "haxecheckstyle.externalSourceRoots": [],
+ "haxecheckstyle.configurationFile": "checkstyle.json",
+ "haxecheckstyle.codeSimilarityBufferSize": 100,
+
+ "lime.targetConfigurations": [
+ {
+ "label": "Windows / Debug",
+ "target": "windows",
+ "args": ["-debug"]
},
-
- "[jsonc]": {
- // Automatically keep JSONC files formatted.
- "editor.formatOnSave": true,
- "editor.formatOnPaste": true,
- "editor.defaultFormatter": "esbenp.prettier-vscode"
+ {
+ "label": "Windows / Debug (DEBUG ASSETS)",
+ "target": "windows",
+ "args": ["-debug", "-DDEBUG_ASSETS"]
},
- "prettier.tabWidth": 2,
-
- // Automatically detect indentation.
- "editor.detectIndentation": true,
- "editor.insertSpaces": true,
- "editor.tabSize": 2,
-
- // Automatically enforce Linux style line endings.
- "files.eol": "\n",
-
- "haxe.displayPort": "auto",
- "haxe.enableCompilationServer": true,
- "haxe.displayServer": {
- "arguments": ["-v"]
+ {
+ "label": "Windows / Debug (ANIMATE)",
+ "target": "windows",
+ "args": ["-debug", "-DANIMATE"]
},
- // Fix file associations for HScript.
- "files.associations": {
- "*.hxp": "haxe",
- "*.hscript": "haxe",
- "*.haxe": "haxe",
- "*.hxs": "haxe",
- "*.hxc": "haxe"
+ {
+ "label": "HTML5 / Debug",
+ "target": "html5",
+ "args": ["-debug"]
},
- "projectManager.git.baseFolders": ["./"],
-
- "haxecheckstyle.sourceFolders": ["src", "Source"],
- "haxecheckstyle.externalSourceRoots": [],
- "haxecheckstyle.configurationFile": "checkstyle.json",
- "haxecheckstyle.codeSimilarityBufferSize": 100,
-
- "lime.targetConfigurations": [
- {
- "label": "Windows / Debug",
- "target": "windows",
- "args": ["-debug"]
- },
- {
- "label": "Windows / Debug (DEBUG ASSETS)",
- "target": "windows",
- "args": ["-debug", "-DDEBUG_ASSETS"]
- },
- {
- "label": "Windows / Debug (ANIMATE)",
- "target": "windows",
- "args": ["-debug", "-DANIMATE"]
- },
- {
- "label": "HTML5 / Debug",
- "target": "html5",
- "args": ["-debug"]
- },
- {
- "label": "HTML5 / Debug (Watch)",
- "target": "html5",
- "args": ["-debug", "-watch"]
- }
- ]
- }
\ No newline at end of file
+ {
+ "label": "HTML5 / Debug (Watch)",
+ "target": "html5",
+ "args": ["-debug", "-watch"]
+ }
+ ]
+}
diff --git a/Project.xml b/Project.xml
index 3f930bc73..e14e0ae0a 100644
--- a/Project.xml
+++ b/Project.xml
@@ -1,48 +1,33 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -93,9 +76,7 @@
-
-
-
-
-
-
-
-
+
-
-
-
+
-
-
-
+
+
-
-
-
-
-
-
@@ -155,85 +126,61 @@
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
-
-
-
+
+
+
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
+
diff --git a/example_mods/introMod/_polymod_meta.json b/example_mods/introMod/_polymod_meta.json
index 4c7fd742e..e0b03f1cd 100644
--- a/example_mods/introMod/_polymod_meta.json
+++ b/example_mods/introMod/_polymod_meta.json
@@ -1,9 +1,11 @@
{
"title": "Intro Mod",
"description": "An introductory mod.",
- "contributors": [{
- "name": "MasterEric"
- }],
+ "contributors": [
+ {
+ "name": "MasterEric"
+ }
+ ],
"api_version": "0.1.0",
"mod_version": "1.0.0",
"license": "Apache-2.0"
diff --git a/example_mods/testing123/_polymod_meta.json b/example_mods/testing123/_polymod_meta.json
index 1a7766820..4c0f177f9 100644
--- a/example_mods/testing123/_polymod_meta.json
+++ b/example_mods/testing123/_polymod_meta.json
@@ -1,9 +1,11 @@
{
"title": "Testing123",
"description": "Newgrounds? More like OLDGROUNDS lol.",
- "contributors": [{
- "name": "MasterEric"
- }],
+ "contributors": [
+ {
+ "name": "MasterEric"
+ }
+ ],
"api_version": "0.1.0",
"mod_version": "1.0.0",
"license": "Apache-2.0"
diff --git a/hmm.json b/hmm.json
index e92868545..9652d9440 100644
--- a/hmm.json
+++ b/hmm.json
@@ -68,7 +68,7 @@
"name": "hxcodec",
"type": "git",
"dir": null,
- "ref": "91adeec",
+ "ref": "c42ab99",
"url": "https://github.com/polybiusproxy/hxCodec"
},
{
@@ -95,7 +95,7 @@
"name": "lime",
"type": "git",
"dir": null,
- "ref": "deecd6c",
+ "ref": "5634ad7",
"url": "https://github.com/openfl/lime"
},
{
@@ -118,4 +118,4 @@
"version": "0.2.2"
}
]
-}
\ No newline at end of file
+}
diff --git a/source/funkin/Alphabet.hx b/source/funkin/Alphabet.hx
index adf97933a..a501707be 100644
--- a/source/funkin/Alphabet.hx
+++ b/source/funkin/Alphabet.hx
@@ -125,8 +125,7 @@ class Alphabet extends FlxSpriteGroup
var xPos:Float = 0;
var curRow:Int = 0;
- new FlxTimer().start(0.05, function(tmr:FlxTimer)
- {
+ new FlxTimer().start(0.05, function(tmr:FlxTimer) {
// trace(_finalText.fastCodeAt(loopNum) + " " + _finalText.charAt(loopNum));
if (_finalText.fastCodeAt(loopNum) == "\n".code)
{
diff --git a/source/funkin/ComboCounter.hx b/source/funkin/ComboCounter.hx
index ac8606691..28aed4560 100644
--- a/source/funkin/ComboCounter.hx
+++ b/source/funkin/ComboCounter.hx
@@ -27,8 +27,7 @@ class ComboCounter extends FlxTypedSpriteGroup
effectStuff.animation.addByPrefix('funny', 'NOTE COMBO animation', 24, false);
effectStuff.animation.play('funny');
effectStuff.antialiasing = true;
- effectStuff.animation.finishCallback = function(nameThing)
- {
+ effectStuff.animation.finishCallback = function(nameThing) {
kill();
};
effectStuff.setGraphicSize(Std.int(effectStuff.width * 0.7));
@@ -42,8 +41,7 @@ class ComboCounter extends FlxTypedSpriteGroup
{
if (onScreenTime < 0.9)
{
- new FlxTimer().start((Conductor.crochet / 1000) * 0.25, function(tmr)
- {
+ new FlxTimer().start((Conductor.crochet / 1000) * 0.25, function(tmr) {
forceFinish();
});
}
@@ -64,16 +62,14 @@ class ComboCounter extends FlxTypedSpriteGroup
if (effectStuff.animation.curAnim.curFrame == 18)
{
- grpNumbers.forEach(function(spr:ComboNumber)
- {
+ grpNumbers.forEach(function(spr:ComboNumber) {
spr.animation.reset();
});
}
if (effectStuff.animation.curAnim.curFrame == 20)
{
- grpNumbers.forEach(function(spr:ComboNumber)
- {
+ grpNumbers.forEach(function(spr:ComboNumber) {
spr.kill();
});
}
diff --git a/source/funkin/Conductor.hx b/source/funkin/Conductor.hx
index a0493869b..77af6b7f6 100644
--- a/source/funkin/Conductor.hx
+++ b/source/funkin/Conductor.hx
@@ -149,9 +149,9 @@ class Conductor
/**
* Forcibly defines the current BPM of the song.
* Useful for things like the chart editor that need to manipulate BPM in real time.
- *
+ *
* Set to null to reset to the BPM defined by the timeChanges.
- *
+ *
* WARNING: Avoid this for things like setting the BPM of the title screen music,
* you should have a metadata file for it instead.
*/
@@ -166,7 +166,7 @@ class Conductor
/**
* Update the conductor with the current song position.
* BPM, current step, etc. will be re-calculated based on the song position.
- *
+ *
* @param songPosition The current position in the song in milliseconds.
* Leave blank to use the FlxG.sound.music position.
*/
diff --git a/source/funkin/CoolUtil.hx b/source/funkin/CoolUtil.hx
index c7d3f7dab..7d7201029 100644
--- a/source/funkin/CoolUtil.hx
+++ b/source/funkin/CoolUtil.hx
@@ -119,8 +119,7 @@ class CoolUtil
FlxTween.tween(screenWipeShit, {daAlphaShit: 1}, time,
{
ease: FlxEase.quadInOut,
- onComplete: function(twn)
- {
+ onComplete: function(twn) {
screenShit.destroy();
FlxG.switchState(new MainMenuState());
}
@@ -130,7 +129,7 @@ class CoolUtil
/**
* Just saves the json with some default values hehe
- * @param json
+ * @param json
* @return String
*/
public static inline function jsonStringify(data:Dynamic):String
diff --git a/source/funkin/CutsceneCharacter.hx b/source/funkin/CutsceneCharacter.hx
index 67810bc30..7df3eb91c 100644
--- a/source/funkin/CutsceneCharacter.hx
+++ b/source/funkin/CutsceneCharacter.hx
@@ -52,8 +52,7 @@ class CutsceneCharacter extends FlxTypedGroup
cutScene.animation.play('weed');
cutScene.antialiasing = true;
- cutScene.animation.finishCallback = function(anim:String)
- {
+ cutScene.animation.finishCallback = function(anim:String) {
cutScene.kill();
cutScene.destroy();
cutScene = null;
diff --git a/source/funkin/DialogueBox.hx b/source/funkin/DialogueBox.hx
index e9c3587ad..945c9fe96 100644
--- a/source/funkin/DialogueBox.hx
+++ b/source/funkin/DialogueBox.hx
@@ -53,8 +53,7 @@ class DialogueBox extends FlxSpriteGroup
bgFade.alpha = 0;
add(bgFade);
- new FlxTimer().start(0.83, function(tmr:FlxTimer)
- {
+ new FlxTimer().start(0.83, function(tmr:FlxTimer) {
bgFade.alpha += (1 / 5) * 0.7;
if (bgFade.alpha > 0.7) bgFade.alpha = 0.7;
}, 5);
@@ -192,8 +191,7 @@ class DialogueBox extends FlxSpriteGroup
if (PlayState.currentSong.song.toLowerCase() == 'senpai'
|| PlayState.currentSong.song.toLowerCase() == 'thorns') FlxG.sound.music.fadeOut(2.2, 0);
- new FlxTimer().start(0.2, function(tmr:FlxTimer)
- {
+ new FlxTimer().start(0.2, function(tmr:FlxTimer) {
box.alpha -= 1 / 5;
bgFade.alpha -= 1 / 5 * 0.7;
portraitLeft.visible = false;
@@ -203,8 +201,7 @@ class DialogueBox extends FlxSpriteGroup
dropText.alpha = swagDialogue.alpha;
}, 5);
- new FlxTimer().start(1.2, function(tmr:FlxTimer)
- {
+ new FlxTimer().start(1.2, function(tmr:FlxTimer) {
finishThing();
kill();
});
@@ -233,8 +230,7 @@ class DialogueBox extends FlxSpriteGroup
// swagDialogue.text = ;
swagDialogue.resetText(dialogueList[0]);
swagDialogue.start(0.04);
- swagDialogue.completeCallback = function()
- {
+ swagDialogue.completeCallback = function() {
trace('dialogue finish');
handSelect.visible = true;
dialogueEnded = true;
diff --git a/source/funkin/Discord.hx b/source/funkin/Discord.hx
index 26a96ab52..4fb6e9dcf 100644
--- a/source/funkin/Discord.hx
+++ b/source/funkin/Discord.hx
@@ -58,8 +58,7 @@ class DiscordClient
public static function initialize()
{
- var DiscordDaemon = sys.thread.Thread.create(() ->
- {
+ var DiscordDaemon = sys.thread.Thread.create(() -> {
new DiscordClient();
});
trace("Discord Client initialized");
diff --git a/source/funkin/FreeplayState.hx b/source/funkin/FreeplayState.hx
index fb2119c55..bab9b95a2 100644
--- a/source/funkin/FreeplayState.hx
+++ b/source/funkin/FreeplayState.hx
@@ -426,7 +426,7 @@ class FreeplayState extends MusicBeatSubstate
var swag:Alphabet = new Alphabet(1, 0, "swag");
// JUST DOIN THIS SHIT FOR TESTING!!!
- /*
+ /*
var md:String = Markdown.markdownToHtml(Assets.getText('CHANGELOG.md'));
var texFel:TextField = new TextField();
diff --git a/source/funkin/LoadingState.hx b/source/funkin/LoadingState.hx
index 316041fd4..f0e56f602 100644
--- a/source/funkin/LoadingState.hx
+++ b/source/funkin/LoadingState.hx
@@ -50,8 +50,7 @@ class LoadingState extends MusicBeatState
loadBar.screenCenter(X);
add(loadBar);
- initSongsManifest().onComplete(function(lib)
- {
+ initSongsManifest().onComplete(function(lib) {
callbacks = new MultiCallback(onLoad);
var introComplete = callbacks.add("introComplete");
checkLoadSong(getSongPath());
@@ -89,8 +88,7 @@ class LoadingState extends MusicBeatState
// @:privateAccess
// library.pathGroups.set(symbolPath, [library.__cacheBreak(symbolPath)]);
var callback = callbacks.add("song:" + path);
- Assets.loadSound(path).onComplete(function(_)
- {
+ Assets.loadSound(path).onComplete(function(_) {
callback();
});
}
@@ -105,8 +103,7 @@ class LoadingState extends MusicBeatState
if (!LimeAssets.libraryPaths.exists(library)) throw "Missing library: " + library;
var callback = callbacks.add("library:" + library);
- Assets.loadLibrary(library).onComplete(function(_)
- {
+ Assets.loadLibrary(library).onComplete(function(_) {
callback();
});
}
@@ -259,8 +256,7 @@ class LoadingState extends MusicBeatState
path = LimeAssets.__cacheBreak(path);
}
- AssetManifest.loadFromFile(path, rootPath).onComplete(function(manifest)
- {
+ AssetManifest.loadFromFile(path, rootPath).onComplete(function(manifest) {
if (manifest == null)
{
promise.error("Cannot parse asset manifest for library \"" + id + "\"");
@@ -280,9 +276,8 @@ class LoadingState extends MusicBeatState
library.onChange.add(LimeAssets.onChange.dispatch);
promise.completeWith(Future.withValue(library));
}
- }).onError(function(_)
- {
- promise.error("There is no asset library with an ID of \"" + id + "\"");
+ }).onError(function(_) {
+ promise.error("There is no asset library with an ID of \"" + id + "\"");
});
return promise.future;
@@ -311,8 +306,7 @@ class MultiCallback
length++;
numRemaining++;
var func:Void->Void = null;
- func = function()
- {
+ func = function() {
if (unfired.exists(id))
{
unfired.remove(id);
diff --git a/source/funkin/MainMenuState.hx b/source/funkin/MainMenuState.hx
index e4bdfbe35..57640bffa 100644
--- a/source/funkin/MainMenuState.hx
+++ b/source/funkin/MainMenuState.hx
@@ -223,8 +223,8 @@ class MainMenuState extends MusicBeatState
/**
* Calls openPrompt and redraws the login/logout button
- * @param prompt
- * @param onClose
+ * @param prompt
+ * @param onClose
*/
public function openNgPrompt(prompt:Prompt, ?onClose:Void->Void)
{
diff --git a/source/funkin/MemoryCounter.hx b/source/funkin/MemoryCounter.hx
index 5ef09b332..658febe59 100644
--- a/source/funkin/MemoryCounter.hx
+++ b/source/funkin/MemoryCounter.hx
@@ -24,8 +24,7 @@ class MemoryCounter extends TextField
text = "RAM: ";
#if flash
- addEventListener(Event.ENTER_FRAME, function(e)
- {
+ addEventListener(Event.ENTER_FRAME, function(e) {
var time = Lib.getTimer();
__enterFrame(time - currentTime);
});
diff --git a/source/funkin/NGio.hx b/source/funkin/NGio.hx
index f538c9656..f2afe84db 100644
--- a/source/funkin/NGio.hx
+++ b/source/funkin/NGio.hx
@@ -49,8 +49,7 @@ class NGio
trace('checking NG.io version');
GAME_VER = "v" + Application.current.meta.get('version');
- NG.core.calls.app.getCurrentVersion(GAME_VER).addDataHandler(function(response)
- {
+ NG.core.calls.app.getCurrentVersion(GAME_VER).addDataHandler(function(response) {
GAME_VER = response.result.data.currentVersion;
trace('CURRENT NG VERSION: ' + GAME_VER);
callback(GAME_VER);
@@ -141,8 +140,7 @@ class NGio
var onCancel:Void->Void = null;
if (onComplete != null)
{
- onSuccess = function()
- {
+ onSuccess = function() {
onNGLogin();
onComplete(Success);
}
@@ -228,7 +226,7 @@ class NGio
scoreboardsLoaded = true;
ngScoresLoaded.dispatch();
- /*
+ /*
for (score in NG.core.scoreBoards.get(8737).scores)
{
trace('score loaded user:${score.user.name}, score:${score.formatted_value}');
diff --git a/source/funkin/Note.hx b/source/funkin/Note.hx
index 7fc49717e..91f45e973 100644
--- a/source/funkin/Note.hx
+++ b/source/funkin/Note.hx
@@ -15,9 +15,9 @@ class Note extends FlxSprite
public var data = new NoteData();
/**
- * code colors for.... code....
+ * code colors for.... code....
* i think goes in order of left to right
- *
+ *
* left 0
* down 1
* up 2
diff --git a/source/funkin/NoteSplash.hx b/source/funkin/NoteSplash.hx
index ea4242679..7f3a8c5e4 100644
--- a/source/funkin/NoteSplash.hx
+++ b/source/funkin/NoteSplash.hx
@@ -34,8 +34,7 @@ class NoteSplash extends FlxSprite
animation.play('note' + noteData + '-' + FlxG.random.int(0, 1), true);
animation.curAnim.frameRate = 24 + FlxG.random.int(-2, 2);
- animation.finishCallback = function(name)
- {
+ animation.finishCallback = function(name) {
kill();
};
updateHitbox();
diff --git a/source/funkin/SongLoad.hx b/source/funkin/SongLoad.hx
index d4ad0023e..ca3bc72d0 100644
--- a/source/funkin/SongLoad.hx
+++ b/source/funkin/SongLoad.hx
@@ -281,7 +281,7 @@ class SongLoad
// castNoteDataToNoteData(swagShit.noteMap[diff]);
- /*
+ /*
switch (diff)
{
case "easy":
diff --git a/source/funkin/TitleState.hx b/source/funkin/TitleState.hx
index e8e96e54d..0af0f4edf 100644
--- a/source/funkin/TitleState.hx
+++ b/source/funkin/TitleState.hx
@@ -53,7 +53,7 @@ class TitleState extends MusicBeatState
super.create();
- /*
+ /*
#elseif web
@@ -84,8 +84,7 @@ class TitleState extends MusicBeatState
*/
// netConnection.addEventListener(MouseEvent.MOUSE_DOWN, overlay_onMouseDown);
- new FlxTimer().start(1, function(tmr:FlxTimer)
- {
+ new FlxTimer().start(1, function(tmr:FlxTimer) {
startIntro();
});
}
@@ -284,7 +283,7 @@ class TitleState extends MusicBeatState
FlxTween.tween(FlxG.stage.window, {y: FlxG.stage.window.y + 100}, 0.7, {ease: FlxEase.quadInOut, type: PINGPONG});
}
- /*
+ /*
FlxG.watch.addQuick('cur display', FlxG.stage.window.display.id);
if (FlxG.keys.justPressed.Y)
{
@@ -373,8 +372,7 @@ class TitleState extends MusicBeatState
#if newgrounds
if (!OutdatedSubState.leftState)
{
- NGio.checkVersion(function(version)
- {
+ NGio.checkVersion(function(version) {
// Check if version is outdated
var localVersion:String = "v" + Application.current.meta.get('version');
var onlineVersion = version.split(" ")[0].trim();
@@ -391,8 +389,7 @@ class TitleState extends MusicBeatState
});
}
#end
- new FlxTimer().start(2, function(tmr:FlxTimer)
- {
+ new FlxTimer().start(2, function(tmr:FlxTimer) {
// These assets are very unlikely to be used for the rest of gameplay, so it unloads them from cache/memory
// Saves about 50mb of RAM or so???
Assets.cache.clear(Paths.image('gfDanceTitle'));
@@ -404,7 +401,7 @@ class TitleState extends MusicBeatState
// FlxG.sound.play(Paths.music('titleShoot'), 0.7);
}
if (pressedEnter && !skippedIntro && initialized) skipIntro();
- /*
+ /*
#if web
if (!initialized && controls.ACCEPT)
{
diff --git a/source/funkin/api/newgrounds/NGUtil.hx b/source/funkin/api/newgrounds/NGUtil.hx
index 88db899d1..773e2f98f 100644
--- a/source/funkin/api/newgrounds/NGUtil.hx
+++ b/source/funkin/api/newgrounds/NGUtil.hx
@@ -226,7 +226,7 @@ class NGUtil
scoreboardsLoaded = true;
ngScoresLoaded.dispatch();
- /*
+ /*
for (score in NG.core.scoreBoards.get(8737).scores)
{
trace('score loaded user:${score.user.name}, score:${score.formatted_value}');
diff --git a/source/funkin/api/newgrounds/NgPrompt.hx b/source/funkin/api/newgrounds/NgPrompt.hx
index 7f7d677ef..133132ba4 100644
--- a/source/funkin/api/newgrounds/NgPrompt.hx
+++ b/source/funkin/api/newgrounds/NgPrompt.hx
@@ -36,14 +36,12 @@ class NgPrompt extends Prompt
#if web
prompt.buttons.getItem("yes").fireInstantly = true;
#end
- prompt.onYes = function()
- {
+ prompt.onYes = function() {
prompt.setText("Connecting..." #if web + "\n(check your popup blocker)" #end);
prompt.setButtons(None);
openPassportUrl();
};
- prompt.onNo = function()
- {
+ prompt.onNo = function() {
prompt.close();
prompt = null;
NGio.cancelLogin();
@@ -92,8 +90,7 @@ class NgPrompt extends Prompt
{
var user = io.newgrounds.NG.core.user.name;
var prompt = new NgPrompt('Log out of $user?', Yes_No);
- prompt.onYes = function()
- {
+ prompt.onYes = function() {
NGio.logout();
prompt.close();
};
diff --git a/source/funkin/audio/SoundGroup.hx b/source/funkin/audio/SoundGroup.hx
index 69c52c3d0..ae755e231 100644
--- a/source/funkin/audio/SoundGroup.hx
+++ b/source/funkin/audio/SoundGroup.hx
@@ -44,7 +44,7 @@ class SoundGroup extends FlxTypedGroup
/**
* Finds the largest deviation from the desired time inside this SoundGroup.
- *
+ *
* @param targetTime The time to check against.
* If none is provided, it checks the time of all members against the first member of this SoundGroup.
* @return The largest deviation from the target time found.
diff --git a/source/funkin/charting/ChartingState.hx b/source/funkin/charting/ChartingState.hx
index 3cfac53be..d81013b50 100644
--- a/source/funkin/charting/ChartingState.hx
+++ b/source/funkin/charting/ChartingState.hx
@@ -484,7 +484,7 @@ class ChartingState extends MusicBeatState
// general shit
var title:FlxText = new FlxText(UI_box.x + 20, UI_box.y + 20, 0);
bullshitUI.add(title);
- /*
+ /*
var loopCheck = new FlxUICheckBox(UI_box.x + 10, UI_box.y + 50, null, null, "Loops", 100, ['loop check']);
loopCheck.checked = notes[0]elected.doesLoop;
tooltips.add(loopCheck, {title: 'Section looping', body: "Whether or not it's a simon says style section", style: tooltipType});
@@ -561,7 +561,7 @@ class ChartingState extends MusicBeatState
}*/
/**
* Gets the start time of section, defaults to the curSection
- * @param section
+ * @param section
* @return position of the song in... either seconds or milliseconds.... woops
*/
function sectionStartTime(?funnySection:Int):Float
@@ -1156,7 +1156,7 @@ class ChartingState extends MusicBeatState
{
sidePreview.drawRect(0, 0, 40, FlxG.height, 0xFF444444);
- /*
+ /*
var sectionsNeeded:Int = Std.int(FlxG.sound.music.length / (sectionCalc(_song.bpm) * 4));
while (sectionsNeeded > 0)
diff --git a/source/funkin/data/BaseRegistry.hx b/source/funkin/data/BaseRegistry.hx
index 0864fddd9..b30c311a3 100644
--- a/source/funkin/data/BaseRegistry.hx
+++ b/source/funkin/data/BaseRegistry.hx
@@ -11,7 +11,7 @@ typedef EntryConstructorFunction = String->Void;
/**
* A base type for a Registry, which is an object which handles loading scriptable objects.
- *
+ *
* @param T The type to construct. Must implement `IRegistryEntry`.
* @param J The type of the JSON data used when constructing.
*/
@@ -139,8 +139,8 @@ abstract class BaseRegistry & Constructible;
@@ -161,7 +161,7 @@ abstract class BaseRegistry & Constructible;
}
diff --git a/source/funkin/freeplayStuff/BGScrollingText.hx b/source/funkin/freeplayStuff/BGScrollingText.hx
index 1091afbe9..9fa6dd49b 100644
--- a/source/funkin/freeplayStuff/BGScrollingText.hx
+++ b/source/funkin/freeplayStuff/BGScrollingText.hx
@@ -48,8 +48,7 @@ class BGScrollingText extends FlxSpriteGroup
function set_funnyColor(col:Int):Int
{
- grpTexts.forEach(function(txt)
- {
+ grpTexts.forEach(function(txt) {
txt.color = col;
});
@@ -85,8 +84,7 @@ class BGScrollingText extends FlxSpriteGroup
function sortTextShit():Void
{
- grpTexts.sort(function(Order:Int, Obj1:FlxObject, Obj2:FlxObject)
- {
+ grpTexts.sort(function(Order:Int, Obj1:FlxObject, Obj2:FlxObject) {
return FlxSort.byValues(Order, Obj1.x, Obj2.x);
});
}
diff --git a/source/funkin/graphics/rendering/SustainTrail.hx b/source/funkin/graphics/rendering/SustainTrail.hx
index 80625b419..d9f43584e 100644
--- a/source/funkin/graphics/rendering/SustainTrail.hx
+++ b/source/funkin/graphics/rendering/SustainTrail.hx
@@ -77,9 +77,9 @@ class SustainTrail extends FlxSprite
/**
* Normally you would take strumTime:Float, noteData:Int, sustainLength:Float, parentNote:Note (?)
- * @param NoteData
- * @param SustainLength
- * @param FileName
+ * @param NoteData
+ * @param SustainLength
+ * @param FileName
*/
public function new(NoteData:Int, SustainLength:Float, Path:String, ?Alpha:Float = 0.6, ?Pixel:Bool = false)
{
diff --git a/source/funkin/graphics/video/FlxVideo.hx b/source/funkin/graphics/video/FlxVideo.hx
index db95c3d95..34b806f7e 100644
--- a/source/funkin/graphics/video/FlxVideo.hx
+++ b/source/funkin/graphics/video/FlxVideo.hx
@@ -18,7 +18,7 @@ class FlxVideo extends FlxBasic
public var finishCallback:Void->Void;
/**
- * Doesn't actually interact with Flixel shit, only just a pleasant to use class
+ * Doesn't actually interact with Flixel shit, only just a pleasant to use class
*/
public function new(vidSrc:String)
{
diff --git a/source/funkin/input/Cursor.hx b/source/funkin/input/Cursor.hx
index e965165f3..37e819469 100644
--- a/source/funkin/input/Cursor.hx
+++ b/source/funkin/input/Cursor.hx
@@ -123,8 +123,7 @@ class Cursor
if (assetCursorDefault == null)
{
var future:Future = Assets.loadBitmapData(CURSOR_DEFAULT_PARAMS.graphic);
- future.onComplete(function(bitmapData:BitmapData)
- {
+ future.onComplete(function(bitmapData:BitmapData) {
assetCursorDefault = bitmapData;
applyCursorParams(assetCursorDefault, CURSOR_DEFAULT_PARAMS);
});
@@ -138,8 +137,7 @@ class Cursor
if (assetCursorCross == null)
{
var future:Future = Assets.loadBitmapData(CURSOR_CROSS_PARAMS.graphic);
- future.onComplete(function(bitmapData:BitmapData)
- {
+ future.onComplete(function(bitmapData:BitmapData) {
assetCursorCross = bitmapData;
applyCursorParams(assetCursorCross, CURSOR_CROSS_PARAMS);
});
@@ -153,8 +151,7 @@ class Cursor
if (assetCursorEraser == null)
{
var future:Future = Assets.loadBitmapData(CURSOR_ERASER_PARAMS.graphic);
- future.onComplete(function(bitmapData:BitmapData)
- {
+ future.onComplete(function(bitmapData:BitmapData) {
assetCursorEraser = bitmapData;
applyCursorParams(assetCursorEraser, CURSOR_ERASER_PARAMS);
});
@@ -168,8 +165,7 @@ class Cursor
if (assetCursorGrabbing == null)
{
var future:Future = Assets.loadBitmapData(CURSOR_GRABBING_PARAMS.graphic);
- future.onComplete(function(bitmapData:BitmapData)
- {
+ future.onComplete(function(bitmapData:BitmapData) {
assetCursorGrabbing = bitmapData;
applyCursorParams(assetCursorGrabbing, CURSOR_GRABBING_PARAMS);
});
@@ -183,8 +179,7 @@ class Cursor
if (assetCursorHourglass == null)
{
var future:Future = Assets.loadBitmapData(CURSOR_HOURGLASS_PARAMS.graphic);
- future.onComplete(function(bitmapData:BitmapData)
- {
+ future.onComplete(function(bitmapData:BitmapData) {
assetCursorHourglass = bitmapData;
applyCursorParams(assetCursorHourglass, CURSOR_HOURGLASS_PARAMS);
});
@@ -198,8 +193,7 @@ class Cursor
if (assetCursorPointer == null)
{
var future:Future = Assets.loadBitmapData(CURSOR_POINTER_PARAMS.graphic);
- future.onComplete(function(bitmapData:BitmapData)
- {
+ future.onComplete(function(bitmapData:BitmapData) {
assetCursorPointer = bitmapData;
applyCursorParams(assetCursorPointer, CURSOR_POINTER_PARAMS);
});
@@ -213,8 +207,7 @@ class Cursor
if (assetCursorText == null)
{
var future:Future = Assets.loadBitmapData(CURSOR_TEXT_PARAMS.graphic);
- future.onComplete(function(bitmapData:BitmapData)
- {
+ future.onComplete(function(bitmapData:BitmapData) {
assetCursorText = bitmapData;
applyCursorParams(assetCursorText, CURSOR_TEXT_PARAMS);
});
@@ -228,8 +221,7 @@ class Cursor
if (assetCursorZoomIn == null)
{
var future:Future = Assets.loadBitmapData(CURSOR_ZOOM_IN_PARAMS.graphic);
- future.onComplete(function(bitmapData:BitmapData)
- {
+ future.onComplete(function(bitmapData:BitmapData) {
assetCursorZoomIn = bitmapData;
applyCursorParams(assetCursorZoomIn, CURSOR_ZOOM_IN_PARAMS);
});
@@ -243,8 +235,7 @@ class Cursor
if (assetCursorZoomOut == null)
{
var future:Future = Assets.loadBitmapData(CURSOR_ZOOM_OUT_PARAMS.graphic);
- future.onComplete(function(bitmapData:BitmapData)
- {
+ future.onComplete(function(bitmapData:BitmapData) {
assetCursorZoomOut = bitmapData;
applyCursorParams(assetCursorZoomOut, CURSOR_ZOOM_OUT_PARAMS);
});
diff --git a/source/funkin/input/TurboKeyHandler.hx b/source/funkin/input/TurboKeyHandler.hx
index 9181f836b..3719ff7cc 100644
--- a/source/funkin/input/TurboKeyHandler.hx
+++ b/source/funkin/input/TurboKeyHandler.hx
@@ -5,10 +5,10 @@ import flixel.FlxBasic;
/**
* Handles repeating behavior when holding down a key or key combination.
- *
+ *
* When the `keys` are pressed, `activated` will be true for the first frame,
* then wait `delay` seconds before becoming true for one frame every `interval` seconds.
- *
+ *
* Example: Pressing Ctrl+Z will undo, while holding Ctrl+Z will start to undo repeatedly.
*/
class TurboKeyHandler extends FlxBasic
diff --git a/source/funkin/modding/IScriptedClass.hx b/source/funkin/modding/IScriptedClass.hx
index 1450f8045..ee57de6be 100644
--- a/source/funkin/modding/IScriptedClass.hx
+++ b/source/funkin/modding/IScriptedClass.hx
@@ -4,7 +4,7 @@ import funkin.modding.events.ScriptEvent;
/**
* Defines a set of callbacks available to all scripted classes.
- *
+ *
* Includes events handling basic life cycle relevant to all scripted classes.
*/
interface IScriptedClass
@@ -53,7 +53,7 @@ interface INoteScriptedClass extends IScriptedClass
/**
* Developer note:
- *
+ *
* I previously considered adding events for onKeyDown, onKeyUp, mouse events, etc.
* However, I realized that you can simply call something like the following within a module:
* `FlxG.state.addEventListener(KeyboardEvent.KEY_DOWN, onKeyDown);`
diff --git a/source/funkin/modding/PolymodErrorHandler.hx b/source/funkin/modding/PolymodErrorHandler.hx
index 70a716821..dc387900b 100644
--- a/source/funkin/modding/PolymodErrorHandler.hx
+++ b/source/funkin/modding/PolymodErrorHandler.hx
@@ -8,7 +8,7 @@ class PolymodErrorHandler
* Show a popup with the given text.
* This displays a system popup, it WILL interrupt the game.
* Make sure to only use this when it's important, like when there's a script error.
- *
+ *
* @param name The name at the top of the popup.
* @param desc The body text of the popup.
*/
diff --git a/source/funkin/modding/events/ScriptEvent.hx b/source/funkin/modding/events/ScriptEvent.hx
index c99db1d0f..44838a6e1 100644
--- a/source/funkin/modding/events/ScriptEvent.hx
+++ b/source/funkin/modding/events/ScriptEvent.hx
@@ -19,7 +19,7 @@ class ScriptEvent
* Called when the relevant object is created.
* Keep in mind that the constructor may be called before the object is needed,
* for the purposes of caching data or otherwise.
- *
+ *
* This event is not cancelable.
*/
public static inline final CREATE:ScriptEventType = "CREATE";
@@ -27,7 +27,7 @@ class ScriptEvent
/**
* Called when the relevant object is destroyed.
* This should perform relevant cleanup to ensure good performance.
- *
+ *
* This event is not cancelable.
*/
public static inline final DESTROY:ScriptEventType = "DESTROY";
@@ -35,7 +35,7 @@ class ScriptEvent
/**
* Called when the relevent object is added to the game state.
* This assumes all data is loaded and ready to go.
- *
+ *
* This event is not cancelable.
*/
public static inline final ADDED:ScriptEventType = 'ADDED';
@@ -43,35 +43,35 @@ class ScriptEvent
/**
* Called during the update function.
* This is called every frame, so be careful!
- *
+ *
* This event is not cancelable.
*/
public static inline final UPDATE:ScriptEventType = "UPDATE";
/**
* Called when the player moves to pause the game.
- *
+ *
* This event IS cancelable! Canceling the event will prevent the game from pausing.
*/
public static inline final PAUSE:ScriptEventType = "PAUSE";
/**
* Called when the player moves to unpause the game while paused.
- *
+ *
* This event IS cancelable! Canceling the event will prevent the game from resuming.
*/
public static inline final RESUME:ScriptEventType = "RESUME";
/**
* Called once per step in the song. This happens 4 times per measure.
- *
+ *
* This event is not cancelable.
*/
public static inline final SONG_BEAT_HIT:ScriptEventType = "BEAT_HIT";
/**
* Called once per step in the song. This happens 16 times per measure.
- *
+ *
* This event is not cancelable.
*/
public static inline final SONG_STEP_HIT:ScriptEventType = "STEP_HIT";
@@ -105,7 +105,7 @@ class ScriptEvent
/**
* Called when a song event is reached in the chart.
- *
+ *
* This event IS cancelable! Cancelling this event prevents the event from being triggered,
* thus blocking its normal functionality.
*/
@@ -113,21 +113,21 @@ class ScriptEvent
/**
* Called when the song starts. This occurs as the countdown ends and the instrumental and vocals begin.
- *
+ *
* This event is not cancelable.
*/
public static inline final SONG_START:ScriptEventType = "SONG_START";
/**
* Called when the song ends. This happens as the instrumental and vocals end.
- *
+ *
* This event is not cancelable.
*/
public static inline final SONG_END:ScriptEventType = "SONG_END";
/**
* Called when the countdown begins. This occurs before the song starts.
- *
+ *
* This event IS cancelable! Canceling this event will prevent the countdown from starting.
* - The song will not start until you call Countdown.performCountdown() later.
* - Note that calling performCountdown() will trigger this event again, so be sure to add logic to ignore it.
@@ -137,7 +137,7 @@ class ScriptEvent
/**
* Called when a step of the countdown happens.
* Includes information about what step of the countdown was hit.
- *
+ *
* This event IS cancelable! Canceling this event will pause the countdown.
* - The countdown will not resume until you call PlayState.resumeCountdown().
*/
@@ -145,14 +145,14 @@ class ScriptEvent
/**
* Called when the countdown is done but just before the song starts.
- *
+ *
* This event is not cancelable.
*/
public static inline final COUNTDOWN_END:ScriptEventType = "COUNTDOWN_END";
/**
* Called before the game over screen triggers and the death animation plays.
- *
+ *
* This event is not cancelable.
*/
public static inline final GAME_OVER:ScriptEventType = "GAME_OVER";
@@ -160,21 +160,21 @@ class ScriptEvent
/**
* Called after the player presses a key to restart the game.
* This can happen from the pause menu or the game over screen.
- *
+ *
* This event IS cancelable! Canceling this event will prevent the game from restarting.
*/
public static inline final SONG_RETRY:ScriptEventType = "SONG_RETRY";
/**
* Called when the player pushes down any key on the keyboard.
- *
+ *
* This event is not cancelable.
*/
public static inline final KEY_DOWN:ScriptEventType = "KEY_DOWN";
/**
* Called when the player releases a key on the keyboard.
- *
+ *
* This event is not cancelable.
*/
public static inline final KEY_UP:ScriptEventType = "KEY_UP";
@@ -182,56 +182,56 @@ class ScriptEvent
/**
* Called when the game has finished loading the notes from JSON.
* This allows modders to mutate the notes before they are used in the song.
- *
+ *
* This event is not cancelable.
*/
public static inline final SONG_LOADED:ScriptEventType = "SONG_LOADED";
/**
* Called when the game is about to switch the current FlxState.
- *
+ *
* This event is not cancelable.
*/
public static inline final STATE_CHANGE_BEGIN:ScriptEventType = "STATE_CHANGE_BEGIN";
/**
* Called when the game has finished switching the current FlxState.
- *
+ *
* This event is not cancelable.
*/
public static inline final STATE_CHANGE_END:ScriptEventType = "STATE_CHANGE_END";
/**
* Called when the game is about to open a new FlxSubState.
- *
+ *
* This event is not cancelable.
*/
public static inline final SUBSTATE_OPEN_BEGIN:ScriptEventType = "SUBSTATE_OPEN_BEGIN";
/**
* Called when the game has finished opening a new FlxSubState.
- *
+ *
* This event is not cancelable.
*/
public static inline final SUBSTATE_OPEN_END:ScriptEventType = "SUBSTATE_OPEN_END";
/**
* Called when the game is about to close the current FlxSubState.
- *
+ *
* This event is not cancelable.
*/
public static inline final SUBSTATE_CLOSE_BEGIN:ScriptEventType = "SUBSTATE_CLOSE_BEGIN";
/**
* Called when the game has finished closing the current FlxSubState.
- *
+ *
* This event is not cancelable.
*/
public static inline final SUBSTATE_CLOSE_END:ScriptEventType = "SUBSTATE_CLOSE_END";
/**
* Called when the game is exiting the current FlxState.
- *
+ *
* This event is not cancelable.
*/
/**
diff --git a/source/funkin/modding/module/Module.hx b/source/funkin/modding/module/Module.hx
index d1a54b619..4d5e3457c 100644
--- a/source/funkin/modding/module/Module.hx
+++ b/source/funkin/modding/module/Module.hx
@@ -25,7 +25,7 @@ class Module implements IPlayStateScriptedClass implements IStateChangingScripte
/**
* Determines the order in which modules receive events.
* You can modify this to change the order in which a given module receives events.
- *
+ *
* Priority 1 is processed before Priority 1000, etc.
*/
public var priority(default, set):Int;
@@ -41,7 +41,7 @@ class Module implements IPlayStateScriptedClass implements IStateChangingScripte
/**
* Called when the module is initialized.
* It may not be safe to reference other modules here since they may not be loaded yet.
- *
+ *
* NOTE: To make the module start inactive, call `this.active = false` in the constructor.
*/
public function new(moduleId:String, priority:Int = 1000):Void
diff --git a/source/funkin/modding/module/ModuleHandler.hx b/source/funkin/modding/module/ModuleHandler.hx
index 51d723d0d..20bd6425c 100644
--- a/source/funkin/modding/module/ModuleHandler.hx
+++ b/source/funkin/modding/module/ModuleHandler.hx
@@ -16,7 +16,7 @@ class ModuleHandler
/**
* Parses and preloads the game's stage data and scripts when the game starts.
- *
+ *
* If you want to force stages to be reloaded, you can just call this function again.
*/
public static function loadModuleCache():Void
@@ -66,8 +66,7 @@ class ModuleHandler
{
modulePriorityOrder = moduleCache.keys().array();
- modulePriorityOrder.sort(function(a:String, b:String):Int
- {
+ modulePriorityOrder.sort(function(a:String, b:String):Int {
var aModule:Module = moduleCache.get(a);
var bModule:Module = moduleCache.get(b);
diff --git a/source/funkin/noteStuff/NoteUtil.hx b/source/funkin/noteStuff/NoteUtil.hx
index 610f82a09..a36c32482 100644
--- a/source/funkin/noteStuff/NoteUtil.hx
+++ b/source/funkin/noteStuff/NoteUtil.hx
@@ -7,7 +7,7 @@ import openfl.Assets;
* Just various functions that IDK where to put em!!!
* Semi-temp for now? the note stuff is super clutter-y right now
* so I am putting this new stuff here right now XDD
- *
+ *
* A lot of this stuff can probably be moved to where appropriate!
* i dont care about NoteUtil.hx at all!!!
*/
@@ -15,7 +15,7 @@ class NoteUtil
{
/**
* IDK THING FOR BOTH LOL! DIS SHIT HACK-Y
- * @param jsonPath
+ * @param jsonPath
* @return Map>
*/
public static function loadSongEvents(jsonPath:String):Map>
@@ -34,7 +34,7 @@ class NoteUtil
/**
* Parses song event json stuff into a neater lil map grouping?
- * @param songEvents
+ * @param songEvents
*/
public static function parseSongEvents(songEvents:Array):Map>
{
diff --git a/source/funkin/play/Countdown.hx b/source/funkin/play/Countdown.hx
index 0af098dbd..d9e2fda4c 100644
--- a/source/funkin/play/Countdown.hx
+++ b/source/funkin/play/Countdown.hx
@@ -46,8 +46,7 @@ class Countdown
// The timer function gets called based on the beat of the song.
countdownTimer = new FlxTimer();
- countdownTimer.start(Conductor.crochet / 1000, function(tmr:FlxTimer)
- {
+ countdownTimer.start(Conductor.crochet / 1000, function(tmr:FlxTimer) {
countdownStep = decrement(countdownStep);
// Handle onBeatHit events manually
@@ -102,7 +101,7 @@ class Countdown
/**
* Pauses the countdown at the current step. You can start it up again later by calling resumeCountdown().
- *
+ *
* If you want to call this from a module, it's better to use the event system and cancel the onCountdownStep event.
*/
public static function pauseCountdown()
@@ -115,7 +114,7 @@ class Countdown
/**
* Resumes the countdown at the current step. Only makes sense if you called pauseCountdown() first.
- *
+ *
* If you want to call this from a module, it's better to use the event system and cancel the onCountdownStep event.
*/
public static function resumeCountdown()
@@ -128,7 +127,7 @@ class Countdown
/**
* Stops the countdown at the current step. You will have to restart it again later.
- *
+ *
* If you want to call this from a module, it's better to use the event system and cancel the onCountdownStart event.
*/
public static function stopCountdown()
@@ -166,7 +165,7 @@ class Countdown
/**
* Retrieves the graphic to use for this step of the countdown.
* TODO: Make this less dumb. Unhardcode it? Use modules? Use notestyles?
- *
+ *
* This is public so modules can do lol funny shit.
*/
public static function showCountdownGraphic(index:CountdownStep, isPixelStyle:Bool):Void
@@ -216,8 +215,7 @@ class Countdown
FlxTween.tween(countdownSprite, {y: countdownSprite.y += 100, alpha: 0}, Conductor.crochet / 1000,
{
ease: FlxEase.cubeInOut,
- onComplete: function(twn:FlxTween)
- {
+ onComplete: function(twn:FlxTween) {
countdownSprite.destroy();
}
});
@@ -228,7 +226,7 @@ class Countdown
/**
* Retrieves the sound file to use for this step of the countdown.
* TODO: Make this less dumb. Unhardcode it? Use modules? Use notestyles?
- *
+ *
* This is public so modules can do lol funny shit.
*/
public static function playCountdownSound(index:CountdownStep, isPixelStyle:Bool):Void
diff --git a/source/funkin/play/GameOverSubstate.hx b/source/funkin/play/GameOverSubstate.hx
index 3d5470324..2c46fa10f 100644
--- a/source/funkin/play/GameOverSubstate.hx
+++ b/source/funkin/play/GameOverSubstate.hx
@@ -15,7 +15,7 @@ import funkin.ui.PreferencesMenu;
/**
* A substate which renders over the PlayState when the player dies.
* Displays the player death animation, plays the music, and handles restarting the song.
- *
+ *
* The newest implementation uses a substate, which prevents having to reload the song and stage each reset.
*/
class GameOverSubstate extends MusicBeatSubstate
@@ -237,7 +237,7 @@ class GameOverSubstate extends MusicBeatSubstate
/**
* Starts the death music at the appropriate volume.
- * @param startingVolume
+ * @param startingVolume
*/
function startDeathMusic(?startingVolume:Float = 1, ?force:Bool = false):Void
{
diff --git a/source/funkin/play/HealthIcon.hx b/source/funkin/play/HealthIcon.hx
index f2bf431bc..a15c63060 100644
--- a/source/funkin/play/HealthIcon.hx
+++ b/source/funkin/play/HealthIcon.hx
@@ -317,7 +317,7 @@ class HealthIcon extends FlxSprite
/**
* Load health icon animations from a Sparrow XML file (the kind used by characters)
* Note that this is looking for SPECIFIC animation names, so you may need to modify the XML.
- * @param charId
+ * @param charId
*/
function loadAnimationNew():Void
{
@@ -333,7 +333,7 @@ class HealthIcon extends FlxSprite
/**
* Load health icon animations using the legacy format.
* Simply assumes two icons, the idle and losing icons.
- * @param charId
+ * @param charId
*/
function loadAnimationOld():Void
{
diff --git a/source/funkin/play/PlayState.hx b/source/funkin/play/PlayState.hx
index 047a1b5fe..987243585 100644
--- a/source/funkin/play/PlayState.hx
+++ b/source/funkin/play/PlayState.hx
@@ -164,7 +164,7 @@ class PlayState extends MusicBeatState
/**
* An empty FlxObject contained in the scene.
* The current gameplay camera will be centered on this object. Tween its position to move the camera smoothly.
- *
+ *
* This is an FlxSprite for two reasons:
* 1. It needs to be an object in the scene for the camera to be configured to follow it.
* 2. It needs to be an FlxSprite to allow a graphic (optionally, for debug purposes) to be drawn on it.
@@ -859,10 +859,10 @@ class PlayState extends MusicBeatState
/**
* Removes any references to the current stage, then clears the stage cache,
* then reloads all the stages.
- *
+ *
* This is useful for when you want to edit a stage without reloading the whole game.
* Reloading works on both the JSON and the HXC, if applicable.
- *
+ *
* Call this by pressing F5 on a debug build.
*/
override function debug_refreshModules()
@@ -892,7 +892,7 @@ class PlayState extends MusicBeatState
/**
* Loads stage data from cache, assembles the props,
* and adds it to the state.
- * @param id
+ * @param id
*/
function loadStage(id:String)
{
@@ -1840,7 +1840,7 @@ class PlayState extends MusicBeatState
/**
* Jumps forward or backward a number of sections in the song.
* Accounts for BPM changes, does not prevent death from skipped notes.
- * @param sec
+ * @param sec
*/
function changeSection(sec:Int):Void
{
@@ -2273,9 +2273,9 @@ class PlayState extends MusicBeatState
* Called when a player presses a key with no note present.
* Scripts can modify the amount of health/score lost, whether player animations or sounds are used,
* or even cancel the event entirely.
- *
- * @param direction
- * @param hasPossibleNotes
+ *
+ * @param direction
+ * @param hasPossibleNotes
*/
function ghostNoteMiss(direction:funkin.noteStuff.NoteBasic.NoteType = 1, hasPossibleNotes:Bool = true):Void
{
@@ -2535,7 +2535,7 @@ class PlayState extends MusicBeatState
/**
* Handles characters dancing to the beat of the current song.
- *
+ *
* TODO: Move some of this logic into `Bopper.hx`
*/
public function danceOnBeat()
@@ -2628,7 +2628,7 @@ class PlayState extends MusicBeatState
/**
* Function called before closing the current substate.
- * @param subState
+ * @param subState
*/
public override function closeSubState()
{
diff --git a/source/funkin/play/Strumline.hx b/source/funkin/play/Strumline.hx
index f45de5cac..4bbcc720a 100644
--- a/source/funkin/play/Strumline.hx
+++ b/source/funkin/play/Strumline.hx
@@ -13,7 +13,7 @@ import funkin.util.Constants;
/**
* A group controlling the individual notes of the strumline for a given player.
- *
+ *
* FUN FACT: Setting the X and Y of a FlxSpriteGroup will move all the sprites in the group.
*/
class Strumline extends FlxTypedSpriteGroup
@@ -62,8 +62,8 @@ class Strumline extends FlxTypedSpriteGroup
/**
* Apply a small animation which moves the arrow down and fades it in.
* Only plays at the start of Free Play songs.
- *
- * Note that modifying the offset of the whole strumline won't have the
+ *
+ * Note that modifying the offset of the whole strumline won't have the
* @param arrow The arrow to animate.
* @param index The index of the arrow in the strumline.
*/
diff --git a/source/funkin/play/character/AnimateAtlasCharacter.hx b/source/funkin/play/character/AnimateAtlasCharacter.hx
index f0ce48a32..4f4b3f8f7 100644
--- a/source/funkin/play/character/AnimateAtlasCharacter.hx
+++ b/source/funkin/play/character/AnimateAtlasCharacter.hx
@@ -32,7 +32,7 @@ typedef AnimateAtlasAnimation =
/**
* An AnimateAtlasCharacter is a Character which is rendered by
* displaying an animation derived from an Adobe Animate texture atlas spritesheet file.
- *
+ *
* BaseCharacter has game logic, AnimateAtlasCharacter has only rendering logic.
* KEEP THEM SEPARATE!
*/
@@ -537,7 +537,7 @@ class AnimateAtlasCharacter extends BaseCharacter
/**
* Returns the left-most position of the left-most member.
* If there are no members, x is returned.
- *
+ *
* @since 5.0.0
* @return the left-most position of the left-most member
*/
@@ -554,7 +554,7 @@ class AnimateAtlasCharacter extends BaseCharacter
/**
* Returns the right-most position of the right-most member.
* If there are no members, x is returned.
- *
+ *
* @since 5.0.0
* @return the right-most position of the right-most member
*/
@@ -586,7 +586,7 @@ class AnimateAtlasCharacter extends BaseCharacter
/**
* Returns the top-most position of the top-most member.
* If there are no members, y is returned.
- *
+ *
* @since 5.0.0
* @return the top-most position of the top-most member
*/
@@ -603,7 +603,7 @@ class AnimateAtlasCharacter extends BaseCharacter
/**
* Returns the top-most position of the top-most member.
* If there are no members, y is returned.
- *
+ *
* @since 5.0.0
* @return the bottom-most position of the bottom-most member
*/
diff --git a/source/funkin/play/character/BaseCharacter.hx b/source/funkin/play/character/BaseCharacter.hx
index df3b60626..a2830f2a8 100644
--- a/source/funkin/play/character/BaseCharacter.hx
+++ b/source/funkin/play/character/BaseCharacter.hx
@@ -9,7 +9,7 @@ import funkin.play.stage.Bopper;
/**
* A Character is a stage prop which bops to the music as well as controlled by the strumlines.
- *
+ *
* Remember: The character's origin is at its FEET. (horizontal center, vertical bottom)
*/
class BaseCharacter extends Bopper
@@ -43,7 +43,7 @@ class BaseCharacter extends Bopper
/**
* Set to true when the character being used in a special way.
* This includes the Chart Editor and the Animation Editor.
- *
+ *
* Used by scripts to ensure that they don't try to run code to interact with the stage when the stage doesn't actually exist.
*/
public var debug:Bool = false;
@@ -76,7 +76,7 @@ class BaseCharacter extends Bopper
/**
* The absolute position of the top-left of the character.
- * @return
+ * @return
*/
public var cornerPosition(get, set):FlxPoint;
@@ -112,7 +112,7 @@ class BaseCharacter extends Bopper
/**
* Returns the point the camera should focus on.
* Should be approximately centered on the character, and should not move based on the current animation.
- *
+ *
* Set the position of this rather than reassigning it, so that anything referencing it will not be affected.
*/
public var cameraFocusPoint(default, null):FlxPoint = new FlxPoint(0, 0);
@@ -242,7 +242,7 @@ class BaseCharacter extends Bopper
/**
* Set the sprite scale to the appropriate value.
- * @param scale
+ * @param scale
*/
public function setScale(scale:Null):Void
{
@@ -394,7 +394,7 @@ class BaseCharacter extends Bopper
/**
* Since no `onBeatHit` or `dance` calls happen in GameOverSubState,
* this regularly gets called instead.
- *
+ *
* @param force Force the deathLoop animation to play, even if `firstDeath` is still playing.
*/
public function playDeathAnimation(force:Bool = false):Void
diff --git a/source/funkin/play/character/CharacterData.hx b/source/funkin/play/character/CharacterData.hx
index 886047ec2..16bf3a8a6 100644
--- a/source/funkin/play/character/CharacterData.hx
+++ b/source/funkin/play/character/CharacterData.hx
@@ -33,7 +33,7 @@ class CharacterDataParser
/**
* Parses and preloads the game's stage data and scripts when the game starts.
- *
+ *
* If you want to force stages to be reloaded, you can just call this function again.
*/
public static function loadCharacterCache():Void
@@ -294,7 +294,7 @@ class CharacterDataParser
/**
* Load a character's JSON file and parse its data.
- *
+ *
* @param charId The character to load.
* @return The character data, or null if validation failed.
*/
@@ -363,8 +363,8 @@ class CharacterDataParser
/**
* Set unspecified parameters to their defaults.
* If the parameter is mandatory, print an error message.
- * @param id
- * @param input
+ * @param id
+ * @param input
* @return The validated character data
*/
static function validateCharacterData(id:String, input:CharacterData):Null
@@ -624,7 +624,7 @@ typedef CharacterData =
/**
* The frequency at which the character will play its idle animation, in beats.
* Increasing this number will make the character dance less often.
- *
+ *
* @default 1
*/
var danceEvery:Null;
@@ -633,7 +633,7 @@ typedef CharacterData =
* The minimum duration that a character will play a note animation for, in beats.
* If this number is too low, you may see the character start playing the idle animation between notes.
* If this number is too high, you may see the the character play the sing animation for too long after the notes are gone.
- *
+ *
* Examples:
* - Daddy Dearest uses a value of `1.525`.
* @default 1.0
@@ -654,7 +654,7 @@ typedef CharacterData =
/**
* Whether or not the whole ass sprite is flipped by default.
* Useful for characters that could also be played (Pico)
- *
+ *
* @default false
*/
var flipX:Null;
diff --git a/source/funkin/play/character/MultiSparrowCharacter.hx b/source/funkin/play/character/MultiSparrowCharacter.hx
index 5d4deee5d..45934c99b 100644
--- a/source/funkin/play/character/MultiSparrowCharacter.hx
+++ b/source/funkin/play/character/MultiSparrowCharacter.hx
@@ -8,11 +8,11 @@ import funkin.play.character.CharacterData.CharacterRenderType;
/**
* For some characters which use Sparrow atlases, the spritesheets need to be split
* into multiple files. This character renderer handles by showing the appropriate sprite.
- *
+ *
* Examples in base game include BF Holding GF (most of the sprites are in one file
* but the death animation is in a separate file).
* Only example I can think of in mods is Tricky (which has a separate file for each animation).
- *
+ *
* BaseCharacter has game logic, SparrowCharacter has only rendering logic.
* KEEP THEM SEPARATE!
*
diff --git a/source/funkin/play/character/SparrowCharacter.hx b/source/funkin/play/character/SparrowCharacter.hx
index 1db14fe23..4bd17e7e6 100644
--- a/source/funkin/play/character/SparrowCharacter.hx
+++ b/source/funkin/play/character/SparrowCharacter.hx
@@ -8,7 +8,7 @@ import funkin.play.character.CharacterData.CharacterRenderType;
/**
* A SparrowCharacter is a Character which is rendered by
* displaying an animation derived from a SparrowV2 atlas spritesheet file.
- *
+ *
* BaseCharacter has game logic, SparrowCharacter has only rendering logic.
* KEEP THEM SEPARATE!
*/
diff --git a/source/funkin/play/event/FocusCameraSongEvent.hx b/source/funkin/play/event/FocusCameraSongEvent.hx
index 29d2e80e0..45c01e739 100644
--- a/source/funkin/play/event/FocusCameraSongEvent.hx
+++ b/source/funkin/play/event/FocusCameraSongEvent.hx
@@ -6,7 +6,7 @@ import funkin.play.song.SongData;
/**
* This class represents a handler for a type of song event.
* It is used by the ScriptedSongEvent class to handle user-defined events.
- *
+ *
* Example: Focus on Boyfriend:
* ```
* {
@@ -16,7 +16,7 @@ import funkin.play.song.SongData;
* }
* }
* ```
- *
+ *
* Example: Focus on 10px above Girlfriend:
* ```
* {
@@ -27,7 +27,7 @@ import funkin.play.song.SongData;
* }
* }
* ```
- *
+ *
* Example: Focus on (100, 100):
* ```
* {
diff --git a/source/funkin/play/event/ScriptedSongEvent.hx b/source/funkin/play/event/ScriptedSongEvent.hx
index 6f5e1c9bc..d85a1c838 100644
--- a/source/funkin/play/event/ScriptedSongEvent.hx
+++ b/source/funkin/play/event/ScriptedSongEvent.hx
@@ -7,7 +7,7 @@ import polymod.hscript.HScriptedClass;
* A script that can be tied to a SongEvent.
* Create a scripted class that extends SongEvent,
* then call `super('SongEventType')` to use this.
- *
+ *
* - Remember to override `handleEvent(data:SongEventData)` to perform your actions when the event is hit.
* - Remember to override `getTitle()` to return an event name that will be displayed in the editor.
* - Remember to override `getEventSchema()` to return a schema for the event data, used to build a form in the chart editor.
diff --git a/source/funkin/play/event/SongEvent.hx b/source/funkin/play/event/SongEvent.hx
index 4071f9a34..24b4d51bf 100644
--- a/source/funkin/play/event/SongEvent.hx
+++ b/source/funkin/play/event/SongEvent.hx
@@ -184,8 +184,7 @@ class SongEventParser
*/
public static function queryEvents(events:Array, currentTime:Float):Array
{
- return events.filter(function(event:SongEventData):Bool
- {
+ return events.filter(function(event:SongEventData):Bool {
// If the event is already activated, don't activate it again.
if (event.activated) return false;
diff --git a/source/funkin/play/song/Song.hx b/source/funkin/play/song/Song.hx
index a712de1cc..7de005cb0 100644
--- a/source/funkin/play/song/Song.hx
+++ b/source/funkin/play/song/Song.hx
@@ -324,7 +324,7 @@ class SongDifficulty
/**
* Build a list of vocal files for the given character.
* Automatically resolves suffixed character IDs (so bf-car will resolve to bf if needed).
- *
+ *
* @param id The character we are about to play.
*/
public function buildVoiceList(?id:String = 'bf'):Array
diff --git a/source/funkin/play/song/SongData.hx b/source/funkin/play/song/SongData.hx
index 982ccb402..78593c6c0 100644
--- a/source/funkin/play/song/SongData.hx
+++ b/source/funkin/play/song/SongData.hx
@@ -24,7 +24,7 @@ class SongDataParser
/**
* Parses and preloads the game's song metadata and scripts when the game starts.
- *
+ *
* If you want to force song metadata to be reloaded, you can just call this function again.
*/
public static function loadSongCache():Void
@@ -217,7 +217,7 @@ typedef RawSongMetadata =
{
/**
* A semantic versioning string for the song data format.
- *
+ *
*/
var version:Version;
@@ -414,7 +414,7 @@ abstract SongNoteData(RawSongNoteData)
/**
* The strumline index of the note, if applicable.
* Strips the direction from the data.
- *
+ *
* 0 = player, 1 = opponent, etc.
*/
public inline function getStrumlineIndex(strumlineSize:Int = 4):Int
diff --git a/source/funkin/play/song/SongDataUtils.hx b/source/funkin/play/song/SongDataUtils.hx
index 27625e846..f75972ee7 100644
--- a/source/funkin/play/song/SongDataUtils.hx
+++ b/source/funkin/play/song/SongDataUtils.hx
@@ -14,14 +14,13 @@ class SongDataUtils
* Given an array of SongNoteData objects, return a new array of SongNoteData objects
* whose timestamps are shifted by the given amount.
* Does not mutate the original array.
- *
+ *
* @param notes The notes to modify.
* @param offset The time difference to apply in milliseconds.
*/
public static function offsetSongNoteData(notes:Array, offset:Int):Array
{
- return notes.map(function(note:SongNoteData):SongNoteData
- {
+ return notes.map(function(note:SongNoteData):SongNoteData {
return new SongNoteData(note.time + offset, note.data, note.length, note.kind);
});
}
@@ -30,14 +29,13 @@ class SongDataUtils
* Given an array of SongEventData objects, return a new array of SongEventData objects
* whose timestamps are shifted by the given amount.
* Does not mutate the original array.
- *
+ *
* @param events The events to modify.
* @param offset The time difference to apply in milliseconds.
*/
public static function offsetSongEventData(events:Array, offset:Int):Array
{
- return events.map(function(event:SongEventData):SongEventData
- {
+ return events.map(function(event:SongEventData):SongEventData {
return new SongEventData(event.time + offset, event.event, event.value);
});
}
@@ -45,7 +43,7 @@ class SongDataUtils
/**
* Return a new array without a certain subset of notes from an array of SongNoteData objects.
* Does not mutate the original array.
- *
+ *
* @param notes The array of notes to be subtracted from.
* @param subtrahend The notes to remove from the `notes` array. Yes, subtrahend is a real word.
*/
@@ -53,8 +51,7 @@ class SongDataUtils
{
if (notes.length == 0 || subtrahend.length == 0) return notes;
- var result = notes.filter(function(note:SongNoteData):Bool
- {
+ var result = notes.filter(function(note:SongNoteData):Bool {
for (x in subtrahend)
// SongNoteData's == operation has been overridden so that this will work.
if (x == note) return false;
@@ -68,7 +65,7 @@ class SongDataUtils
/**
* Return a new array without a certain subset of events from an array of SongEventData objects.
* Does not mutate the original array.
- *
+ *
* @param events The array of events to be subtracted from.
* @param subtrahend The events to remove from the `events` array. Yes, subtrahend is a real word.
*/
@@ -76,8 +73,7 @@ class SongDataUtils
{
if (events.length == 0 || subtrahend.length == 0) return events;
- return events.filter(function(event:SongEventData):Bool
- {
+ return events.filter(function(event:SongEventData):Bool {
// SongEventData's == operation has been overridden so that this will work.
return !subtrahend.has(event);
});
@@ -89,8 +85,7 @@ class SongDataUtils
*/
public static function flipNotes(notes:Array, ?strumlineSize:Int = 4):Array
{
- return notes.map(function(note:SongNoteData):SongNoteData
- {
+ return notes.map(function(note:SongNoteData):SongNoteData {
var newData = note.data;
if (newData < strumlineSize) newData += strumlineSize;
@@ -103,7 +98,7 @@ class SongDataUtils
/**
* Prepare an array of notes to be used as the clipboard data.
- *
+ *
* Offset the provided array of notes such that the first note is at 0 milliseconds.
*/
public static function buildNoteClipboard(notes:Array):Array
@@ -113,7 +108,7 @@ class SongDataUtils
/**
* Prepare an array of events to be used as the clipboard data.
- *
+ *
* Offset the provided array of events such that the first event is at 0 milliseconds.
*/
public static function buildEventClipboard(events:Array):Array
@@ -127,8 +122,7 @@ class SongDataUtils
public static function sortNotes(notes:Array, ?desc:Bool = false):Array
{
// TODO: Modifies the array in place. Is this okay?
- notes.sort(function(a:SongNoteData, b:SongNoteData):Int
- {
+ notes.sort(function(a:SongNoteData, b:SongNoteData):Int {
return FlxSort.byValues(desc ? FlxSort.DESCENDING : FlxSort.ASCENDING, a.time, b.time);
});
return notes;
@@ -140,8 +134,7 @@ class SongDataUtils
public static function sortEvents(events:Array, ?desc:Bool = false):Array
{
// TODO: Modifies the array in place. Is this okay?
- events.sort(function(a:SongEventData, b:SongEventData):Int
- {
+ events.sort(function(a:SongEventData, b:SongEventData):Int {
return FlxSort.byValues(desc ? FlxSort.DESCENDING : FlxSort.ASCENDING, a.time, b.time);
});
return events;
@@ -192,8 +185,7 @@ class SongDataUtils
*/
public static function getNotesInTimeRange(notes:Array, start:Float, end:Float):Array
{
- return notes.filter(function(note:SongNoteData):Bool
- {
+ return notes.filter(function(note:SongNoteData):Bool {
return note.time >= start && note.time <= end;
});
}
@@ -203,8 +195,7 @@ class SongDataUtils
*/
public static function getEventsInTimeRange(events:Array, start:Float, end:Float):Array
{
- return events.filter(function(event:SongEventData):Bool
- {
+ return events.filter(function(event:SongEventData):Bool {
return event.time >= start && event.time <= end;
});
}
@@ -214,8 +205,7 @@ class SongDataUtils
*/
public static function getNotesInDataRange(notes:Array, start:Int, end:Int):Array
{
- return notes.filter(function(note:SongNoteData):Bool
- {
+ return notes.filter(function(note:SongNoteData):Bool {
return note.data >= start && note.data <= end;
});
}
@@ -225,8 +215,7 @@ class SongDataUtils
*/
public static function getNotesWithData(notes:Array, data:Array):Array
{
- return notes.filter(function(note:SongNoteData):Bool
- {
+ return notes.filter(function(note:SongNoteData):Bool {
return data.indexOf(note.data) != -1;
});
}
diff --git a/source/funkin/play/song/SongSerializer.hx b/source/funkin/play/song/SongSerializer.hx
index c7933665a..968a7a1f5 100644
--- a/source/funkin/play/song/SongSerializer.hx
+++ b/source/funkin/play/song/SongSerializer.hx
@@ -50,8 +50,7 @@ class SongSerializer
*/
public static function importSongChartDataAsync(callback:SongChartData->Void):Void
{
- browseFileReference(function(fileReference:FileReference)
- {
+ browseFileReference(function(fileReference:FileReference) {
var data = fileReference.data.toString();
if (data == null) return;
@@ -68,8 +67,7 @@ class SongSerializer
*/
public static function importSongMetadataAsync(callback:SongMetadata->Void):Void
{
- browseFileReference(function(fileReference:FileReference)
- {
+ browseFileReference(function(fileReference:FileReference) {
var data = fileReference.data.toString();
if (data == null) return;
@@ -103,7 +101,7 @@ class SongSerializer
/**
* Save a SongChartData object as a JSON file to a specified path.
* Works great on HTML5 and desktop.
- *
+ *
* @param path The file path to save to.
*/
public static function exportSongChartDataAs(path:String, data:SongChartData)
@@ -116,7 +114,7 @@ class SongSerializer
/**
* Save a SongMetadata object as a JSON file to a specified path.
* Works great on HTML5 and desktop.
- *
+ *
* @param path The file path to save to.
*/
public static function exportSongMetadataAs(path:String, data:SongMetadata)
@@ -163,19 +161,17 @@ class SongSerializer
/**
* Browse for a file to read and execute a callback once we have a file reference.
* Works great on HTML5 or desktop.
- *
+ *
* @param callback The function to call when the file is loaded.
*/
static function browseFileReference(callback:FileReference->Void)
{
var file = new FileReference();
- file.addEventListener(Event.SELECT, function(e)
- {
+ file.addEventListener(Event.SELECT, function(e) {
var selectedFileRef:FileReference = e.target;
trace('Selected file: ' + selectedFileRef.name);
- selectedFileRef.addEventListener(Event.COMPLETE, function(e)
- {
+ selectedFileRef.addEventListener(Event.COMPLETE, function(e) {
var loadedFileRef:FileReference = e.target;
trace('Loaded file: ' + loadedFileRef.name);
callback(loadedFileRef);
@@ -192,16 +188,13 @@ class SongSerializer
static function writeFileReference(path:String, data:String)
{
var file = new FileReference();
- file.addEventListener(Event.COMPLETE, function(e:Event)
- {
+ file.addEventListener(Event.COMPLETE, function(e:Event) {
trace('Successfully wrote file.');
});
- file.addEventListener(Event.CANCEL, function(e:Event)
- {
+ file.addEventListener(Event.CANCEL, function(e:Event) {
trace('Cancelled writing file.');
});
- file.addEventListener(IOErrorEvent.IO_ERROR, function(e:IOErrorEvent)
- {
+ file.addEventListener(IOErrorEvent.IO_ERROR, function(e:IOErrorEvent) {
trace('IO error writing file.');
});
file.save(data, path);
diff --git a/source/funkin/play/song/SongValidator.hx b/source/funkin/play/song/SongValidator.hx
index 950113bcf..d393c11eb 100644
--- a/source/funkin/play/song/SongValidator.hx
+++ b/source/funkin/play/song/SongValidator.hx
@@ -30,7 +30,7 @@ class SongValidator
/**
* Validates the fields of a SongMetadata object (excluding the version field).
- *
+ *
* @param input The SongMetadata object to validate.
* @param songId The ID of the song being validated. Only used for error messages.
* @return The validated SongMetadata object.
@@ -73,7 +73,7 @@ class SongValidator
/**
* Validates the fields of a SongPlayData object.
- *
+ *
* @param input The SongPlayData object to validate.
* @param songId The ID of the song being validated. Only used for error messages.
* @return The validated SongPlayData object.
@@ -85,7 +85,7 @@ class SongValidator
/**
* Validates the fields of a TimeChange object.
- *
+ *
* @param input The TimeChange object to validate.
* @param songId The ID of the song being validated. Only used for error messages.
* @return The validated TimeChange object.
@@ -113,7 +113,7 @@ class SongValidator
/**
* Validates the fields of a SongChartData object (excluding the version field).
- *
+ *
* @param input The SongChartData object to validate.
* @param songId The ID of the song being validated. Only used for error messages.
* @return The validated SongChartData object.
diff --git a/source/funkin/play/stage/Bopper.hx b/source/funkin/play/stage/Bopper.hx
index 9b5d1f314..26c3a0ff2 100644
--- a/source/funkin/play/stage/Bopper.hx
+++ b/source/funkin/play/stage/Bopper.hx
@@ -26,7 +26,7 @@ class Bopper extends StageProp implements IPlayStateScriptedClass
* Whether the bopper should dance left and right.
* - If true, alternate playing `danceLeft` and `danceRight`.
* - If false, play `idle` every time.
- *
+ *
* You can manually set this value, or you can leave it as `null` to determine it automatically.
*/
public var shouldAlternate:Null = null;
@@ -139,7 +139,7 @@ class Bopper extends StageProp implements IPlayStateScriptedClass
* @param name The name of the current animation.
* @param frameNumber The number of the current frame.
* @param frameIndex The index of the current frame.
- *
+ *
* For example, if an animation was defined as having the indexes [3, 0, 1, 2],
* then the first callback would have frameNumber = 0 and frameIndex = 3.
*/
@@ -223,7 +223,7 @@ class Bopper extends StageProp implements IPlayStateScriptedClass
/**
* Ensure that a given animation exists before playing it.
* Will gracefully check for name, then name with stripped suffixes, then 'idle', then fail to play.
- * @param name
+ * @param name
*/
function correctAnimationName(name:String):String
{
diff --git a/source/funkin/play/stage/Stage.hx b/source/funkin/play/stage/Stage.hx
index 71ba522c0..36d1600a6 100644
--- a/source/funkin/play/stage/Stage.hx
+++ b/source/funkin/play/stage/Stage.hx
@@ -19,7 +19,7 @@ typedef StagePropGroup = FlxTypedSpriteGroup;
/**
* A Stage is a group of objects rendered in the PlayState.
- *
+ *
* A Stage is comprised of one or more props, each of which is a FlxSprite.
*/
class Stage extends FlxSpriteGroup implements IPlayStateScriptedClass
@@ -39,8 +39,8 @@ class Stage extends FlxSpriteGroup implements IPlayStateScriptedClass
* The Stage elements get initialized at the beginning of the game.
* They're used to cache the data needed to build the stage,
* then accessed and fleshed out when the stage needs to be built.
- *
- * @param stageId
+ *
+ * @param stageId
*/
public function new(stageId:String)
{
@@ -543,7 +543,7 @@ class Stage extends FlxSpriteGroup implements IPlayStateScriptedClass
/**
* Retrieve a list of all the asset paths required to load the stage.
* Override this in a scripted class to ensure that all necessary assets are loaded!
- *
+ *
* @return An array of file names.
*/
public function fetchAssetPaths():Array
diff --git a/source/funkin/play/stage/StageData.hx b/source/funkin/play/stage/StageData.hx
index 002606c6d..6164c3cde 100644
--- a/source/funkin/play/stage/StageData.hx
+++ b/source/funkin/play/stage/StageData.hx
@@ -31,7 +31,7 @@ class StageDataParser
/**
* Parses and preloads the game's stage data and scripts when the game starts.
- *
+ *
* If you want to force stages to be reloaded, you can just call this function again.
*/
public static function loadStageCache():Void
@@ -68,8 +68,7 @@ class StageDataParser
// UNSCRIPTED STAGES
//
var stageIdList:Array = DataAssets.listDataFilesInPath('stages/');
- var unscriptedStageIds:Array = stageIdList.filter(function(stageId:String):Bool
- {
+ var unscriptedStageIds:Array = stageIdList.filter(function(stageId:String):Bool {
return !stageCache.exists(stageId);
});
trace(' Instantiating ${unscriptedStageIds.length} non-scripted stages...');
@@ -126,7 +125,7 @@ class StageDataParser
/**
* Load a stage's JSON file, parse its data, and return it.
- *
+ *
* @param stageId The stage to load.
* @return The stage data, or null if validation failed.
*/
@@ -199,8 +198,8 @@ class StageDataParser
/**
* Set unspecified parameters to their defaults.
* If the parameter is mandatory, print an error message.
- * @param id
- * @param input
+ * @param id
+ * @param input
* @return The validated stage data
*/
static function validateStageData(id:String, input:StageData):Null
@@ -461,7 +460,7 @@ typedef StageDataProp =
* If not zero, this prop will play an animation every X beats of the song.
* This requires animations to be defined. If `danceLeft` and `danceRight` are defined,
* they will alternated between, otherwise the `idle` animation will be used.
- *
+ *
* @default 0
*/
var danceEvery:Null;
diff --git a/source/funkin/play/stage/StageProp.hx b/source/funkin/play/stage/StageProp.hx
index 58de55293..4f67c5e4b 100644
--- a/source/funkin/play/stage/StageProp.hx
+++ b/source/funkin/play/stage/StageProp.hx
@@ -18,7 +18,7 @@ class StageProp extends FlxSprite implements IStateStageProp
/**
* Called when this prop is added to the stage.
- * @param event
+ * @param event
*/
public function onAdd(event:ScriptEvent):Void {}
diff --git a/source/funkin/shaderslmfao/AngleMask.hx b/source/funkin/shaderslmfao/AngleMask.hx
index 0fe279ad6..b9188201b 100644
--- a/source/funkin/shaderslmfao/AngleMask.hx
+++ b/source/funkin/shaderslmfao/AngleMask.hx
@@ -13,7 +13,7 @@ class AngleMask extends FlxShader
vec2 uv = openfl_TextureCoordv.xy;
-
+
vec2 start = vec2(0.0, 0.0);
vec2 end = vec2(endPosition.x / openfl_TextureSize.x, 1.0);
diff --git a/source/funkin/shaderslmfao/ColorSwap.hx b/source/funkin/shaderslmfao/ColorSwap.hx
index 684e48239..2c1f5664b 100644
--- a/source/funkin/shaderslmfao/ColorSwap.hx
+++ b/source/funkin/shaderslmfao/ColorSwap.hx
@@ -66,8 +66,8 @@ class ColorSwapShader extends FlxShader
const float offset = 1.0 / 128.0;
-
-
+
+
vec3 normalizeColor(vec3 color)
{
@@ -101,7 +101,7 @@ class ColorSwapShader extends FlxShader
vec4 color = flixel_texture2D(bitmap, openfl_TextureCoordv);
vec4 swagColor = vec4(rgb2hsv(vec3(color[0], color[1], color[2])), color[3]);
-
+
// [0] is the hue???
swagColor[0] += uTime;
// swagColor[1] += uTime;
@@ -109,7 +109,7 @@ class ColorSwapShader extends FlxShader
// money += swagColor[0];
color = vec4(hsv2rgb(vec3(swagColor[0], swagColor[1], swagColor[2])), swagColor[3]);
-
+
if (awesomeOutline)
{
@@ -119,7 +119,7 @@ class ColorSwapShader extends FlxShader
if (color.a <= 0.5) {
float w = size.x / openfl_TextureSize.x;
float h = size.y / openfl_TextureSize.y;
-
+
if (flixel_texture2D(bitmap, vec2(openfl_TextureCoordv.x + w, openfl_TextureCoordv.y)).a != 0.
|| flixel_texture2D(bitmap, vec2(openfl_TextureCoordv.x - w, openfl_TextureCoordv.y)).a != 0.
|| flixel_texture2D(bitmap, vec2(openfl_TextureCoordv.x, openfl_TextureCoordv.y + h)).a != 0.
@@ -130,12 +130,12 @@ class ColorSwapShader extends FlxShader
}
-
-
+
+
gl_FragColor = color;
-
-
- /*
+
+
+ /*
if (color.a > 0.5)
gl_FragColor = color;
else
diff --git a/source/funkin/shaderslmfao/OverlayBlend.hx b/source/funkin/shaderslmfao/OverlayBlend.hx
index 14a840451..8845a3b55 100644
--- a/source/funkin/shaderslmfao/OverlayBlend.hx
+++ b/source/funkin/shaderslmfao/OverlayBlend.hx
@@ -47,7 +47,7 @@ class OverlayBlend extends FlxShader
{
vec2 funnyUv = openfl_TextureCoordv;
vec4 color = flixel_texture2D(bitmap, funnyUv);
-
+
vec2 reallyFunnyUv = vec2(vec2(0.0, 0.0) - gl_FragCoord.xy / openfl_TextureSize.xy);
vec4 gf = flixel_texture2D(funnyShit, openfl_TextureCoordv.xy + vec2(0.1, 0.2));
diff --git a/source/funkin/shaderslmfao/ScreenWipeShader.hx b/source/funkin/shaderslmfao/ScreenWipeShader.hx
index 2ba035dc0..1aeb069ba 100644
--- a/source/funkin/shaderslmfao/ScreenWipeShader.hx
+++ b/source/funkin/shaderslmfao/ScreenWipeShader.hx
@@ -45,7 +45,7 @@ class ScreenWipeShader extends FlxShader
{
vec2 funnyUv = openfl_TextureCoordv;
vec4 color = flixel_texture2D(bitmap, funnyUv);
-
+
vec2 reallyFunnyUv = vec2(vec2(0.0, 0.0) - gl_FragCoord.xy / openfl_TextureSize.xy);
vec4 gf = flixel_texture2D(funnyShit, openfl_TextureCoordv);
diff --git a/source/funkin/shaderslmfao/StrokeShader.hx b/source/funkin/shaderslmfao/StrokeShader.hx
index d09b131a7..38dc41636 100644
--- a/source/funkin/shaderslmfao/StrokeShader.hx
+++ b/source/funkin/shaderslmfao/StrokeShader.hx
@@ -44,7 +44,7 @@ class StrokeShader extends FlxShader
if (sample.a == 0.) {
float w = size.x / openfl_TextureSize.x;
float h = size.y / openfl_TextureSize.y;
-
+
if (flixel_texture2D(bitmap, vec2(openfl_TextureCoordv.x + w, openfl_TextureCoordv.y)).a != 0.
|| flixel_texture2D(bitmap, vec2(openfl_TextureCoordv.x - w, openfl_TextureCoordv.y)).a != 0.
|| flixel_texture2D(bitmap, vec2(openfl_TextureCoordv.x, openfl_TextureCoordv.y + h)).a != 0.
diff --git a/source/funkin/shaderslmfao/TitleOutline.hx b/source/funkin/shaderslmfao/TitleOutline.hx
index c10fce8c3..9a849f795 100644
--- a/source/funkin/shaderslmfao/TitleOutline.hx
+++ b/source/funkin/shaderslmfao/TitleOutline.hx
@@ -50,7 +50,7 @@ class TitleOutline extends FlxShader
if (color.a == 0.0) {
float w = size.x / openfl_TextureSize.x;
float h = size.y / openfl_TextureSize.y;
-
+
vec4 colorOffset = flixel_texture2D(bitmap, vec2(openfl_TextureCoordv.x - w, openfl_TextureCoordv.y - h));
@@ -59,7 +59,7 @@ class TitleOutline extends FlxShader
if (hsvShit.b <= 0.1 && colorOffset.a != 0.)
color = vec4(0.0, 1.0, 0.8, color.a);
}
-
+
gl_FragColor = color;
}
diff --git a/source/funkin/ui/AtlasText.hx b/source/funkin/ui/AtlasText.hx
index 857587a7b..c311e387a 100644
--- a/source/funkin/ui/AtlasText.hx
+++ b/source/funkin/ui/AtlasText.hx
@@ -86,7 +86,7 @@ class AtlasText extends FlxTypedSpriteGroup
/**
* Converts all characters to fit the font's `allowedCase`.
- * @param text
+ * @param text
*/
function restrictCase(text:String)
{
diff --git a/source/funkin/ui/ControlsMenu.hx b/source/funkin/ui/ControlsMenu.hx
index c9292d39e..bd81cae5c 100644
--- a/source/funkin/ui/ControlsMenu.hx
+++ b/source/funkin/ui/ControlsMenu.hx
@@ -121,8 +121,7 @@ class ControlsMenu extends funkin.ui.OptionsState.Page
var margin = 100;
menuCamera.deadzone.set(0, margin, menuCamera.width, menuCamera.height - margin * 2);
menuCamera.minScrollY = 0;
- controlGrid.onChange.add(function(selected)
- {
+ controlGrid.onChange.add(function(selected) {
camFollow.y = selected.y;
labels.forEach((label) -> label.alpha = 0.6);
diff --git a/source/funkin/ui/MenuList.hx b/source/funkin/ui/MenuList.hx
index 61d44b960..39b53f998 100644
--- a/source/funkin/ui/MenuList.hx
+++ b/source/funkin/ui/MenuList.hx
@@ -121,9 +121,9 @@ class MenuTypedList extends FlxTypedGroup
/**
* Controls navigation on a linear list of items such as Vertical.
- * @param prev
- * @param next
- * @param allowWrap
+ * @param prev
+ * @param next
+ * @param allowWrap
*/
inline function navList(prev:Bool, next:Bool, allowWrap:Bool)
{
@@ -164,8 +164,7 @@ class MenuTypedList extends FlxTypedGroup
{
busy = true;
FlxG.sound.play(Paths.sound('confirmMenu'));
- FlxFlicker.flicker(selected, 1, 0.06, true, false, function(_)
- {
+ FlxFlicker.flicker(selected, 1, 0.06, true, false, function(_) {
busy = false;
selected.callback();
});
diff --git a/source/funkin/ui/NgPrompt.hx b/source/funkin/ui/NgPrompt.hx
index 9cb153fab..9a2a62940 100644
--- a/source/funkin/ui/NgPrompt.hx
+++ b/source/funkin/ui/NgPrompt.hx
@@ -36,14 +36,12 @@ class NgPrompt extends Prompt
#if web
prompt.buttons.getItem("yes").fireInstantly = true;
#end
- prompt.onYes = function()
- {
+ prompt.onYes = function() {
prompt.setText("Connecting..." #if web + "\n(check your popup blocker)" #end);
prompt.setButtons(None);
openPassportUrl();
};
- prompt.onNo = function()
- {
+ prompt.onNo = function() {
prompt.close();
prompt = null;
NGio.cancelLogin();
@@ -92,8 +90,7 @@ class NgPrompt extends Prompt
{
var user = io.newgrounds.NG.core.user.name;
var prompt = new NgPrompt('Log out of $user?', Yes_No);
- prompt.onYes = function()
- {
+ prompt.onYes = function() {
NGio.logout();
prompt.close();
};
diff --git a/source/funkin/ui/OptionsState.hx b/source/funkin/ui/OptionsState.hx
index 2b93e7222..291dafdf1 100644
--- a/source/funkin/ui/OptionsState.hx
+++ b/source/funkin/ui/OptionsState.hx
@@ -145,8 +145,7 @@ class Page extends FlxGroup
function openPrompt(prompt:Prompt, onClose:Void->Void)
{
enabled = false;
- prompt.closeCallback = function()
- {
+ prompt.closeCallback = function() {
enabled = true;
if (onClose != null) onClose();
}
@@ -217,16 +216,15 @@ class OptionsMenu extends Page
/**
* Calls openPrompt and redraws the login/logout button
- * @param prompt
- * @param onClose
+ * @param prompt
+ * @param onClose
*/
public function openNgPrompt(prompt:Prompt, ?onClose:Void->Void)
{
var onPromptClose = checkLoginStatus;
if (onClose != null)
{
- onPromptClose = function()
- {
+ onPromptClose = function() {
checkLoginStatus();
onClose();
}
diff --git a/source/funkin/ui/PopUpStuff.hx b/source/funkin/ui/PopUpStuff.hx
index 4bcdde138..c5828dd0a 100644
--- a/source/funkin/ui/PopUpStuff.hx
+++ b/source/funkin/ui/PopUpStuff.hx
@@ -55,8 +55,7 @@ class PopUpStuff extends FlxTypedGroup
FlxTween.tween(rating, {alpha: 0}, 0.2,
{
- onComplete: function(tween:FlxTween)
- {
+ onComplete: function(tween:FlxTween) {
remove(rating, true);
rating.destroy();
},
@@ -106,8 +105,7 @@ class PopUpStuff extends FlxTypedGroup
FlxTween.tween(comboSpr, {alpha: 0}, 0.2,
{
- onComplete: function(tween:FlxTween)
- {
+ onComplete: function(tween:FlxTween) {
remove(comboSpr, true);
comboSpr.destroy();
},
@@ -153,8 +151,7 @@ class PopUpStuff extends FlxTypedGroup
FlxTween.tween(numScore, {alpha: 0}, 0.2,
{
- onComplete: function(tween:FlxTween)
- {
+ onComplete: function(tween:FlxTween) {
remove(numScore, true);
numScore.destroy();
},
diff --git a/source/funkin/ui/PreferencesMenu.hx b/source/funkin/ui/PreferencesMenu.hx
index 1b6a6c6fd..0bf83c125 100644
--- a/source/funkin/ui/PreferencesMenu.hx
+++ b/source/funkin/ui/PreferencesMenu.hx
@@ -43,8 +43,7 @@ class PreferencesMenu extends Page
menuCamera.deadzone.set(0, margin, menuCamera.width, 40);
menuCamera.minScrollY = 0;
- items.onChange.add(function(selected)
- {
+ items.onChange.add(function(selected) {
camFollow.y = selected.y;
});
}
@@ -82,8 +81,7 @@ class PreferencesMenu extends Page
function createPrefItem(prefName:String, prefString:String, prefValue:Dynamic):Void
{
- items.createItem(120, (120 * items.length) + 30, prefName, AtlasFont.BOLD, function()
- {
+ items.createItem(120, (120 * items.length) + 30, prefName, AtlasFont.BOLD, function() {
preferenceCheck(prefString, prefValue);
switch (Type.typeof(prefValue).getName())
@@ -145,8 +143,7 @@ class PreferencesMenu extends Page
// menuCamera.followLerp = CoolUtil.camLerpShit(0.05);
- items.forEach(function(daItem:TextMenuItem)
- {
+ items.forEach(function(daItem:TextMenuItem) {
if (items.selectedItem == daItem) daItem.x = 150;
else
daItem.x = 120;
diff --git a/source/funkin/ui/animDebugShit/DebugBoundingState.hx b/source/funkin/ui/animDebugShit/DebugBoundingState.hx
index a21384e76..da7a4e3ff 100644
--- a/source/funkin/ui/animDebugShit/DebugBoundingState.hx
+++ b/source/funkin/ui/animDebugShit/DebugBoundingState.hx
@@ -44,7 +44,7 @@ import sys.io.File;
class DebugBoundingState extends FlxState
{
- /*
+ /*
TODAY'S TO-DO
- Cleaner UI
*/
diff --git a/source/funkin/ui/debug/charting/ChartEditorDialogHandler.hx b/source/funkin/ui/debug/charting/ChartEditorDialogHandler.hx
index 4240773e4..625119343 100644
--- a/source/funkin/ui/debug/charting/ChartEditorDialogHandler.hx
+++ b/source/funkin/ui/debug/charting/ChartEditorDialogHandler.hx
@@ -552,7 +552,7 @@ class ChartEditorDialogHandler
/**
* Builds and opens a dialog displaying the user guide, providing guidance and help on how to use the chart editor.
- *
+ *
* @param state The current chart editor state.
* @return The dialog that was opened.
*/
diff --git a/source/funkin/ui/debug/charting/ChartEditorState.hx b/source/funkin/ui/debug/charting/ChartEditorState.hx
index 4e050b19b..c61637536 100644
--- a/source/funkin/ui/debug/charting/ChartEditorState.hx
+++ b/source/funkin/ui/debug/charting/ChartEditorState.hx
@@ -58,7 +58,7 @@ using Lambda;
* Built with HaxeUI for use by both developers and modders.
*
* Some functionality is moved to other classes to help maintain my sanity.
- *
+ *
* @author MasterEric
*/
// Give other classes access to private instance fields
@@ -602,7 +602,7 @@ class ChartEditorState extends HaxeUIState
* A map of the audio tracks for each character's vocals.
* - Keys are the character IDs.
* - Values are the FlxSound objects to play that character's vocals.
- *
+ *
* When switching characters, the elements of the VoicesGroup will be swapped to match the new character.
*/
var audioVocalTracks:Map = new Map();
@@ -2945,7 +2945,7 @@ class ChartEditorState extends HaxeUIState
/**
* Loads an instrumental from an absolute file path, replacing the current instrumental.
- *
+ *
* @param path The absolute path to the audio file.
* @return Success or failure.
*/
@@ -3132,7 +3132,7 @@ class ChartEditorState extends HaxeUIState
/**
* Perform (or redo) a command, then add it to the undo stack.
- *
+ *
* @param command The command to perform.
* @param purgeRedoStack If true, the redo stack will be cleared.
*/
diff --git a/source/funkin/ui/debug/charting/ChartEditorToolboxHandler.hx b/source/funkin/ui/debug/charting/ChartEditorToolboxHandler.hx
index 8e21b3aeb..359cbb56e 100644
--- a/source/funkin/ui/debug/charting/ChartEditorToolboxHandler.hx
+++ b/source/funkin/ui/debug/charting/ChartEditorToolboxHandler.hx
@@ -133,8 +133,7 @@ class ChartEditorToolboxHandler
toolbox.x = 50;
toolbox.y = 50;
- toolbox.onDialogClosed = (event:DialogEvent) ->
- {
+ toolbox.onDialogClosed = (event:DialogEvent) -> {
state.setUICheckboxSelected('menubarItemToggleToolboxTools', false);
}
@@ -142,8 +141,7 @@ class ChartEditorToolboxHandler
if (toolsGroup == null) return null;
- toolsGroup.onChange = (event:UIEvent) ->
- {
+ toolsGroup.onChange = (event:UIEvent) -> {
switch (event.target.id)
{
case 'toolboxToolsGroupSelect':
@@ -168,8 +166,7 @@ class ChartEditorToolboxHandler
toolbox.x = 75;
toolbox.y = 100;
- toolbox.onDialogClosed = (event:DialogEvent) ->
- {
+ toolbox.onDialogClosed = (event:DialogEvent) -> {
state.setUICheckboxSelected('menubarItemToggleToolboxNotes', false);
}
@@ -177,8 +174,7 @@ class ChartEditorToolboxHandler
var toolboxNotesCustomKindLabel:Label = toolbox.findComponent("toolboxNotesCustomKindLabel", Label);
var toolboxNotesCustomKind:TextField = toolbox.findComponent("toolboxNotesCustomKind", TextField);
- toolboxNotesNoteKind.onChange = (event:UIEvent) ->
- {
+ toolboxNotesNoteKind.onChange = (event:UIEvent) -> {
var isCustom = (event.data.id == '~CUSTOM~');
if (isCustom)
@@ -197,8 +193,7 @@ class ChartEditorToolboxHandler
}
}
- toolboxNotesCustomKind.onChange = (event:UIEvent) ->
- {
+ toolboxNotesCustomKind.onChange = (event:UIEvent) -> {
state.selectedNoteKind = toolboxNotesCustomKind.text;
}
@@ -215,8 +210,7 @@ class ChartEditorToolboxHandler
toolbox.x = 100;
toolbox.y = 150;
- toolbox.onDialogClosed = (event:DialogEvent) ->
- {
+ toolbox.onDialogClosed = (event:DialogEvent) -> {
state.setUICheckboxSelected('menubarItemToggleToolboxEvents', false);
}
@@ -232,8 +226,7 @@ class ChartEditorToolboxHandler
toolboxEventsEventKind.dataSource.add({text: event.getTitle(), value: event.id});
}
- toolboxEventsEventKind.onChange = (event:UIEvent) ->
- {
+ toolboxEventsEventKind.onChange = (event:UIEvent) -> {
var eventType:String = event.data.value;
trace('ChartEditorToolboxHandler.buildToolboxEventDataLayout() - Event type changed: $eventType');
@@ -320,8 +313,7 @@ class ChartEditorToolboxHandler
target.addComponent(input);
- input.onChange = (event:UIEvent) ->
- {
+ input.onChange = (event:UIEvent) -> {
trace('ChartEditorToolboxHandler.buildEventDataFormFromSchema() - ${event.target.id} = ${event.target.value}');
if (event.target.value == null) state.selectedEventData.remove(event.target.id);
@@ -341,8 +333,7 @@ class ChartEditorToolboxHandler
toolbox.x = 125;
toolbox.y = 200;
- toolbox.onDialogClosed = (event:DialogEvent) ->
- {
+ toolbox.onDialogClosed = (event:DialogEvent) -> {
state.setUICheckboxSelected('menubarItemToggleToolboxDifficulty', false);
}
@@ -352,35 +343,28 @@ class ChartEditorToolboxHandler
var difficultyToolboxLoadMetadata:Button = toolbox.findComponent("difficultyToolboxLoadMetadata", Button);
var difficultyToolboxLoadChart:Button = toolbox.findComponent("difficultyToolboxLoadChart", Button);
- difficultyToolboxSaveMetadata.onClick = (event:UIEvent) ->
- {
+ difficultyToolboxSaveMetadata.onClick = (event:UIEvent) -> {
SongSerializer.exportSongMetadata(state.currentSongMetadata);
};
- difficultyToolboxSaveChart.onClick = (event:UIEvent) ->
- {
+ difficultyToolboxSaveChart.onClick = (event:UIEvent) -> {
SongSerializer.exportSongChartData(state.currentSongChartData);
};
- difficultyToolboxSaveAll.onClick = (event:UIEvent) ->
- {
+ difficultyToolboxSaveAll.onClick = (event:UIEvent) -> {
state.exportAllSongData();
};
- difficultyToolboxLoadMetadata.onClick = (event:UIEvent) ->
- {
+ difficultyToolboxLoadMetadata.onClick = (event:UIEvent) -> {
// Replace metadata for current variation.
- SongSerializer.importSongMetadataAsync(function(songMetadata)
- {
+ SongSerializer.importSongMetadataAsync(function(songMetadata) {
state.currentSongMetadata = songMetadata;
});
};
- difficultyToolboxLoadChart.onClick = (event:UIEvent) ->
- {
+ difficultyToolboxLoadChart.onClick = (event:UIEvent) -> {
// Replace chart data for current variation.
- SongSerializer.importSongChartDataAsync(function(songChartData)
- {
+ SongSerializer.importSongChartDataAsync(function(songChartData) {
state.currentSongChartData = songChartData;
state.noteDisplayDirty = true;
});
@@ -401,14 +385,12 @@ class ChartEditorToolboxHandler
toolbox.x = 150;
toolbox.y = 250;
- toolbox.onDialogClosed = (event:DialogEvent) ->
- {
+ toolbox.onDialogClosed = (event:DialogEvent) -> {
state.setUICheckboxSelected('menubarItemToggleToolboxMetadata', false);
}
var inputSongName:TextField = toolbox.findComponent('inputSongName', TextField);
- inputSongName.onChange = (event:UIEvent) ->
- {
+ inputSongName.onChange = (event:UIEvent) -> {
var valid = event.target.text != null && event.target.text != "";
if (valid)
@@ -423,8 +405,7 @@ class ChartEditorToolboxHandler
};
var inputSongArtist:TextField = toolbox.findComponent('inputSongArtist', TextField);
- inputSongArtist.onChange = (event:UIEvent) ->
- {
+ inputSongArtist.onChange = (event:UIEvent) -> {
var valid = event.target.text != null && event.target.text != "";
if (valid)
@@ -439,8 +420,7 @@ class ChartEditorToolboxHandler
};
var inputStage:DropDown = toolbox.findComponent('inputStage', DropDown);
- inputStage.onChange = (event:UIEvent) ->
- {
+ inputStage.onChange = (event:UIEvent) -> {
var valid = event.data != null && event.data.id != null;
if (valid)
@@ -450,15 +430,13 @@ class ChartEditorToolboxHandler
};
var inputNoteSkin:DropDown = toolbox.findComponent('inputNoteSkin', DropDown);
- inputNoteSkin.onChange = (event:UIEvent) ->
- {
+ inputNoteSkin.onChange = (event:UIEvent) -> {
if (event.data.id == null) return;
state.currentSongMetadata.playData.noteSkin = event.data.id;
};
var inputBPM:NumberStepper = toolbox.findComponent('inputBPM', NumberStepper);
- inputBPM.onChange = (event:UIEvent) ->
- {
+ inputBPM.onChange = (event:UIEvent) -> {
if (event.value == null || event.value <= 0) return;
var timeChanges = state.currentSongMetadata.timeChanges;
@@ -477,8 +455,7 @@ class ChartEditorToolboxHandler
};
var inputScrollSpeed:Slider = toolbox.findComponent('inputScrollSpeed', Slider);
- inputScrollSpeed.onChange = (event:UIEvent) ->
- {
+ inputScrollSpeed.onChange = (event:UIEvent) -> {
var valid = event.target.value != null && event.target.value > 0;
if (valid)
@@ -505,8 +482,7 @@ class ChartEditorToolboxHandler
toolbox.x = 175;
toolbox.y = 300;
- toolbox.onDialogClosed = (event:DialogEvent) ->
- {
+ toolbox.onDialogClosed = (event:DialogEvent) -> {
state.setUICheckboxSelected('menubarItemToggleToolboxCharacters', false);
}
@@ -523,8 +499,7 @@ class ChartEditorToolboxHandler
toolbox.x = 200;
toolbox.y = 350;
- toolbox.onDialogClosed = (event:DialogEvent) ->
- {
+ toolbox.onDialogClosed = (event:DialogEvent) -> {
state.setUICheckboxSelected('menubarItemToggleToolboxPlayerPreview', false);
}
@@ -548,8 +523,7 @@ class ChartEditorToolboxHandler
toolbox.x = 200;
toolbox.y = 350;
- toolbox.onDialogClosed = (event:DialogEvent) ->
- {
+ toolbox.onDialogClosed = (event:DialogEvent) -> {
state.setUICheckboxSelected('menubarItemToggleToolboxOpponentPreview', false);
}
diff --git a/source/funkin/ui/haxeui/components/CharacterPlayer.hx b/source/funkin/ui/haxeui/components/CharacterPlayer.hx
index c45aac35e..c6beca123 100644
--- a/source/funkin/ui/haxeui/components/CharacterPlayer.hx
+++ b/source/funkin/ui/haxeui/components/CharacterPlayer.hx
@@ -119,14 +119,12 @@ class CharacterPlayer extends Box
character.scale.x *= _scale;
character.scale.y *= _scale;
- character.animation.callback = function(name:String = "", frameNumber:Int = -1, frameIndex:Int = -1)
- {
+ character.animation.callback = function(name:String = "", frameNumber:Int = -1, frameIndex:Int = -1) {
@:privateAccess
character.onAnimationFrame(name, frameNumber, frameIndex);
dispatch(new AnimationEvent(AnimationEvent.FRAME));
};
- character.animation.finishCallback = function(name:String = "")
- {
+ character.animation.finishCallback = function(name:String = "") {
@:privateAccess
character.onAnimationFinished(name);
dispatch(new AnimationEvent(AnimationEvent.END));
diff --git a/source/funkin/ui/haxeui/components/Notifbar.hx b/source/funkin/ui/haxeui/components/Notifbar.hx
index bd08b4965..91ba16077 100644
--- a/source/funkin/ui/haxeui/components/Notifbar.hx
+++ b/source/funkin/ui/haxeui/components/Notifbar.hx
@@ -44,8 +44,7 @@ class Notifbar extends SideBar
this.action.text = actionText;
this.action.visible = true;
this.action.disabled = false;
- this.action.onClick = (_) ->
- {
+ this.action.onClick = (_) -> {
actionCallback();
};
}
@@ -98,8 +97,7 @@ class Notifbar extends SideBar
action = outerContainer.findComponent('notifbarAction', Button);
dismiss = outerContainer.findComponent('notifbarDismiss', Button);
- dismiss.onClick = (_) ->
- {
+ dismiss.onClick = (_) -> {
dismissNotification();
};
}
diff --git a/source/funkin/ui/stageBuildShit/SprStage.hx b/source/funkin/ui/stageBuildShit/SprStage.hx
index 681e6f10f..2229adfe9 100644
--- a/source/funkin/ui/stageBuildShit/SprStage.hx
+++ b/source/funkin/ui/stageBuildShit/SprStage.hx
@@ -18,11 +18,9 @@ class SprStage extends FlxSprite
{
super(x, y);
- FlxMouseEvent.add(this, dragShitFunc, null, function(spr:SprStage)
- {
+ FlxMouseEvent.add(this, dragShitFunc, null, function(spr:SprStage) {
if (isSelected() || StageBuilderState.curTool == SELECT) alpha = 0.5;
- }, function(spr:SprStage)
- {
+ }, function(spr:SprStage) {
alpha = 1;
}, false, true, true);
}
diff --git a/source/funkin/ui/stageBuildShit/StageBuilderState.hx b/source/funkin/ui/stageBuildShit/StageBuilderState.hx
index ad40a8657..de874e5ff 100644
--- a/source/funkin/ui/stageBuildShit/StageBuilderState.hx
+++ b/source/funkin/ui/stageBuildShit/StageBuilderState.hx
@@ -94,8 +94,7 @@ class StageBuilderState extends MusicBeatState
hudGrp.add(saveSceneBtn);
#if desktop
- FlxG.stage.window.onDropFile.add(function(path:String)
- {
+ FlxG.stage.window.onDropFile.add(function(path:String) {
trace("DROPPED FILE FROM: " + Std.string(path));
var fileName:String = path.split('\\').pop();
@@ -113,8 +112,7 @@ class StageBuilderState extends MusicBeatState
fo.write(sys.io.File.getBytes(path));
- new FlxTimer().start(0.2, function(tmr)
- {
+ new FlxTimer().start(0.2, function(tmr) {
var awesomeImg:SprStage = new SprStage(FlxG.mouse.x, FlxG.mouse.y, sprDragShitFunc);
awesomeImg.loadGraphic(Paths.image('stageBuild/stageTempImg'), false, 0, 0, true);
diff --git a/source/funkin/ui/stageBuildShit/StageOffsetSubstate.hx b/source/funkin/ui/stageBuildShit/StageOffsetSubstate.hx
index f6fd261c8..15140b2a7 100644
--- a/source/funkin/ui/stageBuildShit/StageOffsetSubstate.hx
+++ b/source/funkin/ui/stageBuildShit/StageOffsetSubstate.hx
@@ -23,7 +23,7 @@ import openfl.net.FileReference;
* Built with HaxeUI for use by both developers and modders.
*
* All functionality is kept within this file to ruin my own sanity.
- *
+ *
* @author ninjamuffin99
*/
// Give other classes access to private instance fields
diff --git a/source/funkin/ui/story/StoryMenuState.hx b/source/funkin/ui/story/StoryMenuState.hx
index 8a856baf6..18c791995 100644
--- a/source/funkin/ui/story/StoryMenuState.hx
+++ b/source/funkin/ui/story/StoryMenuState.hx
@@ -390,7 +390,7 @@ class StoryMenuState extends MusicBeatState
/**
* Changes the selected difficulty.
- * @param change +1 (right) to increase difficulty, -1 (left) to decrease difficulty
+ * @param change +1 (right) to increase difficulty, -1 (left) to decrease difficulty
*/
function changeDifficulty(change:Int = 0):Void
{
diff --git a/source/funkin/util/FileUtil.hx b/source/funkin/util/FileUtil.hx
index c30eacba8..57dc7b12e 100644
--- a/source/funkin/util/FileUtil.hx
+++ b/source/funkin/util/FileUtil.hx
@@ -18,7 +18,7 @@ class FileUtil
/**
* Browses for a single file, then calls `onSelect(path)` when a path chosen.
* Note that on HTML5 this will immediately fail, you should call `openFile(onOpen:Resource->Void)` instead.
- *
+ *
* @param typeFilter Filters what kinds of files can be selected.
* @return Whether the file dialog was opened successfully.
*/
@@ -46,7 +46,7 @@ class FileUtil
/**
* Browses for a directory, then calls `onSelect(path)` when a path chosen.
* Note that on HTML5 this will immediately fail.
- *
+ *
* @param typeFilter TODO What does this do?
* @return Whether the file dialog was opened successfully.
*/
@@ -74,7 +74,7 @@ class FileUtil
/**
* Browses for multiple file, then calls `onSelect(paths)` when a path chosen.
* Note that on HTML5 this will immediately fail.
- *
+ *
* @return Whether the file dialog was opened successfully.
*/
public static function browseForMultipleFiles(?typeFilter:Array, ?onSelect:Array->Void, ?onCancel:Void->Void, ?defaultPath:String,
@@ -101,7 +101,7 @@ class FileUtil
/**
* Browses for a file location to save to, then calls `onSelect(path)` when a path chosen.
* Note that on HTML5 you can't do much with this, you should call `saveFile(resource:haxe.io.Bytes)` instead.
- *
+ *
* @param typeFilter TODO What does this do?
* @return Whether the file dialog was opened successfully.
*/
@@ -129,7 +129,7 @@ class FileUtil
/**
* Browses for a single file location, then reads it and passes it to `onOpen(resource:haxe.io.Bytes)`.
* Works great on desktop and HTML5.
- *
+ *
* @param typeFilter TODO What does this do?
* @return Whether the file dialog was opened successfully.
*/
@@ -171,7 +171,7 @@ class FileUtil
/**
* Browses for a single file location, then writes the provided `haxe.io.Bytes` data and calls `onSave(path)` when done.
* Works great on desktop and HTML5.
- *
+ *
* @return Whether the file dialog was opened successfully.
*/
public static function saveFile(data:Bytes, ?onSave:String->Void, ?onCancel:Void->Void, ?defaultFileName:String, ?dialogTitle:String):Bool
@@ -204,7 +204,7 @@ class FileUtil
* Prompts the user to save multiple files.
* On desktop, this will prompt the user for a directory, then write all of the files to there.
* On HTML5, this will zip the files up and prompt the user to save that.
- *
+ *
* @param typeFilter TODO What does this do?
* @return Whether the file dialog was opened successfully.
*/
@@ -296,7 +296,7 @@ class FileUtil
/**
* Write string file contents directly to a given path.
* Only works on desktop.
- *
+ *
* @param mode Whether to Force, Skip, or Ask to overwrite an existing file.
*/
public static function writeStringToPath(path:String, data:String, mode:FileWriteMode = Skip)
@@ -335,7 +335,7 @@ class FileUtil
/**
* Write byte file contents directly to a given path.
* Only works on desktop.
- *
+ *
* @param mode Whether to Force, Skip, or Ask to overwrite an existing file.
*/
public static function writeBytesToPath(path:String, data:Bytes, mode:FileWriteMode = Skip)
@@ -432,7 +432,7 @@ class FileUtil
/**
* Create a Bytes object containing a ZIP file, containing the provided entries.
- *
+ *
* @param entries The entries to add to the ZIP file.
* @return The ZIP file as a Bytes object.
*/
@@ -448,7 +448,7 @@ class FileUtil
/**
* Create a ZIP file entry from a file name and its string contents.
- *
+ *
* @param name The name of the file. You can use slashes to create subdirectories.
* @param content The string contents of the file.
* @return The resulting entry.
diff --git a/source/funkin/util/SerializerUtil.hx b/source/funkin/util/SerializerUtil.hx
index 3b77a04e5..662c05250 100644
--- a/source/funkin/util/SerializerUtil.hx
+++ b/source/funkin/util/SerializerUtil.hx
@@ -24,7 +24,7 @@ class SerializerUtil
}
/**
- * Convert a JSON string to a Haxe object of the chosen type.
+ * Convert a JSON string to a Haxe object of the chosen type.
*/
public static function fromJSONTyped(input:String, type:Class):T
{
diff --git a/source/funkin/util/SortUtil.hx b/source/funkin/util/SortUtil.hx
index e10f6dd55..60b522744 100644
--- a/source/funkin/util/SortUtil.hx
+++ b/source/funkin/util/SortUtil.hx
@@ -19,7 +19,7 @@ class SortUtil
/**
* Given two Notes, returns 1 or -1 based on whether `a` or `b` has an earlier strumtime.
- *
+ *
* @param order Either `FlxSort.ASCENDING` or `FlxSort.DESCENDING`
*/
public static inline function byStrumtime(order:Int, a:Note, b:Note)
diff --git a/source/funkin/util/macro/ClassMacro.hx b/source/funkin/util/macro/ClassMacro.hx
index 591a5f0e1..43b437dda 100644
--- a/source/funkin/util/macro/ClassMacro.hx
+++ b/source/funkin/util/macro/ClassMacro.hx
@@ -7,7 +7,7 @@ import funkin.util.macro.MacroUtil;
/**
* Macros to generate lists of classes at compile time.
- *
+ *
* This code is a bitch glad Jason figured it out.
* Based on code from CompileTime: https://github.com/jasononeil/compiletime
*/
@@ -15,9 +15,9 @@ class ClassMacro
{
/**
* Gets a list of `Class` for all classes in a specified package.
- *
+ *
* Example: `var list:Array> = listClassesInPackage("funkin", true);`
- *
+ *
* @param targetPackage A String containing the package name to query.
* @param includeSubPackages Whether to include classes located in sub-packages of the target package.
* @return A list of classes matching the specified criteria.
@@ -39,9 +39,9 @@ class ClassMacro
/**
* Get a list of `Class` for all classes extending a specified class.
- *
+ *
* Example: `var list:Array> = listSubclassesOf(FlxSprite);`
- *
+ *
* @param targetClass The class to query for subclasses.
* @return A list of classes matching the specified criteria.
*/
@@ -68,7 +68,7 @@ class ClassMacro
/**
* Callback executed after the typing phase but before the generation phase.
* Receives a list of `haxe.macro.Type` for all types in the program.
- *
+ *
* Only metadata can be modified at this time, which makes it a BITCH to access the data at runtime.
*/
static function onGenerate(allTypes:Array)
diff --git a/source/funkin/util/macro/FlxMacro.hx b/source/funkin/util/macro/FlxMacro.hx
index 313b2561a..0c1a5fa78 100644
--- a/source/funkin/util/macro/FlxMacro.hx
+++ b/source/funkin/util/macro/FlxMacro.hx
@@ -24,7 +24,7 @@ class FlxMacro
{
name: "zIndex", // Field name.
access: [haxe.macro.Expr.Access.APublic], // Access level
- kind: haxe.macro.Expr.FieldType.FVar(macro:Int, macro $v{0}), // Variable type and default value
+ kind: haxe.macro.Expr.FieldType.FVar(macro :Int, macro $v{0}), // Variable type and default value
pos: pos, // The field's position in code.
}
]);
diff --git a/source/funkin/util/macro/MacroUtil.hx b/source/funkin/util/macro/MacroUtil.hx
index e0f06c866..a121200ca 100644
--- a/source/funkin/util/macro/MacroUtil.hx
+++ b/source/funkin/util/macro/MacroUtil.hx
@@ -8,7 +8,7 @@ class MacroUtil
{
/**
* Gets the value of a Haxe compiler define.
- *
+ *
* @param key The name of the define to get the value of.
* @param defaultValue The value to return if the define is not set.
* @return An expression containing the value of the define.
diff --git a/source/funkin/util/tools/IteratorTools.hx b/source/funkin/util/tools/IteratorTools.hx
index 261f101e4..9279c1227 100644
--- a/source/funkin/util/tools/IteratorTools.hx
+++ b/source/funkin/util/tools/IteratorTools.hx
@@ -2,9 +2,9 @@ package funkin.util.tools;
/**
* A static extension which provides utility functions for Iterators.
- *
+ *
* For example, add `using IteratorTools` then call `iterator.array()`.
- *
+ *
* @see https://haxe.org/manual/lf-static-extension.html
*/
class IteratorTools
diff --git a/source/funkin/util/tools/MapTools.hx b/source/funkin/util/tools/MapTools.hx
index 430b7bc81..461b88bbf 100644
--- a/source/funkin/util/tools/MapTools.hx
+++ b/source/funkin/util/tools/MapTools.hx
@@ -2,9 +2,9 @@ package funkin.util.tools;
/**
* A static extension which provides utility functions for Maps.
- *
+ *
* For example, add `using MapTools` then call `map.values()`.
- *
+ *
* @see https://haxe.org/manual/lf-static-extension.html
*/
class MapTools
diff --git a/source/funkin/util/tools/StringTools.hx b/source/funkin/util/tools/StringTools.hx
index 7ecddd0d9..8ff76a080 100644
--- a/source/funkin/util/tools/StringTools.hx
+++ b/source/funkin/util/tools/StringTools.hx
@@ -7,7 +7,7 @@ class StringTools
{
/**
* Converts a string to title case. For example, "hello world" becomes "Hello World".
- *
+ *
* @param value The string to convert.
* @return The converted string.
*/
@@ -29,7 +29,7 @@ class StringTools
/**
* Converts a string to lower kebab case. For example, "Hello World" becomes "hello-world".
- *
+ *
* @param value The string to convert.
* @return The converted string.
*/
@@ -40,7 +40,7 @@ class StringTools
/**
* Converts a string to upper kebab case, aka screaming kebab case. For example, "Hello World" becomes "HELLO-WORLD".
- *
+ *
* @param value The string to convert.
* @return The converted string.
*/
@@ -51,7 +51,7 @@ class StringTools
/**
* Parses the string data as JSON and returns the resulting object.
- *
+ *
* @return The parsed object.
*/
public static function parseJSON(value:String):Dynamic
diff --git a/source/module.xml b/source/module.xml
index dd7c9ad20..c3437d993 100644
--- a/source/module.xml
+++ b/source/module.xml
@@ -1,4 +1,4 @@
-
+
@@ -14,8 +14,7 @@
-
-
\ No newline at end of file
+