Skip to content

Commit

Permalink
Merge pull request #2 from Frityet/main
Browse files Browse the repository at this point in the history
forgot to commit this whoops: Renamed PluginInfo.cs fields and split hooks into seperate file
  • Loading branch information
Maiq-The-Dude authored Jun 15, 2021
2 parents 6d6bbef + 7ef4b1b commit f2fbe1a
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 12 deletions.
15 changes: 15 additions & 0 deletions src/Plugin/src/Hooks.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
namespace H3VRMod
{
public class Hooks
{
public void Hook()
{

}

public void Unhook()
{

}
}
}
22 changes: 13 additions & 9 deletions src/Plugin/src/Plugin.cs
Original file line number Diff line number Diff line change
@@ -1,29 +1,33 @@
using BepInEx;
using System;
using BepInEx;

namespace H3VRMod
{
[BepInPlugin(PluginInfo.PLUGIN_GUID, PluginInfo.PLUGIN_NAME, PluginInfo.PLUGIN_VERSION)]
[BepInPlugin(PluginInfo.GUID, PluginInfo.NAME, PluginInfo.VERSION)]
[BepInProcess("h3vr.exe")]
public class Plugin : BaseUnityPlugin
{
internal Hooks Hooks;

public Plugin()
{
Hook();
Hooks = new Hooks();
Hooks.Hook();
}

private void OnDestroy()
private void Awake()
{
Unhook();

}

private void Hook()
private void Update()
{

}

private void Unhook()
private void OnDestroy()
{

Hooks.Unhook();
}
}
}
6 changes: 3 additions & 3 deletions src/Plugin/src/PluginInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ namespace H3VRMod
{
internal static class PluginInfo
{
internal const string PLUGIN_NAME = "Example H3VR Mod";
internal const string PLUGIN_GUID = "com.yourname.h3vrmod";
internal const string PLUGIN_VERSION = "1.0.0";
internal const string NAME = "Example H3VR Mod";
internal const string GUID = "com.yourname.h3vrmod";
internal const string VERSION = "1.0.0";
}
}

0 comments on commit f2fbe1a

Please sign in to comment.