diff --git a/.gitignore b/.gitignore
index 8ebe09b..01fa79c 100644
--- a/.gitignore
+++ b/.gitignore
@@ -401,3 +401,6 @@ FodyWeavers.xsd
# JetBrains Rider
*.sln.iml
.idea/
+
+# Generated dll dependencies file to copy into the Directory.Build.props
+lib_names.xml
diff --git a/ChatBoxExtensions/ChatBoxExtensions.csproj b/ChatBoxExtensions/ChatBoxExtensions.csproj
index de5875c..d83ed14 100644
--- a/ChatBoxExtensions/ChatBoxExtensions.csproj
+++ b/ChatBoxExtensions/ChatBoxExtensions.csproj
@@ -1,12 +1,21 @@
+
+
+ $(NoWarn);MSB3270
+
+
$(MsBuildThisFileDirectory)\..\.ManagedLibs\ml_prm.dll
False
+
+ $(MsBuildThisFileDirectory)\..\.ManagedLibs\ChatBox.dll
+ False
+
diff --git a/ChatBoxExtensions/HarmonyPatches.cs b/ChatBoxExtensions/HarmonyPatches.cs
index 4f12e59..e52cf93 100644
--- a/ChatBoxExtensions/HarmonyPatches.cs
+++ b/ChatBoxExtensions/HarmonyPatches.cs
@@ -1,4 +1,4 @@
-using ABI_RC.Core.Savior;
+using ABI_RC.Systems.InputManagement;
using HarmonyLib;
namespace NAK.ChatBoxExtensions.HarmonyPatches;
@@ -9,6 +9,6 @@ public class CVRInputManagerPatches
[HarmonyPatch(typeof(CVRInputManager), nameof(CVRInputManager.Start))]
static void Postfix_CVRInputManager_Start(ref CVRInputManager __instance)
{
- ChatBoxExtensions.InputModule = __instance.gameObject.AddComponent();
+ __instance.AddInputModule(ChatBoxExtensions.InputModule);
}
}
diff --git a/ChatBoxExtensions/InputModules/InputModuleChatBoxExtensions.cs b/ChatBoxExtensions/InputModules/InputModuleChatBoxExtensions.cs
index 3891d5b..b757f4c 100644
--- a/ChatBoxExtensions/InputModules/InputModuleChatBoxExtensions.cs
+++ b/ChatBoxExtensions/InputModules/InputModuleChatBoxExtensions.cs
@@ -1,4 +1,4 @@
-using ABI_RC.Core.Savior;
+using ABI_RC.Systems.InputManagement;
using UnityEngine;
namespace NAK.ChatBoxExtensions.InputModules;
diff --git a/ChatBoxExtensions/Integrations/Base.cs b/ChatBoxExtensions/Integrations/Base.cs
index c344a01..c45cc50 100644
--- a/ChatBoxExtensions/Integrations/Base.cs
+++ b/ChatBoxExtensions/Integrations/Base.cs
@@ -1,5 +1,5 @@
-using ABI_RC.Core.Player;
-using ABI_RC.Core.Savior;
+using ABI_RC.Core.Networking;
+using ABI_RC.Core.Player;
namespace NAK.ChatBoxExtensions.Integrations;
@@ -18,9 +18,9 @@ public class CommandBase
{
string partialName = argument.Replace("*", "").Trim();
if (String.IsNullOrWhiteSpace(partialName)) return false;
- return MetaPort.Instance.username.Contains(partialName);
+ return AuthManager.username.Contains(partialName);
}
- return MetaPort.Instance.username == argument;
+ return AuthManager.username == argument;
}
internal static void LocalCommandIgnoreOthers(string argument, Action callback)
@@ -53,4 +53,4 @@ public class CommandBase
{
return CVRPlayerManager.Instance.TryGetPlayerName(guid);
}
-}
\ No newline at end of file
+}
diff --git a/ChatBoxExtensions/Integrations/ChatBox.cs b/ChatBoxExtensions/Integrations/ChatBox.cs
index ae8827f..37aa9ca 100644
--- a/ChatBoxExtensions/Integrations/ChatBox.cs
+++ b/ChatBoxExtensions/Integrations/ChatBox.cs
@@ -19,7 +19,7 @@ internal class ChatBoxCommands : CommandBase
{
RemoteCommandListenForSelf(message, args =>
{
- API.SendMessage("/pong " + GetPlayerUsername(sender), false, true);
+ API.SendMessage("/pong " + GetPlayerUsername(sender), false, true, true);
});
});
@@ -33,10 +33,10 @@ internal class ChatBoxCommands : CommandBase
{
awaitingPing = false;
TimeSpan timeSincePing = DateTime.Now - pingTime; // calculate the time difference
- API.SendMessage($"Time since ping: {timeSincePing.TotalMilliseconds}ms", false, true);
+ API.SendMessage($"Time since ping: {timeSincePing.TotalMilliseconds}ms", false, true, true);
return;
}
- API.SendMessage($"You have to ping first, {GetPlayerUsername(sender)}!", false, true);
+ API.SendMessage($"You have to ping first, {GetPlayerUsername(sender)}!", false, true, true);
});
});
}
diff --git a/ChatBoxExtensions/Integrations/ChilloutVRBase.cs b/ChatBoxExtensions/Integrations/ChilloutVRBase.cs
index c4cc313..9e29fca 100644
--- a/ChatBoxExtensions/Integrations/ChilloutVRBase.cs
+++ b/ChatBoxExtensions/Integrations/ChilloutVRBase.cs
@@ -1,5 +1,5 @@
using ABI_RC.Core;
-using ABI_RC.Core.Base;
+using ABI_RC.Core.Vivox;
namespace NAK.ChatBoxExtensions.Integrations;
@@ -28,14 +28,14 @@ internal class ChilloutVRBaseCommands : CommandBase
{
LocalCommandIgnoreOthers(message, args =>
{
- Audio.SetMicrophoneActive(true);
+ VivoxDeviceHandler.InputMuted = true;
});
},
onCommandReceived: (sender, message, sound, displayMsg) =>
{
RemoteCommandListenForAll(message, args =>
{
- Audio.SetMicrophoneActive(true);
+ VivoxDeviceHandler.InputMuted = false;
});
});
}
diff --git a/ChatBoxExtensions/Integrations/Commands.cs b/ChatBoxExtensions/Integrations/Commands.cs
index a0d54be..21e7b6a 100644
--- a/ChatBoxExtensions/Integrations/Commands.cs
+++ b/ChatBoxExtensions/Integrations/Commands.cs
@@ -8,8 +8,8 @@ public static class Commands
internal static void InitializeCommandHandlers()
{
- Kafe.ChatBox.API.OnMessageSent += (source, msg, notification, displayMsg) => HandleSentCommand(msg, notification, displayMsg);
- Kafe.ChatBox.API.OnMessageReceived += (source, sender, msg, notification, displayMsg) => HandleReceivedCommand(sender, msg, notification, displayMsg);
+ Kafe.ChatBox.API.OnMessageSent += msg => HandleSentCommand(msg.Message, msg.TriggerNotification, msg.DisplayOnChatBox);
+ Kafe.ChatBox.API.OnMessageReceived += msg => HandleReceivedCommand(msg.SenderGuid, msg.Message, msg.TriggerNotification, msg.DisplayOnChatBox);
}
internal static void RegisterCommand(string prefix, Action onCommandSent = null, Action onCommandReceived = null)
diff --git a/ChatBoxExtensions/Main.cs b/ChatBoxExtensions/Main.cs
index 370eaed..e6f764f 100644
--- a/ChatBoxExtensions/Main.cs
+++ b/ChatBoxExtensions/Main.cs
@@ -6,7 +6,7 @@ namespace NAK.ChatBoxExtensions;
public class ChatBoxExtensions : MelonMod
{
internal static MelonLogger.Instance Logger;
- internal static InputModuleChatBoxExtensions InputModule;
+ internal static InputModuleChatBoxExtensions InputModule = new();
public override void OnInitializeMelon()
{
diff --git a/ChatBoxExtensions/Properties/AssemblyInfo.cs b/ChatBoxExtensions/Properties/AssemblyInfo.cs
index bf1093f..97b6d79 100644
--- a/ChatBoxExtensions/Properties/AssemblyInfo.cs
+++ b/ChatBoxExtensions/Properties/AssemblyInfo.cs
@@ -28,6 +28,6 @@ using System.Reflection;
namespace ChatBoxExtensions.Properties;
internal static class AssemblyInfoParams
{
- public const string Version = "1.0.2";
+ public const string Version = "1.0.3";
public const string Author = "NotAKidoS";
}
diff --git a/Directory.Build.props b/Directory.Build.props
index e4ac903..75148e1 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -84,10 +84,6 @@
$(MsBuildThisFileDirectory)\.ManagedLibs\AwesomeTechnologies.VegetationStudioPro.Runtime.dll
False
-
- $(MsBuildThisFileDirectory)\.ManagedLibs\BakeryRuntimeAssembly.dll
- False
-
$(MsBuildThisFileDirectory)\.ManagedLibs\Bhaptics.Tact.dll
False
@@ -176,6 +172,10 @@
$(MsBuildThisFileDirectory)\.ManagedLibs\MTJobSystem.dll
False
+
+ $(MsBuildThisFileDirectory)\.ManagedLibs\NewBlood.EngineInternals.dll
+ False
+
$(MsBuildThisFileDirectory)\.ManagedLibs\Newtonsoft.Json.dll
False
diff --git a/NAK_CVR_Mods.sln b/NAK_CVR_Mods.sln
index b81db29..6a744ee 100644
--- a/NAK_CVR_Mods.sln
+++ b/NAK_CVR_Mods.sln
@@ -47,6 +47,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "EzCurls", "EzCurls\EzCurls.
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AlternateIKSystem", "AlternateIKSystem\AlternateIKSystem.csproj", "{CAB05E13-B529-4CDA-A2B5-B62E122408F8}"
EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ChatBoxExtensions", "ChatBoxExtensions\ChatBoxExtensions.csproj", "{0E1DD746-33A1-4179-AE70-8FB83AC40ABC}"
+EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -141,6 +143,10 @@ Global
{CAB05E13-B529-4CDA-A2B5-B62E122408F8}.Debug|Any CPU.Build.0 = Debug|Any CPU
{CAB05E13-B529-4CDA-A2B5-B62E122408F8}.Release|Any CPU.ActiveCfg = Release|Any CPU
{CAB05E13-B529-4CDA-A2B5-B62E122408F8}.Release|Any CPU.Build.0 = Release|Any CPU
+ {0E1DD746-33A1-4179-AE70-8FB83AC40ABC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {0E1DD746-33A1-4179-AE70-8FB83AC40ABC}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {0E1DD746-33A1-4179-AE70-8FB83AC40ABC}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {0E1DD746-33A1-4179-AE70-8FB83AC40ABC}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
diff --git a/copy_and_nstrip_dll.ps1 b/copy_and_nstrip_dll.ps1
index 35e33bb..7c86d08 100644
--- a/copy_and_nstrip_dll.ps1
+++ b/copy_and_nstrip_dll.ps1
@@ -12,7 +12,7 @@ $cvrDefaultPath = "E:\temp\CVR_Experimental"
$dllsToStrip = @('Assembly-CSharp.dll','Assembly-CSharp-firstpass.dll','AVProVideo.Runtime.dll', 'Unity.TextMeshPro.dll', 'MagicaCloth.dll')
# Array with the mods to grab
-$modNames = @("BTKUILib", "BTKSAImmersiveHud", "ActionMenu", "MenuScalePatch")
+$modNames = @("BTKUILib", "BTKSAImmersiveHud", "ActionMenu", "MenuScalePatch", "ChatBox", "ml_prm")
# Array with dlls to ignore from ManagedLibs
$cvrManagedLibNamesToIgnore = @("netstandard")