Table of Contents

Class CustomKnight

Namespace
CustomKnight
Assembly
CustomKnight.dll

Main Mod Class

public class CustomKnight : Mod, IGlobalSettings<GlobalModSettings>, ILocalSettings<SaveModSettings>, ICustomMenuMod, ITogglableMod, IMod, ILogger
Inheritance
Loggable
Mod
CustomKnight
Implements
IGlobalSettings<GlobalModSettings>
ILocalSettings<SaveModSettings>
ICustomMenuMod
ITogglableMod
IMod
ILogger
Inherited Members
Mod.Name
Mod.PreloadSceneHooks()
Mod.LoadPriority()
Mod.Initialize()
Mod.GetMenuButtonText()
Mod.SaveGlobalSettings()

Constructors

CustomKnight()

ctor

public CustomKnight()

Fields

GameObjects

Stores Preloaded gameobjects

public static readonly Dictionary<string, GameObject> GameObjects

Field Value

Dictionary<string, GameObject>

Properties

GlobalSettings

GlobalSettings

public static GlobalModSettings GlobalSettings { get; set; }

Property Value

GlobalModSettings

Instance

Current Mod instance

public static CustomKnight Instance { get; }

Property Value

CustomKnight

SaveSettings

Settings for current save

public static SaveModSettings SaveSettings { get; set; }

Property Value

SaveModSettings

ToggleButtonInsideMenu

ToggleButtonInsideMenu

public bool ToggleButtonInsideMenu { get; }

Property Value

bool

dumpManager

Current DumpManager instance

public static DumpManager dumpManager { get; }

Property Value

DumpManager

swapManager

Current SwapManager instance

public static SwapManager swapManager { get; }

Property Value

SwapManager

Methods

GetMenuScreen(MenuScreen, ModToggleDelegates?)

GetMenuScreen

public MenuScreen GetMenuScreen(MenuScreen modListMenu, ModToggleDelegates? toggle)

Parameters

modListMenu MenuScreen
toggle ModToggleDelegates?

Returns

MenuScreen

GetName()

GetName

public string GetName()

Returns

string

GetPreloadNames()

GetPreloadNames

public override List<(string, string)> GetPreloadNames()

Returns

List<(string, string)>

GetVersion()

GetVersion

public override string GetVersion()

Returns

string

Initialize(Dictionary<string, Dictionary<string, GameObject>>)

Initialize

public override void Initialize(Dictionary<string, Dictionary<string, GameObject>> preloadedObjects)

Parameters

preloadedObjects Dictionary<string, Dictionary<string, GameObject>>

OnLoadGlobal(GlobalModSettings)

OnLoadGlobal

public void OnLoadGlobal(GlobalModSettings s)

Parameters

s GlobalModSettings

OnLoadLocal(SaveModSettings)

OnLoadLocal

public void OnLoadLocal(SaveModSettings s)

Parameters

s SaveModSettings

OnSaveGlobal()

OnSaveGlobal

public GlobalModSettings OnSaveGlobal()

Returns

GlobalModSettings

OnSaveLocal()

OnSaveLocal

public SaveModSettings OnSaveLocal()

Returns

SaveModSettings

Unload()

Unload

public void Unload()

Events

OnInit

Event called when CK is initialised but before applying skin

public static event EventHandler<EventArgs> OnInit

Event Type

EventHandler<EventArgs>

OnReady

Event called when CK is fully ready (after applying a skin)

public static event EventHandler<EventArgs> OnReady

Event Type

EventHandler<EventArgs>

OnUnload

Event called when the mod is unloaded

public static event EventHandler<EventArgs> OnUnload

Event Type

EventHandler<EventArgs>