Skip to content

Commit

Permalink
clean up CharacterInfoService.cs
Browse files Browse the repository at this point in the history
  • Loading branch information
Koenari committed Aug 2, 2024
1 parent 35b2ba2 commit c0a8727
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions HimbeertoniRaidTool/Services/CharacterInfoService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
using Dalamud.Game.ClientState.Objects.SubKinds;
using Dalamud.Game.ClientState.Party;
using Dalamud.Plugin.Services;
using FFXIVClientStructs.FFXIV.Client.System.Framework;
using FFXIVClientStructs.FFXIV.Client.UI.Info;
using Lumina.Excel.GeneratedSheets;

Expand All @@ -12,9 +11,7 @@ internal unsafe class CharacterInfoService
{
private readonly IObjectTable _gameObjects;
private readonly IPartyList _partyList;
private readonly InfoModule* _infoModule;
private InfoProxyPartyMember* PartyInfo =>
(InfoProxyPartyMember*)_infoModule->GetInfoProxyById(InfoProxyId.PartyMember);
private static InfoProxyPartyMember* PartyInfo => InfoProxyPartyMember.Instance();
private readonly Dictionary<string, ulong> _cache = new();
private readonly HashSet<string> _notFound = new();
private DateTime _lastPrune;
Expand All @@ -25,11 +22,8 @@ internal CharacterInfoService(IObjectTable gameObjects, IPartyList partyList)
_gameObjects = gameObjects;
_partyList = partyList;
_lastPrune = DateTime.Now;
_infoModule = Framework.Instance()->UIModule->GetInfoModule();
}

public long GetLocalPlayerContentId() => (long)_infoModule->LocalContentId;

public ulong GetContentId(IPlayerCharacter? character)
{
if (character == null)
Expand Down

0 comments on commit c0a8727

Please sign in to comment.