Upload files to "/"
This commit is contained in:
1 parent
3c7545da22
commit
20f1e294dd
5 files changed
+100
No files matched your search
@@ -0,0 +1,9 @@
|
||||
namespace GorillaCaptions
|
||||
{
|
||||
internal class Constants
|
||||
{
|
||||
public const string Guid = "com.deez.gorillacaptions";
|
||||
public const string Name = "Deez's GorillaCaptions";
|
||||
public const string Version = "1.0.3";
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<Project>
|
||||
<PropertyGroup>
|
||||
<GamePath>C:\Program Files (x86)\Steam\steamapps\common\Gorilla Tag</GamePath>
|
||||
<GameAssemblyPath>$(GamePath)\Gorilla Tag_Data\Managed</GameAssemblyPath>
|
||||
<BepInExAssemblyPath>$(GamePath)\BepInEx\core</BepInExAssemblyPath>
|
||||
<PluginsPath>$(GamePath)\BepInEx\plugins</PluginsPath>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(CI)'=='TRUE'">
|
||||
<GameAssemblyPath>.\Libs</GameAssemblyPath>
|
||||
<BepInExAssemblyPath>.\Libs</BepInExAssemblyPath>
|
||||
<PluginsPath>.\Libs</PluginsPath>
|
||||
<WarningLevel>0</WarningLevel>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<Project>
|
||||
<Target Name="CopyToPlugins" AfterTargets="Build">
|
||||
<Copy SourceFiles="$(TargetPath)" DestinationFiles="$(PluginsPath)\$(TargetFileName)" />
|
||||
<Message Text="Copied to Plugins" Importance="high"/>
|
||||
</Target>
|
||||
</Project>
|
||||
@@ -0,0 +1,36 @@
|
||||
using HarmonyLib;
|
||||
using System.Reflection;
|
||||
|
||||
namespace GorillaCaptions
|
||||
{
|
||||
public class HarmonyPatches
|
||||
{
|
||||
private static Harmony instance;
|
||||
|
||||
public static bool IsPatched { get; private set; }
|
||||
public const string InstanceId = Constants.Guid;
|
||||
|
||||
internal static void ApplyHarmonyPatches()
|
||||
{
|
||||
if (!IsPatched)
|
||||
{
|
||||
if (instance == null)
|
||||
{
|
||||
instance = new Harmony(InstanceId);
|
||||
}
|
||||
|
||||
instance.PatchAll(Assembly.GetExecutingAssembly());
|
||||
IsPatched = true;
|
||||
}
|
||||
}
|
||||
|
||||
internal static void RemoveHarmonyPatches()
|
||||
{
|
||||
if (instance != null && IsPatched)
|
||||
{
|
||||
instance.UnpatchSelf();
|
||||
IsPatched = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
using BepInEx;
|
||||
using GorillaCaptions.Classes.Admin;
|
||||
using GorillaCaptions.Managers.DiscordRPC;
|
||||
using UnityEngine;
|
||||
|
||||
namespace GorillaCaptions;
|
||||
|
||||
[BepInPlugin(Constants.Guid, Constants.Name, Constants.Version)]
|
||||
public class Plugin : BaseUnityPlugin
|
||||
{
|
||||
public static Plugin instance;
|
||||
|
||||
void Awake()
|
||||
{
|
||||
instance = this;
|
||||
Debug.Log("<Deez's GorillaCaptions> Created by Deez <3");
|
||||
}
|
||||
|
||||
void Start()
|
||||
{
|
||||
HarmonyPatches.ApplyHarmonyPatches();
|
||||
|
||||
GameObject ClassHolder = new("Deez's GorillaCaptions");
|
||||
ClassHolder.AddComponent<DiscordRpc>();
|
||||
ClassHolder.AddComponent<DeezData>();
|
||||
ClassHolder.AddComponent<TrackerManager>();
|
||||
ClassHolder.AddComponent<Managers.SynthesizerManager>();
|
||||
ClassHolder.AddComponent<Managers.BubbleManager>();
|
||||
DontDestroyOnLoad(ClassHolder);
|
||||
|
||||
Debug.Log("<Deez's GorillaCaptions> Fully intialized");
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user