mirror of
https://github.com/Ottermandias/Glamourer.git
synced 2026-02-19 05:57:42 +01:00
Remove GameData, move a bunch of customization data to Penumbra.GameData and the rest to Glamourer, update accordingly. Some reformatting and cleanup.
This commit is contained in:
parent
e9d0e61b4c
commit
987c26a51d
83 changed files with 444 additions and 1620 deletions
|
|
@ -6,7 +6,9 @@ using Dalamud.Plugin.Services;
|
|||
using Dalamud.Utility.Signatures;
|
||||
using FFXIVClientStructs.FFXIV.Client.Game.Character;
|
||||
using Glamourer.Interop.Structs;
|
||||
using Glamourer.Structs;
|
||||
using Penumbra.GameData;
|
||||
using Penumbra.GameData.DataContainers;
|
||||
using Penumbra.GameData.Structs;
|
||||
|
||||
namespace Glamourer.Interop;
|
||||
|
||||
|
|
@ -14,19 +16,20 @@ public class JobService : IDisposable
|
|||
{
|
||||
private readonly nint _characterDataOffset;
|
||||
|
||||
public readonly IReadOnlyDictionary<byte, Job> Jobs;
|
||||
public readonly IReadOnlyDictionary<ushort, JobGroup> JobGroups;
|
||||
public readonly IReadOnlyList<JobGroup> AllJobGroups;
|
||||
public readonly DictJob Jobs;
|
||||
public readonly DictJobGroup JobGroups;
|
||||
|
||||
public IReadOnlyList<JobGroup> AllJobGroups
|
||||
=> JobGroups.AllJobGroups;
|
||||
|
||||
public event Action<Actor, Job, Job>? JobChanged;
|
||||
|
||||
public JobService(IDataManager gameData, IGameInteropProvider interop)
|
||||
public JobService(DictJob jobs, DictJobGroup jobGroups, IDataManager gameData, IGameInteropProvider interop)
|
||||
{
|
||||
interop.InitializeFromAttributes(this);
|
||||
_characterDataOffset = Marshal.OffsetOf<Character>(nameof(Character.CharacterData));
|
||||
Jobs = GameData.Jobs(gameData);
|
||||
AllJobGroups = GameData.AllJobGroups(gameData);
|
||||
JobGroups = GameData.JobGroups(gameData);
|
||||
Jobs = jobs;
|
||||
JobGroups = jobGroups;
|
||||
_changeJobHook.Enable();
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue