Skip to content

Commit

Permalink
Switch to SpaceWarp 1.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Falki-git committed May 26, 2023
1 parent 10f19f7 commit c0f6293
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 21 deletions.
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2023 Micrologist
Copyright (c) 2023 Micrologist, Falki-git

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
13 changes: 8 additions & 5 deletions MicroEngineerProject/MicroEngineer/MicroEngineerMod.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,18 @@

namespace MicroMod
{
[BepInPlugin("com.micrologist.microengineer", "MicroEngineer", "1.0.3")]
[BepInDependency(SpaceWarpPlugin.ModGuid, SpaceWarpPlugin.ModVer)]
public class MicroEngineerMod : BaseSpaceWarpPlugin
//[BepInPlugin(MyPluginInfo.PLUGIN_GUID, MyPluginInfo.PLUGIN_NAME, MyPluginInfo.PLUGIN_VERSION)]
[BepInPlugin("com.micrologist.microengineer", "MicroEngineer", "1.1.0")]
[BepInDependency(SpaceWarpPlugin.ModGuid, SpaceWarpPlugin.ModVer)]
public class MicroEngineerMod : BaseSpaceWarpPlugin
{
public static MicroEngineerMod Instance { get; set; }
public string GUID;

public override void OnInitialized()
{
Instance = this;
GUID = Info.Metadata.GUID;

Styles.Initialize();

Expand All @@ -28,7 +31,7 @@ public override void OnInitialized()
Appbar.RegisterAppButton(
"Micro Engineer",
"BTN-MicroEngineerBtn",
AssetManager.GetAsset<Texture2D>($"{SpaceWarpMetadata.ModID}/images/icon.png"),
AssetManager.GetAsset<Texture2D>($"{GUID}/images/icon.png"),
isOpen =>
{
UI.Instance.ShowGuiFlight = isOpen;
Expand All @@ -39,7 +42,7 @@ public override void OnInitialized()
Appbar.RegisterOABAppButton(
"Micro Engineer",
"BTN-MicroEngineerOAB",
AssetManager.GetAsset<Texture2D>($"{SpaceWarpMetadata.ModID}/images/icon.png"),
AssetManager.GetAsset<Texture2D>($"{GUID}/images/icon.png"),
isOpen =>
{
UI.Instance.ShowGuiOAB = isOpen;
Expand Down
30 changes: 15 additions & 15 deletions MicroEngineerProject/MicroEngineer/Utilities/Styles.cs
Original file line number Diff line number Diff line change
Expand Up @@ -367,25 +367,25 @@ private static void InitializeTextures()
{
// Icons from https://icons8.com

Settings20Texture = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/settings-20.png");
Settings15Texture = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/settings-15.png");
CloseButtonTexture = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/close-15.png");
PopoutTexture = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/popout-15.png");
Settings20Texture = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/settings-20.png");
Settings15Texture = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/settings-15.png");
CloseButtonTexture = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/close-15.png");
PopoutTexture = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/popout-15.png");

EntryBackgroundTexture_WhiteTheme_First = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/background_white_first.png");
EntryBackgroundTexture_WhiteTheme_Middle = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/background_white_middle.png");
EntryBackgroundTexture_WhiteTheme_Last = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/background_white_last.png");
EntryBackgroundTexture_WhiteTheme_First = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/background_white_first.png");
EntryBackgroundTexture_WhiteTheme_Middle = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/background_white_middle.png");
EntryBackgroundTexture_WhiteTheme_Last = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/background_white_last.png");

EntryBackgroundTexture_GrayTheme_First = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/background_darkgray_first.png");
EntryBackgroundTexture_GrayTheme_Middle = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/background_darkgray_middle.png");
EntryBackgroundTexture_GrayTheme_Last = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/background_darkgray_last.png");
EntryBackgroundTexture_GrayTheme_First = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/background_darkgray_first.png");
EntryBackgroundTexture_GrayTheme_Middle = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/background_darkgray_middle.png");
EntryBackgroundTexture_GrayTheme_Last = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/background_darkgray_last.png");

EntryBackgroundTexture_BlackTheme_First = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/background_black_first.png");
EntryBackgroundTexture_BlackTheme_Middle = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/background_black_middle.png");
EntryBackgroundTexture_BlackTheme_Last = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/background_black_last.png");
EntryBackgroundTexture_BlackTheme_First = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/background_black_first.png");
EntryBackgroundTexture_BlackTheme_Middle = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/background_black_middle.png");
EntryBackgroundTexture_BlackTheme_Last = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/background_black_last.png");

IncreaseDecimalDigitsTexture = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/increase-decimal-19.png");
DecreaseDecimalDigitsTexture = LoadTexture($"{MicroEngineerMod.Instance.SpaceWarpMetadata.ModID}/images/decrease-decimal-19.png");
IncreaseDecimalDigitsTexture = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/increase-decimal-19.png");
DecreaseDecimalDigitsTexture = LoadTexture($"{MicroEngineerMod.Instance.GUID}/images/decrease-decimal-19.png");
}

private static Texture2D LoadTexture(string path)
Expand Down

0 comments on commit c0f6293

Please sign in to comment.