mirror of
https://github.com/FunkinCrew/Funkin.git
synced 2024-11-23 16:17:53 -05:00
commit
e45446bbe4
2 changed files with 13 additions and 5 deletions
|
@ -24,7 +24,7 @@ import ui.Prompt;
|
||||||
|
|
||||||
using StringTools;
|
using StringTools;
|
||||||
|
|
||||||
#if desktop
|
#if discord_rpc
|
||||||
import Discord.DiscordClient;
|
import Discord.DiscordClient;
|
||||||
#end
|
#end
|
||||||
#if newgrounds
|
#if newgrounds
|
||||||
|
|
|
@ -83,6 +83,7 @@ class ModMenu extends ui.OptionsState.Page
|
||||||
organizeByY();
|
organizeByY();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
inline static var MOD_PATH = "./mods";
|
||||||
private function refreshModList():Void
|
private function refreshModList():Void
|
||||||
{
|
{
|
||||||
while (grpMods.members.length > 0)
|
while (grpMods.members.length > 0)
|
||||||
|
@ -93,16 +94,23 @@ class ModMenu extends ui.OptionsState.Page
|
||||||
#if desktop
|
#if desktop
|
||||||
var modList = [];
|
var modList = [];
|
||||||
modFolders = [];
|
modFolders = [];
|
||||||
|
|
||||||
for (file in FileSystem.readDirectory('./mods'))
|
trace("mods path:" + FileSystem.absolutePath(MOD_PATH));
|
||||||
|
if (!FileSystem.exists(MOD_PATH))
|
||||||
{
|
{
|
||||||
if (FileSystem.isDirectory('./mods/' + file))
|
FlxG.log.warn("missing mods folder, expected: " + FileSystem.absolutePath(MOD_PATH));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
for (file in FileSystem.readDirectory(MOD_PATH))
|
||||||
|
{
|
||||||
|
if (FileSystem.isDirectory(MOD_PATH + file))
|
||||||
modFolders.push(file);
|
modFolders.push(file);
|
||||||
}
|
}
|
||||||
|
|
||||||
enabledMods = [];
|
enabledMods = [];
|
||||||
|
|
||||||
modList = Polymod.scan('./mods');
|
modList = Polymod.scan(MOD_PATH);
|
||||||
|
|
||||||
trace(modList);
|
trace(modList);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue