feat: add novice network button

This commit is contained in:
Anna
2022-02-03 19:52:11 -05:00
parent 51ec427661
commit 20fbf4e004
2 changed files with 20 additions and 1 deletions
+13
View File
@@ -7,6 +7,7 @@ using FFXIVClientStructs.FFXIV.Client.UI;
using FFXIVClientStructs.FFXIV.Client.UI.Agent;
using FFXIVClientStructs.FFXIV.Component.GUI;
using Lumina.Excel.GeneratedSheets;
using ValueType = FFXIVClientStructs.FFXIV.Component.GUI.ValueType;
namespace ChatTwo.GameFunctions;
@@ -254,6 +255,18 @@ internal unsafe class GameFunctions : IDisposable {
}
}
internal void ClickNoviceNetworkButton() {
var agent = Framework.Instance()->GetUiModule()->GetAgentModule()->GetAgentByInternalId(AgentId.ChatLog);
// case 3
var value = new AtkValue {
Type = ValueType.Int,
Int = 3,
};
int result = 0;
var vf0 = *(delegate* unmanaged<AgentInterface*, int*, AtkValue*, ulong, ulong, int*>*) agent->VTable;
vf0(agent, &result, &value, 0, 0);
}
private readonly IntPtr _placeholderNamePtr = Marshal.AllocHGlobal(128);
private readonly string _placeholder = $"<{Guid.NewGuid():N}>";
private string? _replacementName;