Skip to content

Commit be09888

Browse files
committed
General cleaning
1 parent 369223f commit be09888

File tree

21 files changed

+133
-146
lines changed

21 files changed

+133
-146
lines changed

EnableFullScreenToggleIL2CPP_netFm/EnableFullScreenToggleIL2CPP_netFm.cs

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,38 @@
1-
using BepInEx;
1+
using System;
22
using BepInEx.IL2CPP;
3-
using System;
43
using UnhollowerRuntimeLib;
54
using UnityEngine;
65

7-
namespace EnableFullScreenToggleIL2CPP_netFm
6+
namespace BepInEx
87
{
98
/// <summary>
109
/// Allow toggling full screen with alt+enter in games where that has been disabled
1110
/// </summary>
1211
[BepInPlugin(GUID, PluginName, PluginVersion)]
1312
public class EnableFullScreenToggle : BasePlugin
1413
{
15-
internal const string GUID = "SpockBauru.EnableFullScreenToggleIL2CPP_netFm";
14+
internal const string GUID = "BepInEx.EnableFullScreenToggleIL2CPP_netFm";
1615
internal const string PluginName = "Enable Full Screen Toggle";
17-
internal const string PluginVersion = "0.6";
16+
internal const string PluginVersion = "0.7";
1817

19-
//Game Object shared between all SpockPlugins_BepInEx plugins
20-
public GameObject SpockBauru;
18+
//Game Object shared between all BepInExUtility plugins
19+
public GameObject BepInExUtility;
2120

2221
public override void Load()
2322
{
2423
//IL2CPP don't automatically inherits Monobehavior, so needs to add separatelly
2524
ClassInjector.RegisterTypeInIl2Cpp<FullScreenToggleComponent>();
2625

27-
SpockBauru = GameObject.Find("SpockBauru");
26+
BepInExUtility = GameObject.Find("BepInExUtility");
2827

29-
if (SpockBauru == null)
28+
if (BepInExUtility == null)
3029
{
31-
SpockBauru = new GameObject("SpockBauru");
32-
GameObject.DontDestroyOnLoad(SpockBauru);
33-
SpockBauru.hideFlags = HideFlags.HideAndDontSave;
34-
SpockBauru.AddComponent<FullScreenToggleComponent>();
30+
BepInExUtility = new GameObject("BepInExUtility");
31+
GameObject.DontDestroyOnLoad(BepInExUtility);
32+
BepInExUtility.hideFlags = HideFlags.HideAndDontSave;
33+
BepInExUtility.AddComponent<FullScreenToggleComponent>();
3534
}
36-
else SpockBauru.AddComponent<FullScreenToggleComponent>();
35+
else BepInExUtility.AddComponent<FullScreenToggleComponent>();
3736
}
3837
}
3938

EnableFullScreenToggleIL2CPP_netFm/EnableFullScreenToggleIL2CPP_netFm.csproj

Lines changed: 4 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,9 @@
3131
<WarningLevel>4</WarningLevel>
3232
</PropertyGroup>
3333
<ItemGroup>
34-
<Reference Include="BepInEx.Core">
34+
<Reference Include="System" />
35+
<Reference Include="BepInEx.Core, Version=6.0.0.0, Culture=neutral, processorArchitecture=MSIL">
36+
<SpecificVersion>False</SpecificVersion>
3537
<HintPath>..\IL2CPP_netFm\BepInEx.Core.dll</HintPath>
3638
</Reference>
3739
<Reference Include="BepInEx.IL2CPP">
@@ -40,39 +42,22 @@
4042
<Reference Include="Il2Cppmscorlib">
4143
<HintPath>..\IL2CPP_netFm\Il2Cppmscorlib.dll</HintPath>
4244
</Reference>
43-
<Reference Include="System" />
44-
<Reference Include="System.Core" />
45-
<Reference Include="System.Xml.Linq" />
46-
<Reference Include="System.Data.DataSetExtensions" />
47-
<Reference Include="Microsoft.CSharp" />
48-
<Reference Include="System.Data" />
49-
<Reference Include="System.Net.Http" />
50-
<Reference Include="System.Xml" />
51-
<Reference Include="..\IL2CPP_netFramework\*.dll" />
5245
<Reference Include="UnhollowerBaseLib">
5346
<HintPath>..\IL2CPP_netFm\UnhollowerBaseLib.dll</HintPath>
5447
</Reference>
55-
<Reference Include="UnityEngine">
56-
<HintPath>..\IL2CPP_netFm\UnityEngine.dll</HintPath>
57-
</Reference>
5848
<Reference Include="UnityEngine.CoreModule">
5949
<HintPath>..\IL2CPP_netFm\UnityEngine.CoreModule.dll</HintPath>
6050
</Reference>
6151
<Reference Include="UnityEngine.InputLegacyModule">
6252
<HintPath>..\IL2CPP_netFm\UnityEngine.InputLegacyModule.dll</HintPath>
6353
</Reference>
64-
<Reference Include="UnityEngine.InputModule">
65-
<HintPath>..\IL2CPP_netFm\UnityEngine.InputModule.dll</HintPath>
66-
</Reference>
6754
</ItemGroup>
6855
<ItemGroup>
6956
<Compile Include="EnableFullScreenToggleIL2CPP_netFm.cs" />
7057
<Compile Include="Properties\AssemblyInfo.cs" />
7158
</ItemGroup>
7259
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
7360
<PropertyGroup>
74-
<PostBuildEvent>xcopy "$(TargetPath)" "$(SolutionDir)Releases\$(ProjectName)\BepInEx\Plugins\" /s /i /y
75-
powershell Compress-Archive -Path '$(SolutionDir)Releases\$(ProjectName)\BepInEx\' -DestinationPath '$(SolutionDir)Releases\$(ProjectName).zip' -Force
76-
RD /S /Q "$(SolutionDir)Releases\$(ProjectName)\"</PostBuildEvent>
61+
<PostBuildEvent>xcopy "$(TargetPath)" "$(SolutionDir)bin\BepInEx\Plugins\" /s /i /y</PostBuildEvent>
7762
</PropertyGroup>
7863
</Project>

EnableFullScreenToggleIL2CPP_netFm/Properties/AssemblyInfo.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
using System.Reflection;
2-
using static EnableFullScreenToggleIL2CPP_netFm.EnableFullScreenToggle;
2+
using static BepInEx.EnableFullScreenToggle;
33

44
[assembly: AssemblyTitle(GUID)]
55
[assembly: AssemblyDescription(PluginName)]

EnableResizeIL2CPP_netFm/EnableResize.cs

Lines changed: 17 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,28 @@
1-
using BepInEx;
2-
using BepInEx.Configuration;
3-
using BepInEx.IL2CPP;
4-
using BepInEx.IL2CPP.Utils.Collections;
5-
using System;
1+
using System;
62
using System.Collections;
73
using System.Diagnostics;
84
using System.Runtime.InteropServices;
95
using System.Text;
6+
using BepInEx.IL2CPP;
7+
using BepInEx.IL2CPP.Utils.Collections;
8+
using BepInEx.Configuration;
109
using UnhollowerRuntimeLib;
1110
using UnityEngine;
1211

13-
namespace EnableResizeIL2CPP_netFm
12+
namespace BepInEx
1413
{
1514
/// <summary>
1615
/// Enable window resizing in windowed mode.
1716
/// </summary>
1817
[BepInPlugin(GUID, PluginName, PluginVersion)]
1918
public class EnableResize : BasePlugin
2019
{
21-
internal const string GUID = "SpockBauru.EnableResizeIL2CPP_netFm";
20+
internal const string GUID = "BepInEx.EnableResizeIL2CPP_netFm";
2221
internal const string PluginName = "Enable Resize";
23-
internal const string PluginVersion = "0.6";
22+
internal const string PluginVersion = "0.7";
2423

25-
//Game Object shared between all SpockPlugins_BepInEx plugins
26-
public GameObject SpockBauru;
24+
//Game Object shared between all BepInExUtility plugins
25+
public GameObject BepInExUtility;
2726

2827
internal static ConfigEntry<bool> ConfigEnableResize { get; private set; }
2928

@@ -34,15 +33,15 @@ public override void Load()
3433
//IL2CPP don't automatically inherits Monobehavior, so needs to add separatelly
3534
ClassInjector.RegisterTypeInIl2Cpp<EnableResizeComponent>();
3635

37-
SpockBauru = GameObject.Find("SpockBauru");
38-
if (SpockBauru == null)
36+
BepInExUtility = GameObject.Find("BepInExUtility");
37+
if (BepInExUtility == null)
3938
{
40-
SpockBauru = new GameObject("SpockBauru");
41-
GameObject.DontDestroyOnLoad(SpockBauru);
42-
SpockBauru.hideFlags = HideFlags.HideAndDontSave;
43-
SpockBauru.AddComponent<EnableResizeComponent>();
39+
BepInExUtility = new GameObject("BepInExUtility");
40+
GameObject.DontDestroyOnLoad(BepInExUtility);
41+
BepInExUtility.hideFlags = HideFlags.HideAndDontSave;
42+
BepInExUtility.AddComponent<EnableResizeComponent>();
4443
}
45-
else SpockBauru.AddComponent<EnableResizeComponent>();
44+
else BepInExUtility.AddComponent<EnableResizeComponent>();
4645
}
4746
}
4847

@@ -80,7 +79,7 @@ public EnableResizeComponent(IntPtr handle) : base(handle) { }
8079
private const int WS_SYSMENU = 0x80000;
8180
private const int WS_THICKFRAME = 0x40000;
8281

83-
private const string GET_CLASS_NAME_MAGIC = "UnityWndClass"; //How Anon got this???
82+
private const string GET_CLASS_NAME_MAGIC = "UnityWndClass";
8483
private IntPtr WindowHandle = IntPtr.Zero;
8584

8685
private int windowStyle = 0;

EnableResizeIL2CPP_netFm/EnableResizeIL2CPP_netFm.csproj

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,6 @@
3232
</PropertyGroup>
3333
<ItemGroup>
3434
<Reference Include="System" />
35-
<Reference Include="System.Core" />
36-
<Reference Include="System.Xml.Linq" />
37-
<Reference Include="System.Data.DataSetExtensions" />
38-
<Reference Include="Microsoft.CSharp" />
39-
<Reference Include="System.Data" />
40-
<Reference Include="System.Net.Http" />
41-
<Reference Include="System.Xml" />
4235
<Reference Include="BepInEx.Core">
4336
<HintPath>..\IL2CPP_netFm\BepInEx.Core.dll</HintPath>
4437
</Reference>
@@ -51,9 +44,6 @@
5144
<Reference Include="Il2Cppmscorlib">
5245
<HintPath>..\IL2CPP_netFm\Il2Cppmscorlib.dll</HintPath>
5346
</Reference>
54-
<Reference Include="UnityEngine">
55-
<HintPath>..\IL2CPP_netFm\UnityEngine.dll</HintPath>
56-
</Reference>
5747
<Reference Include="UnityEngine.CoreModule">
5848
<HintPath>..\IL2CPP_netFm\UnityEngine.CoreModule.dll</HintPath>
5949
</Reference>
@@ -64,8 +54,6 @@
6454
</ItemGroup>
6555
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
6656
<PropertyGroup>
67-
<PostBuildEvent>xcopy "$(TargetPath)" "$(SolutionDir)Releases\$(ProjectName)\BepInEx\Plugins\" /s /i /y
68-
powershell Compress-Archive -Path '$(SolutionDir)Releases\$(ProjectName)\BepInEx\' -DestinationPath '$(SolutionDir)Releases\$(ProjectName).zip' -Force
69-
RD /S /Q "$(SolutionDir)Releases\$(ProjectName)\"</PostBuildEvent>
57+
<PostBuildEvent>xcopy "$(TargetPath)" "$(SolutionDir)bin\BepInEx\Plugins\" /s /i /y</PostBuildEvent>
7058
</PropertyGroup>
7159
</Project>

EnableResizeIL2CPP_netFm/Properties/AssemblyInfo.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
using System.Reflection;
2-
using static EnableResizeIL2CPP_netFm.EnableResize;
2+
using static BepInEx.EnableResize;
33

44
[assembly: AssemblyTitle(GUID)]
55
[assembly: AssemblyDescription(PluginName)]

GraphicsSettingsIL2CPP_netFm/GraphicsSettings.cs

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,20 @@
11
using System;
2-
using BepInEx;
32
using BepInEx.IL2CPP;
4-
using UnityEngine;
53
using BepInEx.Configuration;
4+
using UnityEngine;
65
using UnityEngine.SceneManagement;
76

8-
namespace GraphicsSettingsIL2CPP_netFm
7+
namespace BepInEx
98
{
109
/// <summary>
1110
/// Change graphics settings like resolution, full screen and vSync in the Configuration Manager (F5)
1211
/// </summary>
1312
[BepInPlugin(GUID, PluginName, PluginVersion)]
1413
public class GraphicsSettings : BasePlugin
1514
{
16-
internal const string GUID = "SpockBauru.GraphicsSettingsIL2CPP_NetFm";
15+
internal const string GUID = "BepInEx.GraphicsSettingsIL2CPP_NetFm";
1716
internal const string PluginName = "Graphics Settings";
18-
internal const string PluginVersion = "0.6";
17+
internal const string PluginVersion = "0.7";
1918

2019
private static ConfigEntry<int> Width;
2120
private static ConfigEntry<int> Height;

GraphicsSettingsIL2CPP_netFm/GraphicsSettingsIL2CPP_netFm.csproj

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
<WarningLevel>4</WarningLevel>
3232
</PropertyGroup>
3333
<ItemGroup>
34+
<Reference Include="System" />
3435
<Reference Include="BepInEx.Core">
3536
<HintPath>..\IL2CPP_netFm\BepInEx.Core.dll</HintPath>
3637
</Reference>
@@ -40,33 +41,21 @@
4041
<Reference Include="Il2Cppmscorlib">
4142
<HintPath>..\IL2CPP_netFm\Il2Cppmscorlib.dll</HintPath>
4243
</Reference>
43-
<Reference Include="System" />
44-
<Reference Include="System.Core" />
45-
<Reference Include="System.Xml.Linq" />
46-
<Reference Include="System.Data.DataSetExtensions" />
47-
<Reference Include="Microsoft.CSharp" />
48-
<Reference Include="System.Data" />
49-
<Reference Include="System.Net.Http" />
50-
<Reference Include="System.Xml" />
51-
<Reference Include="UnhollowerBaseLib">
44+
<Reference Include="UnhollowerBaseLib, Version=0.4.33.3, Culture=neutral, processorArchitecture=MSIL">
45+
<SpecificVersion>False</SpecificVersion>
5246
<HintPath>..\IL2CPP_netFm\UnhollowerBaseLib.dll</HintPath>
5347
</Reference>
5448
<Reference Include="UnityEngine.CoreModule">
5549
<HintPath>..\IL2CPP_netFm\UnityEngine.CoreModule.dll</HintPath>
5650
</Reference>
57-
<Reference Include="UnityEngine.IMGUIModule">
58-
<HintPath>..\IL2CPP_netFm\UnityEngine.IMGUIModule.dll</HintPath>
59-
</Reference>
6051
</ItemGroup>
6152
<ItemGroup>
6253
<Compile Include="GraphicsSettings.cs" />
6354
<Compile Include="Properties\AssemblyInfo.cs" />
6455
</ItemGroup>
6556
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
6657
<PropertyGroup>
67-
<PostBuildEvent>xcopy "$(TargetPath)" "$(SolutionDir)Releases\$(ProjectName)\BepInEx\Plugins\" /s /i /y
68-
powershell Compress-Archive -Path '$(SolutionDir)Releases\$(ProjectName)\BepInEx\' -DestinationPath '$(SolutionDir)Releases\$(ProjectName).zip' -Force
69-
RD /S /Q "$(SolutionDir)Releases\$(ProjectName)\"
58+
<PostBuildEvent>xcopy "$(TargetPath)" "$(SolutionDir)bin\BepInEx\Plugins\" /s /i /y
7059

7160
</PostBuildEvent>
7261
</PropertyGroup>

GraphicsSettingsIL2CPP_netFm/Properties/AssemblyInfo.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
using System.Reflection;
2-
using static GraphicsSettingsIL2CPP_netFm.GraphicsSettings;
2+
using static BepInEx.GraphicsSettings;
33

44
[assembly: AssemblyTitle(GUID)]
55
[assembly: AssemblyDescription(PluginName)]

MessageCenterIL2CPP_netFm/MessageCenter.LogEntry.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
namespace MessageCenterIL2CPP_netFm
1+
namespace BepInEx
22
{
33
public partial class MessageCenterComponent
44
{

0 commit comments

Comments
 (0)