Module GameMod¶
local GameMod = require "necro.game.data.resource.GameMod"
Enumerations¶
GameMod.AssetType¶
| Key | Value | Description |
|---|---|---|
GameMod.AssetType.TILESET_ZONE_1 |
1 | |
GameMod.AssetType.CLONE_SPRITE |
10 | |
GameMod.AssetType.FOLLOWER_SPRITE |
11 | |
GameMod.AssetType.ARTWORK |
12 | |
GameMod.AssetType.VARIANT_SPRITE |
13 | |
GameMod.AssetType.ATTACHMENT |
14 | |
GameMod.AssetType.SWIPE |
15 | |
GameMod.AssetType.PARTICLE |
16 | |
GameMod.AssetType.SPELL |
17 | |
GameMod.AssetType.SOUND |
18 | |
GameMod.AssetType.VOICE |
19 | |
GameMod.AssetType.TILESET_ZONE_2 |
2 | |
GameMod.AssetType.BEATMAP |
20 | |
GameMod.AssetType.SONG |
21 | |
GameMod.AssetType.VOCALS |
22 | |
GameMod.AssetType.VOCALS_2 |
23 | |
GameMod.AssetType.VOCALS_DAOUST |
24 | |
GameMod.AssetType.XML |
25 | |
GameMod.AssetType.OTHER |
26 | |
GameMod.AssetType.TILESET_ZONE_3_HOT |
3 | |
GameMod.AssetType.TILESET_ZONE_3_COLD |
4 | |
GameMod.AssetType.TILESET_ZONE_4 |
5 | |
GameMod.AssetType.TILESET_ZONE_5 |
6 | |
GameMod.AssetType.TILESET_BOSS |
7 | |
GameMod.AssetType.SPRITE |
8 | |
GameMod.AssetType.HEAD_SPRITE |
9 |
GameMod.AssetCategory¶
| Key | Value | Description |
|---|---|---|
GameMod.AssetCategory.PLAYER_CHARACTER |
1 | |
GameMod.AssetCategory.SOUND |
10 | |
GameMod.AssetCategory.MUSIC |
11 | |
GameMod.AssetCategory.BEATMAP |
12 | |
GameMod.AssetCategory.OTHER |
13 | |
GameMod.AssetCategory.ITEM |
2 | |
GameMod.AssetCategory.ENEMY |
3 | |
GameMod.AssetCategory.OBJECT |
4 | |
GameMod.AssetCategory.TILE |
5 | |
GameMod.AssetCategory.VISUAL_EFFECT |
6 | |
GameMod.AssetCategory.HUD |
7 | |
GameMod.AssetCategory.UI |
8 | |
GameMod.AssetCategory.IMAGE |
9 |
Functions¶
GameMod.getModDisplayName(modName)¶
GameMod.listAvailableAssetMods()¶
GameMod.listLoadedAssetMods()¶
GameMod.getAssetModName(name)¶
GameMod.getAssetModPath(name)¶
GameMod.getModGridMenuEntry()¶
GameMod.isModLoaded(name)¶
GameMod.isPermissive(): boolean¶
Checks if the current session uses permissive content guidelines for mods. This can be used to limit certain types of modded content to PC-only sessions without having to split the mod into two branches.
- On PC, returns
truein single-player sessions or non-cross-play multiplayer sessions, andfalseduring multiplayer sessions that can be joined by console players. - On console, always returns
false.
This function can be safely called at load time, and is guaranteed to be synchronized in regular multiplayer.
Non-deterministic cases may arise when by viewing a PC replay on console. However, as non-Weekly leaderboard replays do not contain mods, and the base game does not alter gameplay behavior based on permissiveness, no desyncs should occur due to this. Weekly Challenge runs never load the Permissive mod in the first place.
GameMod.isModAvailable(name)¶
GameMod.isModdedSession()¶
GameMod.resolvePatch(version): string|boolean¶
Checks if our client can load the specified patch, and returns the version number needed to do so.
Parameters
| Type | Name | Description |
|---|---|---|
| string | version | Full version string (optionally with "v" prefix and build number suffix) |
GameMod.getPatchVersion(): string¶
Returns the currently loaded patch version number