sdraw_mods_cvr/ml_amt/Main.cs
2025-08-15 06:49:24 -05:00

33 lines
864 B
C#

using System.Collections;
using UnityEngine;
namespace ml_amt
{
public class AvatarMotionTweaker : MelonLoader.MelonMod
{
MotionTweaker m_tweaker = null;
public override void OnInitializeMelon()
{
Settings.Init();
GameEvents.Init(HarmonyInstance);
MelonLoader.MelonCoroutines.Start(WaitForRootLogic());
}
IEnumerator WaitForRootLogic()
{
while(ABI_RC.Core.RootLogic.Instance == null)
yield return null;
m_tweaker = new GameObject("[AvatarMotionTweaker]").AddComponent<MotionTweaker>();
}
public override void OnDeinitializeMelon()
{
if(m_tweaker != null)
Object.Destroy(m_tweaker.gameObject);
m_tweaker = null;
}
}
}