Update 0.1.6 - Deploy AutoDetect, last debug and optimization

This commit is contained in:
2025-09-13 13:41:00 +02:00
parent b79a51748f
commit 04a8ee3186
10 changed files with 297 additions and 45 deletions

View File

@@ -61,4 +61,23 @@ public class AutoDetectRequestService
}
return ok;
}
public async Task<bool> SendAcceptNotifyAsync(string targetUid, CancellationToken ct = default)
{
var endpoint = _configProvider.AcceptEndpoint;
if (string.IsNullOrEmpty(endpoint))
{
_logger.LogDebug("No accept endpoint configured");
return false;
}
string? displayName = null;
try
{
var me = await _dalamud.RunOnFrameworkThread(() => _dalamud.GetPlayerCharacter()).ConfigureAwait(false);
displayName = me?.Name.TextValue;
}
catch { }
_logger.LogInformation("Nearby: sending accept notify via {endpoint}", endpoint);
return await _client.SendAcceptAsync(endpoint!, targetUid, displayName, ct).ConfigureAwait(false);
}
}