Skip to content

Commit 24eb4f7

Browse files
committed
[F] AdxHidInput 管道导致退出卡死
1 parent 26519fc commit 24eb4f7

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

AquaMai.Mods/GameSystem/AdxHidInput.cs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,7 @@ private void StartPipeServer()
290290

291291
isConnecting = true;
292292

293-
Task.Run(() =>
293+
new Thread(() =>
294294
{
295295
try
296296
{
@@ -314,12 +314,16 @@ private void StartPipeServer()
314314
catch (Exception e)
315315
{
316316
pipeServer = null;
317+
MelonLogger.Msg($"[HidInput] Pipe Server Error: {e.Message}");
317318
}
318319
finally
319320
{
320321
isConnecting = false;
321322
}
322-
});
323+
})
324+
{
325+
IsBackground = true
326+
};
323327
}
324328

325329
private void Update()

AquaMai.Mods/Utils/InstantQuit.cs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
1-
using System;
21
using AquaMai.Config.Attributes;
3-
using AquaMai.Config.Types;
4-
using AquaMai.Core.Helpers;
52
using HarmonyLib;
6-
using Main;
73
using UnityEngine;
84

95
namespace AquaMai.Mods.Utils;

0 commit comments

Comments
 (0)