diff --git a/RemoteAgents/AgentBankaCraftworksSupply.cs b/RemoteAgents/AgentBankaCraftworksSupply.cs index 7d22a3b..b0a0f17 100644 --- a/RemoteAgents/AgentBankaCraftworksSupply.cs +++ b/RemoteAgents/AgentBankaCraftworksSupply.cs @@ -6,26 +6,39 @@ namespace LlamaLibrary.RemoteAgents; - +/// +/// Remote agent for the Banka Craftworks item supply interface. +/// Manages the submission of crafted or gathered items for Banka Craftworks. +/// public class AgentBankaCraftworksSupply : AgentInterface, IAgent { - - + /// + /// Initializes a new instance of the class. + /// + /// The memory address of the agent. protected AgentBankaCraftworksSupply(IntPtr pointer) : base(pointer) { } + /// public IntPtr RegisteredVtable => AgentBankaCraftworksSupplyOffsets.Vtable; + /// + /// Gets the memory address of the internal instance pointer. + /// public IntPtr InstancePointer { get { - var temp1 = Core.Memory.Read(Pointer ) ; + var temp1 = Core.Memory.Read(Pointer); return temp1; } } + /// + /// Gets the memory address of the internal function pointer used for item hand-ins, + /// resolved by reading an offset from the main instance pointer. + /// public IntPtr InstancePointerWithOffset { get @@ -35,6 +48,10 @@ public IntPtr InstancePointerWithOffset } } + /// + /// Executes the hand-in operation for a specified item in a bag slot. + /// + /// The containing the item to hand in. public void HandIn(BagSlot slot) { //var instance = Core.Memory.Read(Pointer) + Offsets.PointerOffset; diff --git a/RemoteAgents/AgentDawnStory.cs b/RemoteAgents/AgentDawnStory.cs index 5beb087..404029e 100644 --- a/RemoteAgents/AgentDawnStory.cs +++ b/RemoteAgents/AgentDawnStory.cs @@ -7,14 +7,23 @@ namespace LlamaLibrary.RemoteAgents { + /// + /// Remote agent for the "Dawn Story" (Duty Support story mode) interface. + /// Manages the selection and availability of duties in the story mode Duty Support window. + /// public class AgentDawnStory : AgentInterface, IAgent { + /// public IntPtr RegisteredVtable => AgentDawnStoryOffsets.Vtable; - - + /// + /// Gets a value indicating whether the duty list has been fully loaded into memory. + /// public bool IsLoaded => Core.Memory.Read(Pointer + AgentDawnStoryOffsets.Loaded) != 0; + /// + /// Gets the memory pointer to the start of the duty information array. + /// public IntPtr DutyArrayPtr { get @@ -25,12 +34,22 @@ public IntPtr DutyArrayPtr } } + /// + /// Gets an array of structures representing the available story duties. + /// public DutyInfo[] Duties => Core.Memory.ReadArray(DutyArrayPtr, AgentDawnStoryOffsets.DutyCount); + /// + /// Initializes a new instance of the class. + /// + /// The memory address of the agent. protected AgentDawnStory(IntPtr pointer) : base(pointer) { } + /// + /// Gets the identifier of the currently selected duty in the interface. + /// public byte SelectedDuty => Core.Memory.Read(Pointer + 0x28); } } \ No newline at end of file diff --git a/RemoteAgents/AgentLookingForGroup.cs b/RemoteAgents/AgentLookingForGroup.cs index 5be61a5..7eb9575 100644 --- a/RemoteAgents/AgentLookingForGroup.cs +++ b/RemoteAgents/AgentLookingForGroup.cs @@ -7,18 +7,31 @@ namespace LlamaLibrary.RemoteAgents { + /// + /// Remote agent for the Party Finder (Looking for Group) interface. + /// Manages recruitment comments and other PF-related settings. + /// public class AgentLookingForGroup : AgentInterface, IAgent { + /// public IntPtr RegisteredVtable => AgentLookingForGroupOffsets.VTable; - - + /// + /// Initializes a new instance of the class. + /// + /// The memory address of the agent. protected AgentLookingForGroup(IntPtr pointer) : base(pointer) { } + /// + /// Gets the memory address where the Party Finder recruitment comment is stored. + /// public IntPtr CommentStringPtr => Pointer + AgentLookingForGroupOffsets.CommentString; + /// + /// Gets or sets the Party Finder recruitment comment string. + /// public string SavedComment { get => Core.Memory.ReadStringUTF8(CommentStringPtr); diff --git a/RemoteAgents/AgentMinionNoteBook.cs b/RemoteAgents/AgentMinionNoteBook.cs index 0b2a979..db6cdd2 100644 --- a/RemoteAgents/AgentMinionNoteBook.cs +++ b/RemoteAgents/AgentMinionNoteBook.cs @@ -9,17 +9,32 @@ namespace LlamaLibrary.RemoteAgents { + /// + /// Remote agent for the Minion Guide (Minion Notebook) interface. + /// Provides access to the list of acquired minions and their metadata. + /// public class AgentMinionNoteBook : AgentInterface, IAgent { + /// public IntPtr RegisteredVtable => AgentMinionNoteBookOffsets.VTable; + /// + /// Gets the memory address where the pointer to the minion list is stored. + /// public IntPtr MinionListAddress => Pointer + AgentMinionNoteBookOffsets.AgentOffset; - + /// + /// Initializes a new instance of the class. + /// + /// The memory address of the agent. protected AgentMinionNoteBook(IntPtr pointer) : base(pointer) { } + /// + /// Retrieves the full list of minions currently loaded in the agent's memory. + /// + /// An array of objects. public MinionStruct[] GetCurrentMinions() { var address = Pointer + AgentMinionNoteBookOffsets.AgentOffset; @@ -28,6 +43,11 @@ public MinionStruct[] GetCurrentMinions() return Core.Memory.ReadArray(address1, (int)count); } + /// + /// Retrieves the localized name of a minion by its index in the guide. + /// + /// The zero-based index of the minion. + /// The minion name as a string, or an empty string if not found. public static string GetMinionName(int index) { var result = Core.Memory.CallInjectedWraper(AgentMinionNoteBookOffsets.GetCompanion, index); @@ -35,12 +55,21 @@ public static string GetMinionName(int index) } } + /// + /// Represents the memory-mapped structure for a minion in the guide. + /// [StructLayout(LayoutKind.Explicit, Size = 0x4)] public struct MinionStruct { + /// + /// The unique identifier of the minion. + /// [FieldOffset(0)] public ushort MinionId; + /// + /// Reserved or unknown field. + /// [FieldOffset(2)] public ushort unknown; }