using ImGuiNET; using Lumina.Excel.GeneratedSheets; namespace TheHeartOfTheParty; internal class PluginUi : IDisposable { private Plugin Plugin { get; } private string _searchText = ""; private bool _unlockedOnly = true; internal PluginUi(Plugin plugin) { this.Plugin = plugin; this.Plugin.Interface.UiBuilder.Draw += this.OnDraw; } public void Dispose() { this.Plugin.Interface.UiBuilder.Draw -= this.OnDraw; } private void OnDraw() { if (!ImGui.Begin(this.Plugin.Name)) { ImGui.End(); return; } ImGui.Checkbox("Only show unlocked titles", ref this._unlockedOnly); ImGui.SetNextItemWidth(-1); ImGui.InputTextWithHint("##search", "Search...", ref this._searchText, 64); var fem = true; if (this.Plugin.ClientState.LocalPlayer is {} player) { fem = player.Customize[1] == 1; } var titles = this.Plugin.DataManager.GetExcelSheet