Codename LogoCodename Logo

funkin.backend.assets.ModsFolder

APIWiki

Static variables

View in GitHub

@:value("./addons/")staticaddonsPath:String = "./addons/"

Path to the addons folder.

View in GitHub

@:value(null)staticcurrentModFolder:String = null

Current mod folder. Will affect Paths.

View in GitHub

@:value("./mods/")staticmodsPath:String = "./mods/"

Path to the mods folder.

View in GitHub

@:value(true)staticuseLibFile:Bool = true

If accessing a file as assets/data/global/LIB_mymod.hx should redirect to mymod:assets/data/global.hx

Static methods

View in GitHub

staticgetLoadedMods():Array<String>

View in GitHub

staticgetModsList():Array<String>

View in GitHub

staticinit():Void

Initialises mods folder.

View in GitHub

@:value({ force : false })staticloadLibraryFromFolder(libName:String, folder:String, force:Bool = false, ?modName:String):AssetLibrary

View in GitHub

@:value({ force : false })staticloadLibraryFromZip(libName:String, zipPath:String, force:Bool = false, ?modName:String):AssetLibrary

View in GitHub

@:value({ force : false })staticloadModLib(path:String, force:Bool = false, ?modName:String):AssetLibrary

Loads a mod library from the specified path. Supports folders and zips.

Parameters:

modName

Name of the mod

force

Whenever the mod should be reloaded if it has already been loaded

View in GitHub

@:value({ force : false })staticprepareLibrary(libName:String, force:Bool = false):AssetLibrary

View in GitHub

@:value({ force : false })staticprepareModLibrary(libName:String, lib:IModsAssetLibrary, force:Bool = false):AssetLibrary

View in GitHub

staticregisterFont(font:Font):Font

View in GitHub

staticswitchMod(mod:String):Void

Switches mod - unloads all the other mods, then load this one.

Parameters:

null

libName