That's a good question actually. I'm assuming you have linked all the DLL files, I'd imagine they would be buried in some kind of xml file somewhere which I "believe" is read by these DLLs? Is that fair to assume that?
Also, in the documentation, Step 4: Setup an override for the OnSubModuleLoad() inherited method.
Now, I'm not too cluey with code, and I'm doing my darndest to learn on the fly (Inheriting the MBSubModuleBase was I'm assuming the base class for the MySubModule class, so I.E class MySubModule : MBSubModuleBase), but I'm stuck on the next step, 4. Is the Override function being written straight into the MySubModule class as a public override method? What is it's return type and what method are we actually overriding?
Or is OnSubModuleLoad() the method the actual method in our class we are overriding? And from what? Man I feel like a complete dunce sometimes with coding.
This is what I've got so far but I'm getting an error saying: The modifier 'override' is not valid for this item and that the method must have a return type. This is my code:
using TaleWorlds.Core;
using TaleWorlds.Localization;
using TaleWorlds.MountAndBlade;
namespace MyMod
{
class MySubModule : MBSubModuleBase
{
public override OnSubModuleLoad()
{
Module.CurrentModule.AddInitialStateOption(new InitialStateOption("Message",
new TextObject("Message", null),
9990,
() => { InformationManager.DisplayMessage(new InformationMessage("Hello World")); },
false));
}
}
}