do not send forbidden files

This commit is contained in:
rootdarkarchon
2023-02-23 00:51:01 +01:00
parent b1a7afde27
commit 78f0df9eaf
2 changed files with 8 additions and 6 deletions

View File

@@ -132,11 +132,12 @@ public class CharacterDataFactory : MediatorSubscriberBase
// wait until chara is not drawing and present so nothing spontaneously explodes
_dalamudUtil.WaitWhileCharacterIsDrawing(_logger, playerRelatedObject, Guid.NewGuid(), 30000, ct: token);
var chara = _dalamudUtil.CreateGameObject(charaPointer)!;
while (!DalamudUtil.IsObjectPresent(chara))
int totalWaitTime = 10000;
while (!DalamudUtil.IsObjectPresent(_dalamudUtil.CreateGameObject(charaPointer)) && totalWaitTime > 0)
{
_logger.LogTrace("Character is null but it shouldn't be, waiting");
await Task.Delay(50).ConfigureAwait(false);
totalWaitTime -= 50;
}
Stopwatch st = Stopwatch.StartNew();