I tried coding my own mod, but my template doesn't even work (I'm just trying to see an option for my mod in the Appbar):
public override void OnInitialized()
{
...
// Create the window
var myFirstWindow = Window.Create(windowOptions, myFirstWindowUxml);
// Add a controller for the UI to the window's game object
var myFirstWindowController = myFirstWindow.gameObject.AddComponent<MyFirstWindowController>();
// Register Flight AppBar button
Appbar.RegisterAppButton(
ModName,
ToolbarFlightButtonID,
AssetManager.GetAsset<Texture2D>($"{ModGuid}/images/icon.png"),
isOpen => myFirstWindowController.IsWindowOpen = isOpen
);
// Register OAB AppBar Button
Appbar.RegisterOABAppButton(
ModName,
ToolbarOabButtonID,
AssetManager.GetAsset<Texture2D>($"{ModGuid}/images/icon.png"),
isOpen => myFirstWindowController.IsWindowOpen = isOpen
);
// Register KSC AppBar Button
Appbar.RegisterKSCAppButton(
ModName,
ToolbarKscButtonID,
AssetManager.GetAsset<Texture2D>($"{ModGuid}/images/icon.png"),
() => myFirstWindowController.IsWindowOpen = !myFirstWindowController.IsWindowOpen
);
}
However it's displayed as active in the mods menu. Is there some way I can debug stuff or does someone see the issue by any chance?