1275 lines
56 KiB
C#
1275 lines
56 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Collections.ObjectModel;
|
|
using System.Runtime.CompilerServices;
|
|
using System.Threading;
|
|
using Dalamud.Game.Addon.Lifecycle;
|
|
using Dalamud.Game.Addon.Lifecycle.AddonArgTypes;
|
|
using Dalamud.Game.NativeWrapper;
|
|
using Dalamud.Plugin.Services;
|
|
using FFXIVClientStructs.FFXIV.Client.Game;
|
|
using FFXIVClientStructs.FFXIV.Client.Game.UI;
|
|
using FFXIVClientStructs.FFXIV.Component.GUI;
|
|
using LLib.GameUI;
|
|
using LLib.Inventory;
|
|
using LLib.Shop.Model;
|
|
using Lumina.Excel;
|
|
using Lumina.Excel.Sheets;
|
|
|
|
namespace LLib.Shop;
|
|
|
|
public sealed class GrandCompanyShop : IDisposable
|
|
{
|
|
private sealed class GrandCompanyPurchaseRequest
|
|
{
|
|
public required uint ItemId { get; init; }
|
|
|
|
public required int RankTabIndex { get; init; }
|
|
|
|
public required int CategoryTabIndex { get; init; }
|
|
|
|
public required int DesiredQuantity { get; init; }
|
|
|
|
public int InitialCount { get; set; } = -1;
|
|
}
|
|
|
|
private const string AddonName = "GrandCompanyExchange";
|
|
|
|
private const string SelectYesNoAddonName = "SelectYesno";
|
|
|
|
private readonly IPluginLog _pluginLog;
|
|
|
|
private readonly IGameGui _gameGui;
|
|
|
|
private readonly IAddonLifecycle _addonLifecycle;
|
|
|
|
private readonly ExcelSheet<Item> _itemSheet;
|
|
|
|
private const int MinPollIntervalMs = 100;
|
|
|
|
private const int MaxWaitMs = 3000;
|
|
|
|
private const int MaxPurchaseQuantity = 99;
|
|
|
|
private const int AtkItemCountIndex = 1;
|
|
|
|
private const int AtkSealCostBase = 67;
|
|
|
|
private const int AtkIconIdBase = 167;
|
|
|
|
private const int AtkItemIdBase = 317;
|
|
|
|
private static readonly ReadOnlyCollection<GrandCompanyItem> EmptyItems = new List<GrandCompanyItem>().AsReadOnly();
|
|
|
|
private int _navigationStep;
|
|
|
|
private long _lastActionMs;
|
|
|
|
private bool _awaitingAddonReady;
|
|
|
|
private bool _yesNoArmed;
|
|
|
|
private GrandCompanyPurchaseRequest? _pendingPurchase;
|
|
|
|
private int _itemCountBeforePurchase;
|
|
|
|
[CompilerGenerated]
|
|
private EventHandler<PurchaseCompletedEventArgs>? m_PurchaseCompleted;
|
|
|
|
[CompilerGenerated]
|
|
private EventHandler? m_ShopOpened;
|
|
|
|
[CompilerGenerated]
|
|
private EventHandler? m_ShopClosed;
|
|
|
|
public bool IsOpen { get; private set; }
|
|
|
|
public bool IsPurchaseInProgress => _pendingPurchase != null;
|
|
|
|
public bool IsAwaitingConfirmation { get; private set; }
|
|
|
|
public event EventHandler<PurchaseCompletedEventArgs>? PurchaseCompleted
|
|
{
|
|
[CompilerGenerated]
|
|
add
|
|
{
|
|
EventHandler<PurchaseCompletedEventArgs> eventHandler = this.m_PurchaseCompleted;
|
|
int num = 1165402561;
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = 1165402563;
|
|
int num4 = num2;
|
|
int num5 = num4 + num3;
|
|
int num6 = num4 & num3;
|
|
switch (num5 - (num6 + num6))
|
|
{
|
|
case 0:
|
|
num = 1165402561;
|
|
break;
|
|
case 1:
|
|
return;
|
|
case 2:
|
|
{
|
|
EventHandler<PurchaseCompletedEventArgs> eventHandler2 = eventHandler;
|
|
EventHandler<PurchaseCompletedEventArgs> value2 = (EventHandler<PurchaseCompletedEventArgs>)_202E_202C_206F_200C_202C_206D_202A_206E_206B_200B_200F_202B_200F_206C_200F_200F_202E_200C_200E_206D_206B_202B_206A_202A_202D_202A_200D_200E_206F_206C_200D_202C_200C_206D_200B_206E_206C_206E_202E_206B_202E((Delegate)eventHandler2, (Delegate)value);
|
|
eventHandler = Interlocked.CompareExchange(ref this.m_PurchaseCompleted, value2, eventHandler2);
|
|
num = (((object)eventHandler != eventHandler2) ? 1165402561 : 1165402562);
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
[CompilerGenerated]
|
|
remove
|
|
{
|
|
EventHandler<PurchaseCompletedEventArgs> eventHandler = this.m_PurchaseCompleted;
|
|
int num = -1559785428;
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = -1559785427;
|
|
int num4 = num2;
|
|
switch ((num4 | num3) - (num4 & num3))
|
|
{
|
|
case 0:
|
|
return;
|
|
case 1:
|
|
{
|
|
EventHandler<PurchaseCompletedEventArgs> eventHandler2 = eventHandler;
|
|
EventHandler<PurchaseCompletedEventArgs> value2 = (EventHandler<PurchaseCompletedEventArgs>)_200B_200F_200D_200E_200E_206D_200C_206C_206F_200B_202C_202C_206F_202C_202B_206D_206A_202B_206C_202C_206E_200C_200D_202E_200D_202A_202A_200B_202C_202B_206B_200F_206B_200E_206A_206C_200F_200D_200F_206D_202E((Delegate)eventHandler2, (Delegate)value);
|
|
eventHandler = Interlocked.CompareExchange(ref this.m_PurchaseCompleted, value2, eventHandler2);
|
|
num = (((object)eventHandler != eventHandler2) ? (-1559785428) : (-1559785427));
|
|
break;
|
|
}
|
|
case 2:
|
|
num = -1559785428;
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
public event EventHandler? ShopOpened
|
|
{
|
|
[CompilerGenerated]
|
|
add
|
|
{
|
|
EventHandler eventHandler = this.m_ShopOpened;
|
|
int num = 1361377683;
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = 1361377682;
|
|
int num4 = num2;
|
|
int num5 = num4 + num3;
|
|
int num6 = num4 & num3;
|
|
switch (num5 - (num6 + num6))
|
|
{
|
|
case 0:
|
|
num = 1361377683;
|
|
break;
|
|
case 1:
|
|
{
|
|
EventHandler eventHandler2 = eventHandler;
|
|
EventHandler value2 = (EventHandler)_202E_202C_206F_200C_202C_206D_202A_206E_206B_200B_200F_202B_200F_206C_200F_200F_202E_200C_200E_206D_206B_202B_206A_202A_202D_202A_200D_200E_206F_206C_200D_202C_200C_206D_200B_206E_206C_206E_202E_206B_202E((Delegate)eventHandler2, (Delegate)value);
|
|
eventHandler = Interlocked.CompareExchange(ref this.m_ShopOpened, value2, eventHandler2);
|
|
num = (((object)eventHandler != eventHandler2) ? 1361377683 : 1361377680);
|
|
break;
|
|
}
|
|
case 2:
|
|
return;
|
|
}
|
|
}
|
|
}
|
|
[CompilerGenerated]
|
|
remove
|
|
{
|
|
EventHandler eventHandler = this.m_ShopOpened;
|
|
int num = -281406326;
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = -281406328;
|
|
int num4 = num2;
|
|
int num5 = num4 + num3;
|
|
int num6 = num4 & num3;
|
|
switch (num5 - (num6 + num6))
|
|
{
|
|
case 0:
|
|
num = -281406326;
|
|
break;
|
|
case 1:
|
|
return;
|
|
case 2:
|
|
{
|
|
EventHandler eventHandler2 = eventHandler;
|
|
EventHandler value2 = (EventHandler)_200B_200F_200D_200E_200E_206D_200C_206C_206F_200B_202C_202C_206F_202C_202B_206D_206A_202B_206C_202C_206E_200C_200D_202E_200D_202A_202A_200B_202C_202B_206B_200F_206B_200E_206A_206C_200F_200D_200F_206D_202E((Delegate)eventHandler2, (Delegate)value);
|
|
eventHandler = Interlocked.CompareExchange(ref this.m_ShopOpened, value2, eventHandler2);
|
|
num = (((object)eventHandler != eventHandler2) ? (-281406326) : (-281406327));
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
public event EventHandler? ShopClosed
|
|
{
|
|
[CompilerGenerated]
|
|
add
|
|
{
|
|
EventHandler eventHandler = this.m_ShopClosed;
|
|
int num = 1747740711;
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = 1747740710;
|
|
int num4 = num2;
|
|
int num5 = num4 + num3;
|
|
int num6 = num4 & num3;
|
|
switch (num5 - (num6 + num6))
|
|
{
|
|
case 2:
|
|
num = 1747740711;
|
|
break;
|
|
case 0:
|
|
return;
|
|
case 1:
|
|
{
|
|
EventHandler eventHandler2 = eventHandler;
|
|
EventHandler value2 = (EventHandler)_202E_202C_206F_200C_202C_206D_202A_206E_206B_200B_200F_202B_200F_206C_200F_200F_202E_200C_200E_206D_206B_202B_206A_202A_202D_202A_200D_200E_206F_206C_200D_202C_200C_206D_200B_206E_206C_206E_202E_206B_202E((Delegate)eventHandler2, (Delegate)value);
|
|
eventHandler = Interlocked.CompareExchange(ref this.m_ShopClosed, value2, eventHandler2);
|
|
num = (((object)eventHandler != eventHandler2) ? 1747740711 : 1747740710);
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
[CompilerGenerated]
|
|
remove
|
|
{
|
|
EventHandler eventHandler = this.m_ShopClosed;
|
|
int num = 34666078;
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = 34666076;
|
|
int num4 = num2;
|
|
switch ((num4 | num3) - (num4 & num3))
|
|
{
|
|
case 0:
|
|
num = 34666078;
|
|
break;
|
|
case 1:
|
|
return;
|
|
case 2:
|
|
{
|
|
EventHandler eventHandler2 = eventHandler;
|
|
EventHandler value2 = (EventHandler)_200B_200F_200D_200E_200E_206D_200C_206C_206F_200B_202C_202C_206F_202C_202B_206D_206A_202B_206C_202C_206E_200C_200D_202E_200D_202A_202A_200B_202C_202B_206B_200F_206B_200E_206A_206C_200F_200D_200F_206D_202E((Delegate)eventHandler2, (Delegate)value);
|
|
eventHandler = Interlocked.CompareExchange(ref this.m_ShopClosed, value2, eventHandler2);
|
|
num = (((object)eventHandler != eventHandler2) ? 34666078 : 34666077);
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
[MethodImpl(MethodImplOptions.NoInlining)]
|
|
public GrandCompanyShop(IPluginLog pluginLog, IGameGui gameGui, IAddonLifecycle addonLifecycle, IDataManager dataManager)
|
|
{
|
|
_206D_202D_200F_202D_200D_206A_200F_206C_202D_202C_200F_200D_206D_206E_206B_200D_202A_200D_206E_206A_206C_200D_206F_200F_206D_200C_200D_200F_206E_200F_206A_200C_206B_206B_202B_202E_206D_200B_200B_206A_202E((object)pluginLog, global::_003CModule_003E._206A_202C_200C_206F_202A_200C_200F_206F_202B_202B_200D_206F_206D_200E_206A_206B_202A_200F_200B_206C_202B_202A_202B_206C_200F_206C_202C_202C_200C_206C_206F_200C_200B_202D_200E_202A_202A_206B_206B_200F_202E<string>(1267946466));
|
|
_206D_202D_200F_202D_200D_206A_200F_206C_202D_202C_200F_200D_206D_206E_206B_200D_202A_200D_206E_206A_206C_200D_206F_200F_206D_200C_200D_200F_206E_200F_206A_200C_206B_206B_202B_202E_206D_200B_200B_206A_202E((object)gameGui, global::_003CModule_003E._206E_202B_206C_202A_202A_200E_202B_202B_206D_200B_200C_206B_200B_206D_202E_202D_206C_202B_200B_206A_202D_206C_202A_200F_202D_200C_200B_200B_200B_200D_202C_206E_206D_202E_200C_206B_206A_206D_202D_202C_202E<string>(-89144403));
|
|
_206D_202D_200F_202D_200D_206A_200F_206C_202D_202C_200F_200D_206D_206E_206B_200D_202A_200D_206E_206A_206C_200D_206F_200F_206D_200C_200D_200F_206E_200F_206A_200C_206B_206B_202B_202E_206D_200B_200B_206A_202E((object)addonLifecycle, global::_003CModule_003E._202E_202C_206D_206B_202B_202D_206D_202E_206F_202E_202A_206A_206A_202B_206A_202D_202C_206C_206B_202C_206E_202B_200E_206E_206A_206C_200D_200D_200F_200B_202C_200B_200E_206F_202C_200F_202D_202A_206E_202B_202E<string>(1756451262));
|
|
_206D_202D_200F_202D_200D_206A_200F_206C_202D_202C_200F_200D_206D_206E_206B_200D_202A_200D_206E_206A_206C_200D_206F_200F_206D_200C_200D_200F_206E_200F_206A_200C_206B_206B_202B_202E_206D_200B_200B_206A_202E((object)dataManager, global::_003CModule_003E._202E_202C_206D_206B_202B_202D_206D_202E_206F_202E_202A_206A_206A_202B_206A_202D_202C_206C_206B_202C_206E_202B_200E_206E_206A_206C_200D_200D_200F_200B_202C_200B_200E_206F_202C_200F_202D_202A_206E_202B_202E<string>(167281534));
|
|
_pluginLog = pluginLog;
|
|
_gameGui = gameGui;
|
|
_addonLifecycle = addonLifecycle;
|
|
_itemSheet = dataManager.GetExcelSheet<Item>();
|
|
_202A_206B_206F_206E_202E_206A_202B_202C_200E_202A_200C_200C_200B_200E_206B_202E_202E_202C_200B_202D_206F_206A_206C_206F_200B_206A_206A_202B_206F_206B_200B_206A_200C_206B_202E_206E_200F_202E_200E_200D_202E(_addonLifecycle, AddonEvent.PostSetup, global::_003CModule_003E._206A_206D_202C_206E_206D_206E_202A_200F_200D_206A_200F_206C_202C_202D_206D_206A_200D_200F_206A_206C_202C_206D_206E_200F_200F_200C_206B_200B_206B_206E_202B_206B_200E_200E_200B_206F_200F_202E_200C_200C_202E<string>(1178205757), (IAddonLifecycle.AddonEventDelegate)OnShopPostSetup);
|
|
_202A_206B_206F_206E_202E_206A_202B_202C_200E_202A_200C_200C_200B_200E_206B_202E_202E_202C_200B_202D_206F_206A_206C_206F_200B_206A_206A_202B_206F_206B_200B_206A_200C_206B_202E_206E_200F_202E_200E_200D_202E(_addonLifecycle, AddonEvent.PreFinalize, global::_003CModule_003E._202E_202C_206D_206B_202B_202D_206D_202E_206F_202E_202A_206A_206A_202B_206A_202D_202C_206C_206B_202C_206E_202B_200E_206E_206A_206C_200D_200D_200F_200B_202C_200B_200E_206F_202C_200F_202D_202A_206E_202B_202E<string>(-1848412387), (IAddonLifecycle.AddonEventDelegate)OnShopPreFinalize);
|
|
_202A_206B_206F_206E_202E_206A_202B_202C_200E_202A_200C_200C_200B_200E_206B_202E_202E_202C_200B_202D_206F_206A_206C_206F_200B_206A_206A_202B_206F_206B_200B_206A_200C_206B_202E_206E_200F_202E_200E_200D_202E(_addonLifecycle, AddonEvent.PostSetup, global::_003CModule_003E._206E_202B_206C_202A_202A_200E_202B_202B_206D_200B_200C_206B_200B_206D_202E_202D_206C_202B_200B_206A_202D_206C_202A_200F_202D_200C_200B_200B_200B_200D_202C_206E_206D_202E_200C_206B_206A_206D_202D_202C_202E<string>(-502173951), (IAddonLifecycle.AddonEventDelegate)OnSelectYesNoPostSetup);
|
|
_202A_206B_206F_206E_202E_206A_202B_202C_200E_202A_200C_200C_200B_200E_206B_202E_202E_202C_200B_202D_206F_206A_206C_206F_200B_206A_206A_202B_206F_206B_200B_206A_200C_206B_202E_206E_200F_202E_200E_200D_202E(_addonLifecycle, AddonEvent.PostUpdate, global::_003CModule_003E._206A_202C_200C_206F_202A_200C_200F_206F_202B_202B_200D_206F_206D_200E_206A_206B_202A_200F_200B_206C_202B_202A_202B_206C_200F_206C_202C_202C_200C_206C_206F_200C_200B_202D_200E_202A_202A_206B_206B_200F_202E<string>(423301839), (IAddonLifecycle.AddonEventDelegate)OnSelectYesNoPostUpdate);
|
|
}
|
|
|
|
[MethodImpl(MethodImplOptions.NoInlining)]
|
|
private void OnShopPostSetup(AddonEvent type, AddonArgs args)
|
|
{
|
|
IsOpen = true;
|
|
_navigationStep = 0;
|
|
_200D_206E_200E_202C_202B_202B_206B_206D_206F_202E_200E_206D_202C_206C_200D_200C_206F_206C_206F_202C_206C_200E_202D_202D_202A_200B_202E_206C_206D_200F_206A_200C_202A_202D_202A_206B_200B_200E_200C_202C_202E(_pluginLog, global::_003CModule_003E._202E_202C_206D_206B_202B_202D_206D_202E_206F_202E_202A_206A_206A_202B_206A_202D_202C_206C_206B_202C_206E_202B_200E_206E_206A_206C_200D_200D_200F_200B_202C_200B_200E_206F_202C_200F_202D_202A_206E_202B_202E<string>(1066347615), Array.Empty<object>());
|
|
this.ShopOpened?.Invoke(this, EventArgs.Empty);
|
|
}
|
|
|
|
[MethodImpl(MethodImplOptions.NoInlining)]
|
|
private void OnShopPreFinalize(AddonEvent type, AddonArgs args)
|
|
{
|
|
uint? num = _pendingPurchase?.ItemId;
|
|
IsOpen = false;
|
|
ResetPurchaseState();
|
|
_200D_206E_200E_202C_202B_202B_206B_206D_206F_202E_200E_206D_202C_206C_200D_200C_206F_206C_206F_202C_206C_200E_202D_202D_202A_200B_202E_206C_206D_200F_206A_200C_202A_202D_202A_206B_200B_200E_200C_202C_202E(_pluginLog, global::_003CModule_003E._202E_202C_206D_206B_202B_202D_206D_202E_206F_202E_202A_206A_206A_202B_206A_202D_202C_206C_206B_202C_206E_202B_200E_206E_206A_206C_200D_200D_200F_200B_202C_200B_200E_206F_202C_200F_202D_202A_206E_202B_202E<string>(666829825), Array.Empty<object>());
|
|
EventHandler? eventHandler = this.ShopClosed;
|
|
if (eventHandler == null)
|
|
{
|
|
goto IL_00d9;
|
|
}
|
|
eventHandler(this, EventArgs.Empty);
|
|
int num2 = -1294964905;
|
|
goto IL_0075;
|
|
IL_00d9:
|
|
num2 = ((!num.HasValue) ? (-1294964908) : (-1294964906));
|
|
goto IL_0075;
|
|
IL_0075:
|
|
while (true)
|
|
{
|
|
int num3 = num2;
|
|
int num4 = -1294964907;
|
|
int num5 = num3;
|
|
switch ((num5 | num4) - (num5 & num4))
|
|
{
|
|
default:
|
|
continue;
|
|
case 0:
|
|
num2 = -1294964905;
|
|
continue;
|
|
case 3:
|
|
{
|
|
EventHandler<PurchaseCompletedEventArgs>? eventHandler2 = this.PurchaseCompleted;
|
|
if (eventHandler2 == null)
|
|
{
|
|
return;
|
|
}
|
|
eventHandler2(this, new PurchaseCompletedEventArgs(num.Value, success: false));
|
|
num2 = -1294964908;
|
|
continue;
|
|
}
|
|
case 2:
|
|
break;
|
|
case 1:
|
|
return;
|
|
}
|
|
break;
|
|
}
|
|
goto IL_00d9;
|
|
}
|
|
|
|
private void OnSelectYesNoPostSetup(AddonEvent type, AddonArgs args)
|
|
{
|
|
int num = ((_pendingPurchase == null) ? 1914486152 : 1914486153);
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = 1914486154;
|
|
int num4 = num2;
|
|
int num5 = num4 + num3;
|
|
int num6 = num4 & num3;
|
|
switch (num5 - (num6 + num6))
|
|
{
|
|
case 1:
|
|
_yesNoArmed = true;
|
|
num = 1914486152;
|
|
break;
|
|
case 2:
|
|
return;
|
|
case 0:
|
|
num = 1914486153;
|
|
break;
|
|
case 3:
|
|
num = ((!IsAwaitingConfirmation) ? 1914486152 : 1914486155);
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
|
|
[MethodImpl(MethodImplOptions.NoInlining)]
|
|
private unsafe void OnSelectYesNoPostUpdate(AddonEvent type, AddonArgs args)
|
|
{
|
|
int num = ((_pendingPurchase == null) ? (-1083928703) : (-1083928698));
|
|
AtkUnitBase* address = default(AtkUnitBase*);
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = -1083928701;
|
|
int num4 = num2;
|
|
int num5 = num4 + num3;
|
|
int num6 = num4 & num3;
|
|
switch (num5 - (num6 + num6))
|
|
{
|
|
case 0:
|
|
address = (AtkUnitBase*)_206F_202E_200B_202E_206B_206B_206B_202A_200C_206C_202D_200C_202E_200C_202D_202E_202E_206B_206B_206D_206E_202D_206F_206B_200D_200C_206F_202D_206B_202E_206E_202E_202C_200F_202E_206A_202A_202A_200F_206D_202E(args).Address;
|
|
num = (LAddon.IsAddonReady(address) ? (-1083928704) : (-1083928699));
|
|
break;
|
|
case 3:
|
|
_yesNoArmed = false;
|
|
_202B_202B_202A_206C_206D_206F_200F_202B_202B_200B_200D_200B_200F_202A_202D_200B_202C_202C_200D_202D_202D_206F_200B_206D_202C_200D_202B_206E_202D_202C_202C_202A_200F_200C_200B_206C_200E_202E_202A_206A_202E(_pluginLog, global::_003CModule_003E._200E_206F_206C_206C_200E_202A_206D_206B_200B_202D_202B_200F_200F_206B_206C_206F_202D_206F_206A_202D_206A_200B_200B_202B_202D_202C_200F_200D_202E_200E_200D_202A_202B_206F_202E_200E_200B_206B_200E_202E_202E<string>(-1268211520), Array.Empty<object>());
|
|
AddonCallback.ClickYes(address);
|
|
address->Close(fireCallback: true);
|
|
IsAwaitingConfirmation = false;
|
|
_lastActionMs = _202E_202B_202B_206F_200E_200E_202E_206D_200E_206F_200F_206E_200B_206D_206A_206E_206D_202B_200C_200F_206C_202C_202E_202D_206A_200E_202A_200C_200C_202D_202C_202A_206E_206B_200D_206B_202E_206D_202E_202E();
|
|
return;
|
|
case 2:
|
|
return;
|
|
case 6:
|
|
return;
|
|
case 4:
|
|
num = -1083928698;
|
|
break;
|
|
case 5:
|
|
num = ((!IsAwaitingConfirmation) ? (-1083928703) : (-1083928702));
|
|
break;
|
|
case 1:
|
|
num = (_yesNoArmed ? (-1083928701) : (-1083928703));
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
|
|
[MethodImpl(MethodImplOptions.NoInlining)]
|
|
public bool StartPurchase(uint itemId, int rankTabIndex, int categoryTabIndex, int quantity)
|
|
{
|
|
int num = ((!IsOpen) ? 1313706852 : 1313706855);
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = 1313706853;
|
|
int num4 = num2;
|
|
switch ((num4 | num3) - (num4 & num3))
|
|
{
|
|
case 0:
|
|
num = 1313706855;
|
|
break;
|
|
case 1:
|
|
return false;
|
|
case 3:
|
|
{
|
|
_pendingPurchase = new GrandCompanyPurchaseRequest
|
|
{
|
|
ItemId = itemId,
|
|
RankTabIndex = rankTabIndex,
|
|
CategoryTabIndex = categoryTabIndex,
|
|
DesiredQuantity = quantity
|
|
};
|
|
_navigationStep = 0;
|
|
_lastActionMs = 0L;
|
|
_itemCountBeforePurchase = -1;
|
|
IPluginLog pluginLog = _pluginLog;
|
|
DefaultInterpolatedStringHandler defaultInterpolatedStringHandler = new DefaultInterpolatedStringHandler(37, 2);
|
|
defaultInterpolatedStringHandler.AppendLiteral(global::_003CModule_003E._200E_206F_206C_206C_200E_202A_206D_206B_200B_202D_202B_200F_200F_206B_206C_206F_202D_206F_206A_202D_206A_200B_200B_202B_202D_202C_200F_200D_202E_200E_200D_202A_202B_206F_202E_200E_200B_206B_200E_202E_202E<string>(243895174));
|
|
defaultInterpolatedStringHandler.AppendFormatted(quantity);
|
|
defaultInterpolatedStringHandler.AppendLiteral(global::_003CModule_003E._202E_202C_206D_206B_202B_202D_206D_202E_206F_202E_202A_206A_206A_202B_206A_202D_202C_206C_206B_202C_206E_202B_200E_206E_206A_206C_200D_200D_200F_200B_202C_200B_200E_206F_202C_200F_202D_202A_206E_202B_202E<string>(1293415020));
|
|
defaultInterpolatedStringHandler.AppendFormatted(itemId);
|
|
_202B_202B_202A_206C_206D_206F_200F_202B_202B_200B_200D_200B_200F_202A_202D_200B_202C_202C_200D_202D_202D_206F_200B_206D_202C_200D_202B_206E_202D_202C_202C_202A_200F_200C_200B_206C_200E_202E_202A_206A_202E(pluginLog, defaultInterpolatedStringHandler.ToStringAndClear(), Array.Empty<object>());
|
|
return true;
|
|
}
|
|
case 2:
|
|
num = ((_pendingPurchase == null) ? 1313706854 : 1313706852);
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
|
|
public void CancelPurchase()
|
|
{
|
|
uint? num = _pendingPurchase?.ItemId;
|
|
ResetPurchaseState();
|
|
int num2 = ((!num.HasValue) ? (-828309669) : (-828309670));
|
|
while (true)
|
|
{
|
|
int num3 = num2;
|
|
int num4 = -828309669;
|
|
int num5 = num3;
|
|
switch ((num5 | num4) - (num5 & num4))
|
|
{
|
|
case 2:
|
|
num2 = -828309670;
|
|
break;
|
|
case 0:
|
|
return;
|
|
case 1:
|
|
{
|
|
EventHandler<PurchaseCompletedEventArgs>? eventHandler = this.PurchaseCompleted;
|
|
if (eventHandler == null)
|
|
{
|
|
return;
|
|
}
|
|
eventHandler(this, new PurchaseCompletedEventArgs(num.Value, success: false));
|
|
num2 = -828309669;
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
[MethodImpl(MethodImplOptions.NoInlining)]
|
|
public unsafe bool ProcessPurchase()
|
|
{
|
|
int num = ((_pendingPurchase == null) ? 636680118 : 636680125);
|
|
long num11 = default(long);
|
|
int num10 = default(int);
|
|
int num15 = default(int);
|
|
int maxHoldableQuantity = default(int);
|
|
int inventoryItemCount = default(int);
|
|
InventoryManager* ptr2 = default(InventoryManager*);
|
|
AtkUnitBase* addonPtr = default(AtkUnitBase*);
|
|
InventoryManager* ptr = default(InventoryManager*);
|
|
GrandCompanyItem grandCompanyItem = default(GrandCompanyItem);
|
|
int num12 = default(int);
|
|
int num9 = default(int);
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = 636680111;
|
|
int num4 = num2;
|
|
int num5 = num4 + num3;
|
|
int num6 = num4 & num3;
|
|
int num8;
|
|
int num7;
|
|
int navigationStep2;
|
|
int num16;
|
|
int num17;
|
|
int navigationStep3;
|
|
int num18;
|
|
int num19;
|
|
switch (num5 - (num6 + num6))
|
|
{
|
|
default:
|
|
continue;
|
|
case 13:
|
|
num11 = _202E_202B_202B_206F_200E_200E_202E_206D_200E_206F_200F_206E_200B_206D_206A_206E_206D_202B_200C_200F_206C_202C_202E_202D_206A_200E_202A_200C_200C_202D_202C_202A_206E_206B_200D_206B_202E_206D_202E_202E() - _lastActionMs;
|
|
num = ((num11 >= 100) ? 636680076 : 636680104);
|
|
continue;
|
|
case 1:
|
|
{
|
|
IPluginLog pluginLog3 = _pluginLog;
|
|
DefaultInterpolatedStringHandler defaultInterpolatedStringHandler3 = new DefaultInterpolatedStringHandler(61, 4);
|
|
defaultInterpolatedStringHandler3.AppendLiteral(global::_003CModule_003E._206A_206D_202C_206E_206D_206E_202A_200F_200D_206A_200F_206C_202C_202D_206D_206A_200D_200F_206A_206C_202C_206D_206E_200F_200F_200C_206B_200B_206B_206E_202B_206B_200E_200E_200B_206F_200F_202E_200C_200C_202E<string>(-2005174402));
|
|
defaultInterpolatedStringHandler3.AppendFormatted(_pendingPurchase.ItemId);
|
|
defaultInterpolatedStringHandler3.AppendLiteral(global::_003CModule_003E._202E_202C_206D_206B_202B_202D_206D_202E_206F_202E_202A_206A_206A_202B_206A_202D_202C_206C_206B_202C_206E_202B_200E_206E_206A_206C_200D_200D_200F_200B_202C_200B_200E_206F_202C_200F_202D_202A_206E_202B_202E<string>(-2111689734));
|
|
defaultInterpolatedStringHandler3.AppendFormatted(num10);
|
|
defaultInterpolatedStringHandler3.AppendLiteral(global::_003CModule_003E._206E_202B_206C_202A_202A_200E_202B_202B_206D_200B_200C_206B_200B_206D_202E_202D_206C_202B_200B_206A_202D_206C_202A_200F_202D_200C_200B_200B_200B_200D_202C_206E_206D_202E_200C_206B_206A_206D_202D_202C_202E<string>(-356398602));
|
|
defaultInterpolatedStringHandler3.AppendFormatted(num15);
|
|
defaultInterpolatedStringHandler3.AppendLiteral(global::_003CModule_003E._200E_206F_206C_206C_200E_202A_206D_206B_200B_202D_202B_200F_200F_206B_206C_206F_202D_206F_206A_202D_206A_200B_200B_202B_202D_202C_200F_200D_202E_200E_200D_202A_202B_206F_202E_200E_200B_206B_200E_202E_202E<string>(-967737798));
|
|
defaultInterpolatedStringHandler3.AppendFormatted(maxHoldableQuantity);
|
|
_200E_202D_200D_200E_202A_200F_202D_206A_206A_200E_202B_206F_202C_200F_206F_206D_200C_202D_200B_206F_206E_200F_200C_206B_200D_206C_206B_200F_200F_206C_200C_202B_206D_200F_202A_202D_200D_206C_202E_206C_202E(pluginLog3, defaultInterpolatedStringHandler3.ToStringAndClear(), Array.Empty<object>());
|
|
CancelPurchase();
|
|
num = 636680108;
|
|
continue;
|
|
}
|
|
case 8:
|
|
num = 636680108;
|
|
continue;
|
|
case 35:
|
|
num = ((num11 < 3000) ? 636680117 : 636680114);
|
|
continue;
|
|
case 18:
|
|
num = (IsOpen ? 636680123 : 636680118);
|
|
continue;
|
|
case 30:
|
|
num = ((_navigationStep != 0) ? 636680074 : 636680079);
|
|
continue;
|
|
case 2:
|
|
switch (_navigationStep)
|
|
{
|
|
case 2:
|
|
goto IL_048f;
|
|
case 0:
|
|
goto IL_0509;
|
|
case 1:
|
|
goto IL_0597;
|
|
case 3:
|
|
goto end_IL_003b;
|
|
}
|
|
num = 636680103;
|
|
continue;
|
|
case 29:
|
|
{
|
|
IPluginLog pluginLog5 = _pluginLog;
|
|
DefaultInterpolatedStringHandler defaultInterpolatedStringHandler5 = new DefaultInterpolatedStringHandler(66, 1);
|
|
defaultInterpolatedStringHandler5.AppendLiteral(global::_003CModule_003E._206A_202C_200C_206F_202A_200C_200F_206F_202B_202B_200D_206F_206D_200E_206A_206B_202A_200F_200B_206C_202B_202A_202B_206C_200F_206C_202C_202C_200C_206C_206F_200C_200B_202D_200E_202A_202A_206B_206B_200F_202E<string>(-47133297));
|
|
defaultInterpolatedStringHandler5.AppendFormatted(3000);
|
|
defaultInterpolatedStringHandler5.AppendLiteral(global::_003CModule_003E._200E_206F_206C_206C_200E_202A_206D_206B_200B_202D_202B_200F_200F_206B_206C_206F_202D_206F_206A_202D_206A_200B_200B_202B_202D_202C_200F_200D_202E_200E_200D_202A_202B_206F_202E_200E_200B_206B_200E_202E_202E<string>(1573770018));
|
|
_200E_202D_200D_200E_202A_200F_202D_206A_206A_200E_202B_206F_202C_200F_206F_206D_200C_202D_200B_206F_206E_200F_200C_206B_200D_206C_206B_200F_200F_206C_200C_202B_206D_200F_202A_202D_200D_206C_202E_206C_202E(pluginLog5, defaultInterpolatedStringHandler5.ToStringAndClear(), Array.Empty<object>());
|
|
CancelPurchase();
|
|
return false;
|
|
}
|
|
case 9:
|
|
{
|
|
IPluginLog pluginLog4 = _pluginLog;
|
|
DefaultInterpolatedStringHandler defaultInterpolatedStringHandler4 = new DefaultInterpolatedStringHandler(32, 1);
|
|
defaultInterpolatedStringHandler4.AppendLiteral(global::_003CModule_003E._206A_206D_202C_206E_206D_206E_202A_200F_200D_206A_200F_206C_202C_202D_206D_206A_200D_200F_206A_206C_202C_206D_206E_200F_200F_200C_206B_200B_206B_206E_202B_206B_200E_200E_200B_206F_200F_202E_200C_200C_202E<string>(-701323076));
|
|
defaultInterpolatedStringHandler4.AppendFormatted(_pendingPurchase.ItemId);
|
|
defaultInterpolatedStringHandler4.AppendLiteral(global::_003CModule_003E._206A_202C_200C_206F_202A_200C_200F_206F_202B_202B_200D_206F_206D_200E_206A_206B_202A_200F_200B_206C_202B_202A_202B_206C_200F_206C_202C_202C_200C_206C_206F_200C_200B_202D_200E_202A_202A_206B_206B_200F_202E<string>(-229047175));
|
|
_200E_202D_200D_200E_202A_200F_202D_206A_206A_200E_202B_206F_202C_200F_206F_206D_200C_202D_200B_206F_206E_200F_200C_206B_200D_206C_206B_200F_200F_206C_200C_202B_206D_200F_202A_202D_200D_206C_202E_206C_202E(pluginLog4, defaultInterpolatedStringHandler4.ToStringAndClear(), Array.Empty<object>());
|
|
CancelPurchase();
|
|
num = 636680108;
|
|
continue;
|
|
}
|
|
case 14:
|
|
inventoryItemCount = ptr2->GetInventoryItemCount(_pendingPurchase.ItemId, isHq: false, checkEquipped: true, checkArmory: true, 0);
|
|
num = ((inventoryItemCount < _pendingPurchase.DesiredQuantity) ? 636680074 : 636680105);
|
|
continue;
|
|
case 20:
|
|
ptr2 = InventoryManager.Instance();
|
|
num = ((ptr2 == null) ? 636680074 : 636680113);
|
|
continue;
|
|
case 26:
|
|
num = ((_navigationStep != 2) ? 636680127 : 636680106);
|
|
continue;
|
|
case 7:
|
|
return false;
|
|
case 6:
|
|
{
|
|
IPluginLog pluginLog = _pluginLog;
|
|
DefaultInterpolatedStringHandler defaultInterpolatedStringHandler = new DefaultInterpolatedStringHandler(37, 3);
|
|
defaultInterpolatedStringHandler.AppendLiteral(global::_003CModule_003E._202E_202C_206D_206B_202B_202D_206D_202E_206F_202E_202A_206A_206A_202B_206A_202D_202C_206C_206B_202C_206E_202B_200E_206E_206A_206C_200D_200D_200F_200B_202C_200B_200E_206F_202C_200F_202D_202A_206E_202B_202E<string>(848483749));
|
|
defaultInterpolatedStringHandler.AppendFormatted(inventoryItemCount);
|
|
defaultInterpolatedStringHandler.AppendLiteral(global::_003CModule_003E._206A_202C_200C_206F_202A_200C_200F_206F_202B_202B_200D_206F_206D_200E_206A_206B_202A_200F_200B_206C_202B_202A_202B_206C_200F_206C_202C_202C_200C_206C_206F_200C_200B_202D_200E_202A_202A_206B_206B_200F_202E<string>(245261652));
|
|
defaultInterpolatedStringHandler.AppendFormatted(_pendingPurchase.ItemId);
|
|
defaultInterpolatedStringHandler.AppendLiteral(global::_003CModule_003E._206E_202B_206C_202A_202A_200E_202B_202B_206D_200B_200C_206B_200B_206D_202E_202D_206C_202B_200B_206A_202D_206C_202A_200F_202D_200C_200B_200B_200B_200D_202C_206E_206D_202E_200C_206B_206A_206D_202D_202C_202E<string>(1873420954));
|
|
defaultInterpolatedStringHandler.AppendFormatted(_pendingPurchase.DesiredQuantity);
|
|
defaultInterpolatedStringHandler.AppendLiteral(global::_003CModule_003E._202E_202C_206D_206B_202B_202D_206D_202E_206F_202E_202A_206A_206A_202B_206A_202D_202C_206C_206B_202C_206E_202B_200E_206E_206A_206C_200D_200D_200F_200B_202C_200B_200E_206F_202C_200F_202D_202A_206E_202B_202E<string>(-2066276253));
|
|
_202B_202B_202A_206C_206D_206F_200F_202B_202B_200B_200D_200B_200F_202A_202D_200B_202C_202C_200D_202D_202D_206F_200B_206D_202C_200D_202B_206E_202D_202C_202C_202A_200F_200C_200B_206C_200E_202E_202A_206A_202E(pluginLog, defaultInterpolatedStringHandler.ToStringAndClear(), Array.Empty<object>());
|
|
uint itemId = _pendingPurchase.ItemId;
|
|
ResetPurchaseState();
|
|
EventHandler<PurchaseCompletedEventArgs>? eventHandler = this.PurchaseCompleted;
|
|
if (eventHandler == null)
|
|
{
|
|
goto case 27;
|
|
}
|
|
eventHandler(this, new PurchaseCompletedEventArgs(itemId, success: true));
|
|
num = 636680116;
|
|
continue;
|
|
}
|
|
case 32:
|
|
num = ((_itemCountBeforePurchase != -1) ? 636680074 : 636680097);
|
|
continue;
|
|
case 19:
|
|
goto IL_048f;
|
|
case 37:
|
|
num = ((!_gameGui.TryGetAddonByName<AtkUnitBase>(global::_003CModule_003E._202E_202C_206D_206B_202B_202D_206D_202E_206F_202E_202A_206A_206A_202B_206A_202D_202C_206C_206B_202C_206E_202B_200E_206E_206A_206C_200D_200D_200F_200B_202C_200B_200E_206F_202C_200F_202D_202A_206E_202B_202E<string>(-1848412387), out addonPtr)) ? 636680112 : 636680101);
|
|
continue;
|
|
case 4:
|
|
return false;
|
|
case 11:
|
|
num8 = 0;
|
|
goto IL_07ab;
|
|
case 22:
|
|
goto IL_0509;
|
|
case 28:
|
|
ptr = InventoryManager.Instance();
|
|
num = ((ptr != null) ? 636680096 : 636680122);
|
|
continue;
|
|
case 34:
|
|
num = 636680125;
|
|
continue;
|
|
case 33:
|
|
goto IL_0597;
|
|
case 17:
|
|
num = ((!_awaitingAddonReady) ? 636680109 : 636680098);
|
|
continue;
|
|
case 36:
|
|
{
|
|
IPluginLog pluginLog2 = _pluginLog;
|
|
DefaultInterpolatedStringHandler defaultInterpolatedStringHandler2 = new DefaultInterpolatedStringHandler(61, 4);
|
|
defaultInterpolatedStringHandler2.AppendLiteral(global::_003CModule_003E._206E_202B_206C_202A_202A_200E_202B_202B_206D_200B_200C_206B_200B_206D_202E_202D_206C_202B_200B_206A_202D_206C_202A_200F_202D_200C_200B_200B_200B_200D_202C_206E_206D_202E_200C_206B_206A_206D_202D_202C_202E<string>(979872393));
|
|
defaultInterpolatedStringHandler2.AppendFormatted(grandCompanyItem.ItemId);
|
|
defaultInterpolatedStringHandler2.AppendLiteral(global::_003CModule_003E._206E_202B_206C_202A_202A_200E_202B_202B_206D_200B_200C_206B_200B_206D_202E_202D_206C_202B_200B_206A_202D_206C_202A_200F_202D_200C_200B_200B_200B_200D_202C_206E_206D_202E_200C_206B_206A_206D_202D_202C_202E<string>(2094782171));
|
|
defaultInterpolatedStringHandler2.AppendFormatted(grandCompanyItem.Index);
|
|
defaultInterpolatedStringHandler2.AppendLiteral(global::_003CModule_003E._200E_206F_206C_206C_200E_202A_206D_206B_200B_202D_202B_200F_200F_206B_206C_206F_202D_206F_206A_202D_206A_200B_200B_202B_202D_202C_200F_200D_202E_200E_200D_202A_202B_206F_202E_200E_200B_206B_200E_202E_202E<string>(889356428));
|
|
defaultInterpolatedStringHandler2.AppendFormatted(num12);
|
|
defaultInterpolatedStringHandler2.AppendLiteral(global::_003CModule_003E._206A_202C_200C_206F_202A_200C_200F_206F_202B_202B_200D_206F_206D_200E_206A_206B_202A_200F_200B_206C_202B_202A_202B_206C_200F_206C_202C_202C_200C_206C_206F_200C_200B_202D_200E_202A_202A_206B_206B_200F_202E<string>(-326512158));
|
|
defaultInterpolatedStringHandler2.AppendFormatted(num9);
|
|
defaultInterpolatedStringHandler2.AppendLiteral(global::_003CModule_003E._200E_206F_206C_206C_200E_202A_206D_206B_200B_202D_202B_200F_200F_206B_206C_206F_202D_206F_206A_202D_206A_200B_200B_202B_202D_202C_200F_200D_202E_200E_200D_202A_202B_206F_202E_200E_200B_206B_200E_202E_202E<string>(-361921312));
|
|
_202B_202B_202A_206C_206D_206F_200F_202B_202B_200B_200D_200B_200F_202A_202D_200B_202C_202C_200D_202D_202D_206F_200B_206D_202C_200D_202B_206E_202D_202C_202C_202A_200F_200C_200B_206C_200E_202E_202A_206A_202E(pluginLog2, defaultInterpolatedStringHandler2.ToStringAndClear(), Array.Empty<object>());
|
|
FirePurchaseCallback(addonPtr, grandCompanyItem, num12);
|
|
IsAwaitingConfirmation = true;
|
|
int navigationStep = _navigationStep;
|
|
num3 = 1;
|
|
num4 = navigationStep;
|
|
int num13 = num4 ^ num3;
|
|
int num14 = num4 & num3;
|
|
_navigationStep = num13 + (num14 + num14);
|
|
_lastActionMs = _202E_202B_202B_206F_200E_200E_202E_206D_200E_206F_200F_206E_200B_206D_206A_206E_206D_202B_200C_200F_206C_202C_202E_202D_206A_200E_202A_200C_200C_202D_202C_202A_206E_206B_200D_206B_202E_206D_202E_202E();
|
|
num = 636680108;
|
|
continue;
|
|
}
|
|
case 21:
|
|
num7 = 0;
|
|
goto IL_0814;
|
|
case 25:
|
|
return false;
|
|
case 5:
|
|
num = ((GetAtkValueInt(addonPtr, 1) > 0) ? 636680127 : 636680107);
|
|
continue;
|
|
case 12:
|
|
_pendingPurchase.InitialCount = num9;
|
|
num = 636680119;
|
|
continue;
|
|
case 31:
|
|
return false;
|
|
case 27:
|
|
return true;
|
|
case 24:
|
|
_itemCountBeforePurchase = num9;
|
|
num10 = _pendingPurchase.DesiredQuantity - (num9 - _pendingPurchase.InitialCount);
|
|
num = ((grandCompanyItem.SealCost != 0) ? 636680120 : 636680100);
|
|
continue;
|
|
case 23:
|
|
num8 = GetCompanySeals() / (int)grandCompanyItem.SealCost;
|
|
goto IL_07ab;
|
|
case 15:
|
|
num7 = ptr->GetInventoryItemCount(_pendingPurchase.ItemId, isHq: false, checkEquipped: true, checkArmory: true, 0);
|
|
goto IL_0814;
|
|
case 3:
|
|
return false;
|
|
case 10:
|
|
num = (LAddon.IsAddonReady(addonPtr) ? 636680126 : 636680112);
|
|
continue;
|
|
case 16:
|
|
_awaitingAddonReady = false;
|
|
num = 636680109;
|
|
continue;
|
|
case 0:
|
|
break;
|
|
IL_048f:
|
|
grandCompanyItem = FindItemInShop(addonPtr, _pendingPurchase.ItemId);
|
|
num = ((grandCompanyItem == null) ? 636680102 : 636680115);
|
|
continue;
|
|
IL_0814:
|
|
num9 = num7;
|
|
num = ((_pendingPurchase.InitialCount != -1) ? 636680119 : 636680099);
|
|
continue;
|
|
IL_07ab:
|
|
num15 = num8;
|
|
maxHoldableQuantity = InventoryHelper.GetMaxHoldableQuantity(_pendingPurchase.ItemId, _itemSheet);
|
|
num12 = _200D_206A_206D_200D_206A_200C_206A_200C_206A_200B_206B_206C_200B_206D_202C_206F_206D_202A_206A_202A_206C_200B_200C_206A_202E_200B_206A_200E_200C_206B_206B_206E_200D_200D_202E_206A_200F_202B_200E_202A_202E(_200D_206A_206D_200D_206A_200C_206A_200C_206A_200B_206B_206C_200B_206D_202C_206F_206D_202A_206A_202A_206C_200B_200C_206A_202E_200B_206A_200E_200C_206B_206B_206E_200D_200D_202E_206A_200F_202B_200E_202A_202E(num10, 99), _200D_206A_206D_200D_206A_200C_206A_200C_206A_200B_206B_206C_200B_206D_202C_206F_206D_202A_206A_202A_206C_200B_200C_206A_202E_200B_206A_200E_200C_206B_206B_206E_200D_200D_202E_206A_200F_202B_200E_202A_202E(num15, maxHoldableQuantity));
|
|
num = ((num12 > 0) ? 636680075 : 636680110);
|
|
continue;
|
|
IL_0597:
|
|
AddonCallback.Fire(addonPtr, 2, _pendingPurchase.CategoryTabIndex);
|
|
navigationStep2 = _navigationStep;
|
|
num3 = 1;
|
|
num4 = navigationStep2;
|
|
num16 = num4 ^ num3;
|
|
num17 = num4 & num3;
|
|
_navigationStep = num16 + (num17 + num17);
|
|
_lastActionMs = _202E_202B_202B_206F_200E_200E_202E_206D_200E_206F_200F_206E_200B_206D_206A_206E_206D_202B_200C_200F_206C_202C_202E_202D_206A_200E_202A_200C_200C_202D_202C_202A_206E_206B_200D_206B_202E_206D_202E_202E();
|
|
_awaitingAddonReady = true;
|
|
num = 636680108;
|
|
continue;
|
|
IL_0509:
|
|
AddonCallback.Fire(addonPtr, 1, _pendingPurchase.RankTabIndex);
|
|
navigationStep3 = _navigationStep;
|
|
num3 = 1;
|
|
num4 = navigationStep3;
|
|
num18 = num4 ^ num3;
|
|
num19 = num4 & num3;
|
|
_navigationStep = num18 + (num19 + num19);
|
|
_lastActionMs = _202E_202B_202B_206F_200E_200E_202E_206D_200E_206F_200F_206E_200B_206D_206A_206E_206D_202B_200C_200F_206C_202C_202E_202D_206A_200E_202A_200C_200C_202D_202C_202A_206E_206B_200D_206B_202E_206D_202E_202E();
|
|
_awaitingAddonReady = true;
|
|
num = 636680108;
|
|
continue;
|
|
end_IL_003b:
|
|
break;
|
|
}
|
|
break;
|
|
}
|
|
return WaitForPurchaseCompletion();
|
|
}
|
|
|
|
[MethodImpl(MethodImplOptions.NoInlining)]
|
|
public unsafe void CloseShop()
|
|
{
|
|
int num = (IsOpen ? (-576018868) : (-576018870));
|
|
AtkUnitBase* addonPtr = default(AtkUnitBase*);
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = -576018872;
|
|
int num4 = num2;
|
|
switch ((num4 | num3) - (num4 & num3))
|
|
{
|
|
case 1:
|
|
addonPtr->Close(fireCallback: true);
|
|
num = -576018869;
|
|
break;
|
|
case 3:
|
|
return;
|
|
case 2:
|
|
return;
|
|
case 0:
|
|
num = -576018870;
|
|
break;
|
|
case 4:
|
|
num = ((!_gameGui.TryGetAddonByName<AtkUnitBase>(global::_003CModule_003E._206A_206D_202C_206E_206D_206E_202A_200F_200D_206A_200F_206C_202C_202D_206D_206A_200D_200F_206A_206C_202C_206D_206E_200F_200F_200C_206B_200B_206B_206E_202B_206B_200E_200E_200B_206F_200F_202E_200C_200C_202E<string>(1178205757), out addonPtr)) ? (-576018869) : (-576018871));
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
|
|
public unsafe static int GetCompanySeals()
|
|
{
|
|
InventoryManager* ptr = InventoryManager.Instance();
|
|
PlayerState* ptr2 = PlayerState.Instance();
|
|
int num = ((ptr == null) ? 1253116757 : 1253116759);
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = 1253116758;
|
|
int num4 = num2;
|
|
int num5 = num4 + num3;
|
|
int num6 = num4 & num3;
|
|
switch (num5 - (num6 + num6))
|
|
{
|
|
case 3:
|
|
return 0;
|
|
case 1:
|
|
num = ((ptr2 != null) ? 1253116758 : 1253116757);
|
|
break;
|
|
case 2:
|
|
num = 1253116759;
|
|
break;
|
|
case 0:
|
|
return (int)ptr->GetCompanySeals(ptr2->GrandCompany);
|
|
}
|
|
}
|
|
}
|
|
|
|
[MethodImpl(MethodImplOptions.NoInlining)]
|
|
public unsafe ReadOnlyCollection<GrandCompanyItem> GetAvailableItems()
|
|
{
|
|
int num = ((!IsOpen) ? 1134948284 : 1134948272);
|
|
int atkValueInt2 = default(int);
|
|
AtkUnitBase* addonPtr = default(AtkUnitBase*);
|
|
List<GrandCompanyItem> list2 = default(List<GrandCompanyItem>);
|
|
int num6 = default(int);
|
|
int atkValueInt = default(int);
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = 1134948277;
|
|
int num4 = num2;
|
|
switch ((num4 | num3) - (num4 & num3))
|
|
{
|
|
case 7:
|
|
atkValueInt2 = GetAtkValueInt(addonPtr, 1);
|
|
list2 = new List<GrandCompanyItem>(atkValueInt2);
|
|
num6 = 0;
|
|
num = 1134948277;
|
|
break;
|
|
case 2:
|
|
num = (LAddon.IsAddonReady(addonPtr) ? 1134948274 : 1134948284);
|
|
break;
|
|
case 4:
|
|
return list2.AsReadOnly();
|
|
case 3:
|
|
{
|
|
AtkUnitBase* addon = addonPtr;
|
|
num3 = num6;
|
|
num4 = 317;
|
|
atkValueInt = GetAtkValueInt(addon, (num4 | num3) + (num4 & num3));
|
|
num = ((atkValueInt <= 0) ? 1134948276 : 1134948275);
|
|
break;
|
|
}
|
|
case 9:
|
|
return EmptyItems;
|
|
case 8:
|
|
num = 1134948272;
|
|
break;
|
|
case 0:
|
|
num = ((num6 < atkValueInt2) ? 1134948278 : 1134948273);
|
|
break;
|
|
case 6:
|
|
{
|
|
List<GrandCompanyItem> list = list2;
|
|
GrandCompanyItem obj = new GrandCompanyItem
|
|
{
|
|
Index = num6,
|
|
ItemId = (uint)atkValueInt
|
|
};
|
|
AtkUnitBase* addon2 = addonPtr;
|
|
num3 = num6;
|
|
num4 = 167;
|
|
int num7 = num4 ^ num3;
|
|
int num8 = num4 & num3;
|
|
obj.IconId = (uint)GetAtkValueInt(addon2, num7 + (num8 + num8));
|
|
AtkUnitBase* addon3 = addonPtr;
|
|
num3 = num6;
|
|
num4 = 67;
|
|
int num9 = num4 ^ num3;
|
|
int num10 = num4 & num3;
|
|
obj.SealCost = (uint)GetAtkValueInt(addon3, num9 + (num10 + num10));
|
|
list.Add(obj);
|
|
num = 1134948276;
|
|
break;
|
|
}
|
|
case 5:
|
|
num = ((!_gameGui.TryGetAddonByName<AtkUnitBase>(global::_003CModule_003E._206A_206D_202C_206E_206D_206E_202A_200F_200D_206A_200F_206C_202C_202D_206D_206A_200D_200F_206A_206C_202C_206D_206E_200F_200F_200C_206B_200B_206B_206E_202B_206B_200E_200E_200B_206F_200F_202E_200C_200C_202E<string>(1178205757), out addonPtr)) ? 1134948284 : 1134948279);
|
|
break;
|
|
case 1:
|
|
{
|
|
int num5 = num6;
|
|
num3 = 1;
|
|
num4 = num5;
|
|
num6 = (num4 | num3) + (num4 & num3);
|
|
num = 1134948277;
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
private unsafe static GrandCompanyItem? FindItemInShop(AtkUnitBase* addon, uint targetItemId)
|
|
{
|
|
int atkValueInt = GetAtkValueInt(addon, 1);
|
|
int num = ((atkValueInt > 0) ? 1303324821 : 1303324817);
|
|
int num5 = default(int);
|
|
int atkValueInt2 = default(int);
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = 1303324819;
|
|
int num4 = num2;
|
|
switch ((num4 | num3) - (num4 & num3))
|
|
{
|
|
case 4:
|
|
return null;
|
|
case 2:
|
|
return null;
|
|
case 0:
|
|
num = 1303324817;
|
|
break;
|
|
case 1:
|
|
{
|
|
int num8 = num5;
|
|
num3 = 1;
|
|
num4 = num8;
|
|
int num9 = num4 ^ num3;
|
|
int num10 = num4 & num3;
|
|
num5 = num9 + (num10 + num10);
|
|
num = 1303324816;
|
|
break;
|
|
}
|
|
case 3:
|
|
num = ((num5 < atkValueInt) ? 1303324822 : 1303324823);
|
|
break;
|
|
case 6:
|
|
num5 = 0;
|
|
num = 1303324816;
|
|
break;
|
|
case 7:
|
|
{
|
|
GrandCompanyItem obj = new GrandCompanyItem
|
|
{
|
|
Index = num5,
|
|
ItemId = (uint)atkValueInt2
|
|
};
|
|
num3 = num5;
|
|
num4 = 167;
|
|
int num11 = num4 ^ num3;
|
|
int num12 = num4 & num3;
|
|
obj.IconId = (uint)GetAtkValueInt(addon, num11 + (num12 + num12));
|
|
num3 = num5;
|
|
num4 = 67;
|
|
int num13 = num4 ^ num3;
|
|
int num14 = num4 & num3;
|
|
obj.SealCost = (uint)GetAtkValueInt(addon, num13 + (num14 + num14));
|
|
return obj;
|
|
}
|
|
case 5:
|
|
{
|
|
num3 = num5;
|
|
num4 = 317;
|
|
int num6 = num4 ^ num3;
|
|
int num7 = num4 & num3;
|
|
atkValueInt2 = GetAtkValueInt(addon, num6 + (num7 + num7));
|
|
num = ((atkValueInt2 != (int)targetItemId) ? 1303324818 : 1303324820);
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
[MethodImpl(MethodImplOptions.NoInlining)]
|
|
private unsafe bool WaitForPurchaseCompletion()
|
|
{
|
|
long num = _202E_202B_202B_206F_200E_200E_202E_206D_200E_206F_200F_206E_200B_206D_206A_206E_206D_202B_200C_200F_206C_202C_202E_202D_206A_200E_202A_200C_200C_202D_202C_202A_206E_206B_200D_206B_202E_206D_202E_202E() - _lastActionMs;
|
|
int num2 = ((!IsAwaitingConfirmation) ? 1518393876 : 1518393882);
|
|
int num8 = default(int);
|
|
InventoryManager* ptr = default(InventoryManager*);
|
|
while (true)
|
|
{
|
|
int num3 = num2;
|
|
int num4 = 1518393887;
|
|
int num5 = num3;
|
|
int num6 = num5 + num4;
|
|
int num7 = num5 & num4;
|
|
switch (num6 - (num7 + num7))
|
|
{
|
|
case 2:
|
|
num2 = 1518393882;
|
|
break;
|
|
case 7:
|
|
return false;
|
|
case 8:
|
|
{
|
|
IPluginLog pluginLog3 = _pluginLog;
|
|
DefaultInterpolatedStringHandler defaultInterpolatedStringHandler3 = new DefaultInterpolatedStringHandler(33, 2);
|
|
defaultInterpolatedStringHandler3.AppendLiteral(global::_003CModule_003E._206A_206D_202C_206E_206D_206E_202A_200F_200D_206A_200F_206C_202C_202D_206D_206A_200D_200F_206A_206C_202C_206D_206E_200F_200F_200C_206B_200B_206B_206E_202B_206B_200E_200E_200B_206F_200F_202E_200C_200C_202E<string>(32368461));
|
|
defaultInterpolatedStringHandler3.AppendFormatted(num8);
|
|
defaultInterpolatedStringHandler3.AppendLiteral(global::_003CModule_003E._206A_206D_202C_206E_206D_206E_202A_200F_200D_206A_200F_206C_202C_202D_206D_206A_200D_200F_206A_206C_202C_206D_206E_200F_200F_200C_206B_200B_206B_206E_202B_206B_200E_200E_200B_206F_200F_202E_200C_200C_202E<string>(640094798));
|
|
defaultInterpolatedStringHandler3.AppendFormatted(_pendingPurchase.ItemId);
|
|
defaultInterpolatedStringHandler3.AppendLiteral(global::_003CModule_003E._202E_202C_206D_206B_202B_202D_206D_202E_206F_202E_202A_206A_206A_202B_206A_202D_202C_206C_206B_202C_206E_202B_200E_206E_206A_206C_200D_200D_200F_200B_202C_200B_200E_206F_202C_200F_202D_202A_206E_202B_202E<string>(-1848110280));
|
|
_202B_202B_202A_206C_206D_206F_200F_202B_202B_200B_200D_200B_200F_202A_202D_200B_202C_202C_200D_202D_202D_206F_200B_206D_202C_200D_202B_206E_202D_202C_202C_202A_200F_200C_200B_206C_200E_202E_202A_206A_202E(pluginLog3, defaultInterpolatedStringHandler3.ToStringAndClear(), Array.Empty<object>());
|
|
uint itemId = _pendingPurchase.ItemId;
|
|
int quantityPurchased = num8;
|
|
ResetPurchaseState();
|
|
EventHandler<PurchaseCompletedEventArgs>? eventHandler = this.PurchaseCompleted;
|
|
if (eventHandler == null)
|
|
{
|
|
goto case 4;
|
|
}
|
|
eventHandler(this, new PurchaseCompletedEventArgs(itemId, success: true, quantityPurchased));
|
|
num2 = 1518393883;
|
|
break;
|
|
}
|
|
case 3:
|
|
return false;
|
|
case 0:
|
|
_200E_202D_200D_200E_202A_200F_202D_206A_206A_200E_202B_206F_202C_200F_206F_206D_200C_202D_200B_206F_206E_200F_200C_206B_200D_206C_206B_200F_200F_206C_200C_202B_206D_200F_202A_202D_200D_206C_202E_206C_202E(_pluginLog, global::_003CModule_003E._206A_202C_200C_206F_202A_200C_200F_206F_202B_202B_200D_206F_206D_200E_206A_206B_202A_200F_200B_206C_202B_202A_202B_206C_200F_206C_202C_202C_200C_206C_206F_200C_200B_202D_200E_202A_202A_206B_206B_200F_202E<string>(201100359), Array.Empty<object>());
|
|
CancelPurchase();
|
|
num2 = 1518393880;
|
|
break;
|
|
case 4:
|
|
return true;
|
|
case 11:
|
|
ptr = InventoryManager.Instance();
|
|
num2 = ((ptr == null) ? 1518393878 : 1518393886);
|
|
break;
|
|
case 10:
|
|
{
|
|
IPluginLog pluginLog = _pluginLog;
|
|
DefaultInterpolatedStringHandler defaultInterpolatedStringHandler = new DefaultInterpolatedStringHandler(65, 1);
|
|
defaultInterpolatedStringHandler.AppendLiteral(global::_003CModule_003E._200E_206F_206C_206C_200E_202A_206D_206B_200B_202D_202B_200F_200F_206B_206C_206F_202D_206F_206A_202D_206A_200B_200B_202B_202D_202C_200F_200D_202E_200E_200D_202A_202B_206F_202E_200E_200B_206B_200E_202E_202E<string>(-504508394));
|
|
defaultInterpolatedStringHandler.AppendFormatted(3000);
|
|
defaultInterpolatedStringHandler.AppendLiteral(global::_003CModule_003E._202E_202C_206D_206B_202B_202D_206D_202E_206F_202E_202A_206A_206A_202B_206A_202D_202C_206C_206B_202C_206E_202B_200E_206E_206A_206C_200D_200D_200F_200B_202C_200B_200E_206F_202C_200F_202D_202A_206E_202B_202E<string>(222200661));
|
|
_200E_202D_200D_200E_202A_200F_202D_206A_206A_200E_202B_206F_202C_200F_206F_206D_200C_202D_200B_206F_206E_200F_200C_206B_200D_206C_206B_200F_200F_206C_200C_202B_206D_200F_202A_202D_200D_206C_202E_206C_202E(pluginLog, defaultInterpolatedStringHandler.ToStringAndClear(), Array.Empty<object>());
|
|
CancelPurchase();
|
|
num2 = 1518393884;
|
|
break;
|
|
}
|
|
case 5:
|
|
num2 = ((num < 3000) ? 1518393880 : 1518393887);
|
|
break;
|
|
case 9:
|
|
num2 = ((num < 3000) ? 1518393884 : 1518393877);
|
|
break;
|
|
case 1:
|
|
num2 = ((ptr->GetInventoryItemCount(_pendingPurchase.ItemId, isHq: false, checkEquipped: true, checkArmory: true, 0) <= _itemCountBeforePurchase) ? 1518393878 : 1518393875);
|
|
break;
|
|
case 6:
|
|
{
|
|
IPluginLog pluginLog2 = _pluginLog;
|
|
DefaultInterpolatedStringHandler defaultInterpolatedStringHandler2 = new DefaultInterpolatedStringHandler(48, 2);
|
|
defaultInterpolatedStringHandler2.AppendLiteral(global::_003CModule_003E._206A_202C_200C_206F_202A_200C_200F_206F_202B_202B_200D_206F_206D_200E_206A_206B_202A_200F_200B_206C_202B_202A_202B_206C_200F_206C_202C_202C_200C_206C_206F_200C_200B_202D_200E_202A_202A_206B_206B_200F_202E<string>(2052935036));
|
|
defaultInterpolatedStringHandler2.AppendFormatted(num8);
|
|
defaultInterpolatedStringHandler2.AppendLiteral(global::_003CModule_003E._206A_202C_200C_206F_202A_200C_200F_206F_202B_202B_200D_206F_206D_200E_206A_206B_202A_200F_200B_206C_202B_202A_202B_206C_200F_206C_202C_202C_200C_206C_206F_200C_200B_202D_200E_202A_202A_206B_206B_200F_202E<string>(-1145280286));
|
|
defaultInterpolatedStringHandler2.AppendFormatted(_pendingPurchase.DesiredQuantity);
|
|
defaultInterpolatedStringHandler2.AppendLiteral(global::_003CModule_003E._200E_206F_206C_206C_200E_202A_206D_206B_200B_202D_202B_200F_200F_206B_206C_206F_202D_206F_206A_202D_206A_200B_200B_202B_202D_202C_200F_200D_202E_200E_200D_202A_202B_206F_202E_200E_200B_206B_200E_202E_202E<string>(-413392469));
|
|
_202B_202B_202A_206C_206D_206F_200F_202B_202B_200B_200D_200B_200F_202A_202D_200B_202C_202C_200D_202D_202D_206F_200B_206D_202C_200D_202B_206E_202D_202C_202C_202A_200F_200C_200B_206C_200E_202E_202A_206A_202E(pluginLog2, defaultInterpolatedStringHandler2.ToStringAndClear(), Array.Empty<object>());
|
|
_navigationStep = 2;
|
|
_lastActionMs = _202E_202B_202B_206F_200E_200E_202E_206D_200E_206F_200F_206E_200B_206D_206A_206E_206D_202B_200C_200F_206C_202C_202E_202D_206A_200E_202A_200C_200C_202D_202C_202A_206E_206B_200D_206B_202E_206D_202E_202E();
|
|
_awaitingAddonReady = true;
|
|
return false;
|
|
}
|
|
case 12:
|
|
num8 = ptr->GetInventoryItemCount(_pendingPurchase.ItemId, isHq: false, checkEquipped: true, checkArmory: true, 0) - _pendingPurchase.InitialCount;
|
|
num2 = ((num8 < _pendingPurchase.DesiredQuantity) ? 1518393881 : 1518393879);
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
|
|
private void ResetPurchaseState()
|
|
{
|
|
_pendingPurchase = null;
|
|
IsAwaitingConfirmation = false;
|
|
_yesNoArmed = false;
|
|
_awaitingAddonReady = false;
|
|
_navigationStep = 0;
|
|
_itemCountBeforePurchase = -1;
|
|
}
|
|
|
|
private unsafe void FirePurchaseCallback(AtkUnitBase* addon, GrandCompanyItem item, int quantity)
|
|
{
|
|
AtkValue* ptr = stackalloc AtkValue[9];
|
|
ptr->Type = FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.Int;
|
|
ptr->Int = 0;
|
|
ptr[1].Type = FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.Int;
|
|
ptr[1].Int = item.Index;
|
|
ptr[2].Type = FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.Int;
|
|
ptr[2].Int = quantity;
|
|
ptr[3].Type = FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.Int;
|
|
ptr[3].Int = 0;
|
|
ptr[4].Type = FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.Int;
|
|
ptr[4].Int = 0;
|
|
ptr[5].Type = FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.Int;
|
|
ptr[5].Int = 0;
|
|
ptr[6].Type = FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.UInt;
|
|
ptr[6].UInt = item.ItemId;
|
|
ptr[7].Type = FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.UInt;
|
|
ptr[7].UInt = item.IconId;
|
|
ptr[8].Type = FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.UInt;
|
|
ptr[8].UInt = item.SealCost;
|
|
addon->FireCallback(9u, ptr);
|
|
}
|
|
|
|
private unsafe static int GetAtkValueInt(AtkUnitBase* addon, int index)
|
|
{
|
|
int num = ((addon == null) ? (-57715483) : (-57715477));
|
|
int result = default(int);
|
|
AtkValue atkValue = default(AtkValue);
|
|
while (true)
|
|
{
|
|
int num2 = num;
|
|
int num3 = -57715475;
|
|
int num4 = num2;
|
|
switch ((num4 | num3) - (num4 & num3))
|
|
{
|
|
default:
|
|
continue;
|
|
case 7:
|
|
num = ((index < addon->AtkValuesCount) ? (-57715474) : (-57715483));
|
|
continue;
|
|
case 6:
|
|
num = ((addon->AtkValues == null) ? (-57715483) : (-57715476));
|
|
continue;
|
|
case 10:
|
|
result = ((atkValue.Byte != 0) ? 1 : 0);
|
|
num = -57715480;
|
|
continue;
|
|
case 2:
|
|
goto IL_00c7;
|
|
case 3:
|
|
atkValue = addon->AtkValues[index];
|
|
switch (atkValue.Type)
|
|
{
|
|
case FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.Bool:
|
|
break;
|
|
case FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.Int64:
|
|
goto IL_00c7;
|
|
default:
|
|
goto IL_0109;
|
|
case FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.UInt:
|
|
goto IL_0140;
|
|
case FFXIVClientStructs.FFXIV.Component.GUI.AtkValueType.Int:
|
|
goto end_IL_0033;
|
|
}
|
|
goto case 10;
|
|
case 5:
|
|
return result;
|
|
case 8:
|
|
return -1;
|
|
case 1:
|
|
num = ((index < 0) ? (-57715483) : (-57715478));
|
|
continue;
|
|
case 0:
|
|
num = -57715477;
|
|
continue;
|
|
case 11:
|
|
goto IL_0140;
|
|
case 4:
|
|
num = -57715473;
|
|
continue;
|
|
case 9:
|
|
break;
|
|
IL_0140:
|
|
result = (int)atkValue.UInt;
|
|
num = -57715480;
|
|
continue;
|
|
IL_0109:
|
|
num = -57715479;
|
|
continue;
|
|
IL_00c7:
|
|
result = -1;
|
|
num = -57715480;
|
|
continue;
|
|
end_IL_0033:
|
|
break;
|
|
}
|
|
result = atkValue.Int;
|
|
num = -57715480;
|
|
}
|
|
}
|
|
|
|
[MethodImpl(MethodImplOptions.NoInlining)]
|
|
public void Dispose()
|
|
{
|
|
_206D_206E_206A_202D_202B_206F_202D_206F_206F_200E_202A_206E_200C_202D_202D_200F_200E_202D_202E_202E_206A_202C_200F_202A_202E_200B_206F_202E_206E_206A_206A_206A_202D_206C_200E_200D_206F_206E_202C_206D_202E(_addonLifecycle, AddonEvent.PostSetup, global::_003CModule_003E._200E_206F_206C_206C_200E_202A_206D_206B_200B_202D_202B_200F_200F_206B_206C_206F_202D_206F_206A_202D_206A_200B_200B_202B_202D_202C_200F_200D_202E_200E_200D_202A_202B_206F_202E_200E_200B_206B_200E_202E_202E<string>(-238810398), (IAddonLifecycle.AddonEventDelegate)OnShopPostSetup);
|
|
_206D_206E_206A_202D_202B_206F_202D_206F_206F_200E_202A_206E_200C_202D_202D_200F_200E_202D_202E_202E_206A_202C_200F_202A_202E_200B_206F_202E_206E_206A_206A_206A_202D_206C_200E_200D_206F_206E_202C_206D_202E(_addonLifecycle, AddonEvent.PreFinalize, global::_003CModule_003E._206A_206D_202C_206E_206D_206E_202A_200F_200D_206A_200F_206C_202C_202D_206D_206A_200D_200F_206A_206C_202C_206D_206E_200F_200F_200C_206B_200B_206B_206E_202B_206B_200E_200E_200B_206F_200F_202E_200C_200C_202E<string>(1178205757), (IAddonLifecycle.AddonEventDelegate)OnShopPreFinalize);
|
|
_206D_206E_206A_202D_202B_206F_202D_206F_206F_200E_202A_206E_200C_202D_202D_200F_200E_202D_202E_202E_206A_202C_200F_202A_202E_200B_206F_202E_206E_206A_206A_206A_202D_206C_200E_200D_206F_206E_202C_206D_202E(_addonLifecycle, AddonEvent.PostSetup, global::_003CModule_003E._206A_202C_200C_206F_202A_200C_200F_206F_202B_202B_200D_206F_206D_200E_206A_206B_202A_200F_200B_206C_202B_202A_202B_206C_200F_206C_202C_202C_200C_206C_206F_200C_200B_202D_200E_202A_202A_206B_206B_200F_202E<string>(423301839), (IAddonLifecycle.AddonEventDelegate)OnSelectYesNoPostSetup);
|
|
_206D_206E_206A_202D_202B_206F_202D_206F_206F_200E_202A_206E_200C_202D_202D_200F_200E_202D_202E_202E_206A_202C_200F_202A_202E_200B_206F_202E_206E_206A_206A_206A_202D_206C_200E_200D_206F_206E_202C_206D_202E(_addonLifecycle, AddonEvent.PostUpdate, global::_003CModule_003E._206A_202C_200C_206F_202A_200C_200F_206F_202B_202B_200D_206F_206D_200E_206A_206B_202A_200F_200B_206C_202B_202A_202B_206C_200F_206C_202C_202C_200C_206C_206F_200C_200B_202D_200E_202A_202A_206B_206B_200F_202E<string>(423301839), (IAddonLifecycle.AddonEventDelegate)OnSelectYesNoPostUpdate);
|
|
}
|
|
|
|
void IDisposable.Dispose()
|
|
{
|
|
//ILSpy generated this explicit interface implementation from .override directive in Dispose
|
|
this.Dispose();
|
|
}
|
|
|
|
static void _206D_202D_200F_202D_200D_206A_200F_206C_202D_202C_200F_200D_206D_206E_206B_200D_202A_200D_206E_206A_206C_200D_206F_200F_206D_200C_200D_200F_206E_200F_206A_200C_206B_206B_202B_202E_206D_200B_200B_206A_202E(object P_0, string P_1)
|
|
{
|
|
ArgumentNullException.ThrowIfNull(P_0, P_1);
|
|
}
|
|
|
|
static void _202A_206B_206F_206E_202E_206A_202B_202C_200E_202A_200C_200C_200B_200E_206B_202E_202E_202C_200B_202D_206F_206A_206C_206F_200B_206A_206A_202B_206F_206B_200B_206A_200C_206B_202E_206E_200F_202E_200E_200D_202E(IAddonLifecycle P_0, AddonEvent P_1, string P_2, IAddonLifecycle.AddonEventDelegate P_3)
|
|
{
|
|
P_0.RegisterListener(P_1, P_2, P_3);
|
|
}
|
|
|
|
static Delegate _202E_202C_206F_200C_202C_206D_202A_206E_206B_200B_200F_202B_200F_206C_200F_200F_202E_200C_200E_206D_206B_202B_206A_202A_202D_202A_200D_200E_206F_206C_200D_202C_200C_206D_200B_206E_206C_206E_202E_206B_202E(Delegate P_0, Delegate P_1)
|
|
{
|
|
return Delegate.Combine(P_0, P_1);
|
|
}
|
|
|
|
static Delegate _200B_200F_200D_200E_200E_206D_200C_206C_206F_200B_202C_202C_206F_202C_202B_206D_206A_202B_206C_202C_206E_200C_200D_202E_200D_202A_202A_200B_202C_202B_206B_200F_206B_200E_206A_206C_200F_200D_200F_206D_202E(Delegate P_0, Delegate P_1)
|
|
{
|
|
return Delegate.Remove(P_0, P_1);
|
|
}
|
|
|
|
static void _200D_206E_200E_202C_202B_202B_206B_206D_206F_202E_200E_206D_202C_206C_200D_200C_206F_206C_206F_202C_206C_200E_202D_202D_202A_200B_202E_206C_206D_200F_206A_200C_202A_202D_202A_206B_200B_200E_200C_202C_202E(IPluginLog P_0, string P_1, object[] P_2)
|
|
{
|
|
P_0.Debug(P_1, P_2);
|
|
}
|
|
|
|
static AtkUnitBasePtr _206F_202E_200B_202E_206B_206B_206B_202A_200C_206C_202D_200C_202E_200C_202D_202E_202E_206B_206B_206D_206E_202D_206F_206B_200D_200C_206F_202D_206B_202E_206E_202E_202C_200F_202E_206A_202A_202A_200F_206D_202E(AddonArgs P_0)
|
|
{
|
|
return P_0.Addon;
|
|
}
|
|
|
|
static void _202B_202B_202A_206C_206D_206F_200F_202B_202B_200B_200D_200B_200F_202A_202D_200B_202C_202C_200D_202D_202D_206F_200B_206D_202C_200D_202B_206E_202D_202C_202C_202A_200F_200C_200B_206C_200E_202E_202A_206A_202E(IPluginLog P_0, string P_1, object[] P_2)
|
|
{
|
|
P_0.Information(P_1, P_2);
|
|
}
|
|
|
|
static long _202E_202B_202B_206F_200E_200E_202E_206D_200E_206F_200F_206E_200B_206D_206A_206E_206D_202B_200C_200F_206C_202C_202E_202D_206A_200E_202A_200C_200C_202D_202C_202A_206E_206B_200D_206B_202E_206D_202E_202E()
|
|
{
|
|
return Environment.TickCount64;
|
|
}
|
|
|
|
static void _200E_202D_200D_200E_202A_200F_202D_206A_206A_200E_202B_206F_202C_200F_206F_206D_200C_202D_200B_206F_206E_200F_200C_206B_200D_206C_206B_200F_200F_206C_200C_202B_206D_200F_202A_202D_200D_206C_202E_206C_202E(IPluginLog P_0, string P_1, object[] P_2)
|
|
{
|
|
P_0.Warning(P_1, P_2);
|
|
}
|
|
|
|
static int _200D_206A_206D_200D_206A_200C_206A_200C_206A_200B_206B_206C_200B_206D_202C_206F_206D_202A_206A_202A_206C_200B_200C_206A_202E_200B_206A_200E_200C_206B_206B_206E_200D_200D_202E_206A_200F_202B_200E_202A_202E(int P_0, int P_1)
|
|
{
|
|
return Math.Min(P_0, P_1);
|
|
}
|
|
|
|
static void _206D_206E_206A_202D_202B_206F_202D_206F_206F_200E_202A_206E_200C_202D_202D_200F_200E_202D_202E_202E_206A_202C_200F_202A_202E_200B_206F_202E_206E_206A_206A_206A_202D_206C_200E_200D_206F_206E_202C_206D_202E(IAddonLifecycle P_0, AddonEvent P_1, string P_2, IAddonLifecycle.AddonEventDelegate P_3)
|
|
{
|
|
P_0.UnregisterListener(P_1, P_2, P_3);
|
|
}
|
|
}
|