master #107

Merged
sin365 merged 6 commits from Alienjack/AxibugEmuOnline:master into master 2025-08-21 00:30:04 +08:00
2 changed files with 26 additions and 8 deletions
Showing only changes of commit 51d638e116 - Show all commits

View File

@ -166,20 +166,23 @@ public static class AxiHttp
public static IPAddress GetDnsIP(string str)
{
if (!dictIP2Address.ContainsKey(str))
lock (dictIP2Address)
{
IPHostEntry host = Dns.GetHostEntry(str);
IPAddress ip = null;
foreach (var item in host.AddressList)
if (!dictIP2Address.ContainsKey(str))
{
if (item.AddressFamily == AddressFamily.InterNetwork)
IPHostEntry host = Dns.GetHostEntry(str);
IPAddress ip = null;
foreach (var item in host.AddressList)
{
ip = item; break;
if (item.AddressFamily == AddressFamily.InterNetwork)
{
ip = item; break;
}
}
dictIP2Address[str] = ip;
}
dictIP2Address[str] = ip;
return dictIP2Address[str];
}
return dictIP2Address[str];
}
public enum AxiDownLoadMode

View File

@ -1,5 +1,6 @@
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.InputSystem;
namespace AxibugEmuOnline.Client.InputDevices
{
@ -77,6 +78,20 @@ namespace AxibugEmuOnline.Client.InputDevices
public void Update()
{
foreach (var device in m_devices.Values) device.Update();
foreach (var device in InputSystem.devices)
{
if (device is Mouse)
continue;
for (int i = 0; i < device.allControls.Count; i++)
{
if (device.allControls[i].IsPressed(0))
{
Debug.Log($"{device.displayName}| {device.allControls[i].displayName}|{device.allControls[i].name}");
}
}
}
}
}
}