mirror of
https://github.com/Caraxi/mare.client.git
synced 2025-12-13 19:04:15 +01:00
why did I start writing this plugin
This commit is contained in:
parent
61b178e2c0
commit
c7439ac769
7 changed files with 53 additions and 39 deletions
|
|
@ -70,12 +70,12 @@ public class CachedPlayer
|
|||
{
|
||||
Logger.Debug("Received total " + e.CharacterData.FileReplacements.Count + " file replacement data");
|
||||
_cache[e.CharacterData.Hash] = e.CharacterData;
|
||||
_lastAppliedEquipmentHash = e.CharacterData.Hash;
|
||||
}
|
||||
else
|
||||
{
|
||||
Logger.Debug("Had valid local cache for " + PlayerName);
|
||||
}
|
||||
_lastAppliedEquipmentHash = e.CharacterData.Hash;
|
||||
|
||||
DownloadAndApplyCharacter();
|
||||
}
|
||||
|
|
@ -158,15 +158,19 @@ public class CachedPlayer
|
|||
try
|
||||
{
|
||||
Logger.Debug("Restoring state for " + PlayerName);
|
||||
IsVisible = false;
|
||||
_downloadCancellationTokenSource?.Cancel();
|
||||
_downloadCancellationTokenSource?.Dispose();
|
||||
_downloadCancellationTokenSource = null;
|
||||
_dalamudUtil.RemovePlayerFromWatch(PlayerName);
|
||||
_ipcManager.PenumbraRemoveTemporaryCollection(PlayerName);
|
||||
_ipcManager.GlamourerRevertCharacterCustomization(PlayerName);
|
||||
_ipcManager.GlamourerApplyOnlyCustomization(_originalGlamourerData, PlayerName);
|
||||
_ipcManager.GlamourerApplyOnlyEquipment(_lastGlamourerData, PlayerName);
|
||||
if (IsVisible)
|
||||
{
|
||||
_ipcManager.GlamourerRevertCharacterCustomization(PlayerName);
|
||||
_ipcManager.GlamourerApplyOnlyCustomization(_originalGlamourerData, PlayerName);
|
||||
_ipcManager.GlamourerApplyOnlyEquipment(_lastGlamourerData, PlayerName);
|
||||
}
|
||||
|
||||
IsVisible = false;
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
|
|
@ -215,6 +219,7 @@ public class CachedPlayer
|
|||
|
||||
if (RequestedPenumbraRedraw == false && !string.IsNullOrEmpty(_lastAppliedEquipmentHash))
|
||||
{
|
||||
Logger.Warn("Unauthorized character change detected");
|
||||
DownloadAndApplyCharacter();
|
||||
}
|
||||
else
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue