implement playerState

- use IPlayerState for DalamudUtilService and make things less asynced
- make LocationInfo work with ContentFinderData
This commit is contained in:
Tsubasahane
2025-12-27 17:04:39 +08:00
parent 1632258c4f
commit 5c8e239a7b
16 changed files with 132 additions and 106 deletions

View File

@@ -72,7 +72,7 @@ public sealed class TokenProvider : IDisposable, IMediatorSubscriber
result = await _httpClient.PostAsync(tokenUri, new FormUrlEncodedContent(
[
new KeyValuePair<string, string>("auth", auth),
new KeyValuePair<string, string>("charaIdent", await _dalamudUtil.GetPlayerNameHashedAsync().ConfigureAwait(false)),
new KeyValuePair<string, string>("charaIdent", _dalamudUtil.GetPlayerNameHashed()),
]), ct).ConfigureAwait(false);
}
else
@@ -152,7 +152,7 @@ public sealed class TokenProvider : IDisposable, IMediatorSubscriber
JwtIdentifier jwtIdentifier;
try
{
var playerIdentifier = await _dalamudUtil.GetPlayerNameHashedAsync().ConfigureAwait(false);
var playerIdentifier = _dalamudUtil.GetPlayerNameHashed();
if (string.IsNullOrEmpty(playerIdentifier))
{