muffin v7.5.11
This commit is contained in:
parent
addf2d530f
commit
3102923ce2
522 changed files with 41082 additions and 211592 deletions
|
|
@ -1,7 +1,5 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Numerics;
|
||||
using System.Runtime.CompilerServices;
|
||||
using Dalamud.Plugin.Services;
|
||||
using LLib.Shop.Model;
|
||||
using Lumina.Excel;
|
||||
|
|
@ -11,9 +9,9 @@ namespace LLib.Shop.Searchers;
|
|||
|
||||
internal sealed class GCShopSearcher
|
||||
{
|
||||
private static readonly uint[] SealItemIds;
|
||||
private static readonly uint[] SealItemIds = new uint[4] { 0u, 20u, 21u, 22u };
|
||||
|
||||
private static readonly uint[] QuartermasterNpcIds;
|
||||
private static readonly uint[] QuartermasterNpcIds = new uint[4] { 0u, 1003251u, 1000394u, 1004416u };
|
||||
|
||||
private readonly IDataManager _dataManager;
|
||||
|
||||
|
|
@ -32,243 +30,71 @@ internal sealed class GCShopSearcher
|
|||
ExcelSheet<GCScripShopCategory> excelSheet = _dataManager.GetExcelSheet<GCScripShopCategory>();
|
||||
ExcelSheet<GCShop> excelSheet2 = _dataManager.GetExcelSheet<GCShop>();
|
||||
Dictionary<uint, uint> dictionary = new Dictionary<uint, uint>();
|
||||
int num;
|
||||
using (ExcelSheet<GCShop>.Enumerator enumerator = excelSheet2.GetEnumerator())
|
||||
foreach (GCShop item in excelSheet2)
|
||||
{
|
||||
num = 1051383977;
|
||||
uint rowId = default(uint);
|
||||
GCShop current = default(GCShop);
|
||||
while (true)
|
||||
uint rowId = item.GrandCompany.RowId;
|
||||
if (rowId != 0)
|
||||
{
|
||||
int num2 = num;
|
||||
int num3 = 1051383979;
|
||||
int num4 = num2;
|
||||
switch ((num4 | num3) - (num4 & num3))
|
||||
{
|
||||
case 0:
|
||||
num = 1051383977;
|
||||
break;
|
||||
case 2:
|
||||
num = (enumerator.MoveNext() ? 1051383983 : 1051383976);
|
||||
break;
|
||||
case 1:
|
||||
dictionary.TryAdd(rowId, current.RowId);
|
||||
num = 1051383977;
|
||||
break;
|
||||
case 4:
|
||||
current = enumerator.Current;
|
||||
rowId = current.GrandCompany.RowId;
|
||||
num = ((rowId == 0) ? 1051383977 : 1051383978);
|
||||
break;
|
||||
case 3:
|
||||
goto end_IL_0063;
|
||||
}
|
||||
continue;
|
||||
end_IL_0063:
|
||||
break;
|
||||
dictionary.TryAdd(rowId, item.RowId);
|
||||
}
|
||||
}
|
||||
Dictionary<uint, uint> dictionary2 = new Dictionary<uint, uint>();
|
||||
using (SubrowExcelSheet<GCScripShopItem>.Enumerator enumerator2 = subrowExcelSheet.GetEnumerator())
|
||||
foreach (SubrowCollection<GCScripShopItem> item2 in subrowExcelSheet)
|
||||
{
|
||||
num = 754964801;
|
||||
uint num8 = default(uint);
|
||||
uint value2 = default(uint);
|
||||
uint rowId3 = default(uint);
|
||||
uint value = default(uint);
|
||||
SubrowCollection<GCScripShopItem> current2 = default(SubrowCollection<GCScripShopItem>);
|
||||
uint rowId2 = default(uint);
|
||||
int num7 = default(int);
|
||||
GCScripShopCategory row = default(GCScripShopCategory);
|
||||
uint costGCSeals = default(uint);
|
||||
GCScripShopItem gCScripShopItem = default(GCScripShopItem);
|
||||
while (true)
|
||||
uint rowId2 = item2.RowId;
|
||||
for (int i = 0; i < item2.Count; i++)
|
||||
{
|
||||
int num5 = num;
|
||||
int num3 = 754964806;
|
||||
int num4 = num5;
|
||||
switch ((num4 | num3) - (num4 & num3))
|
||||
GCScripShopItem gCScripShopItem = item2[i];
|
||||
if (gCScripShopItem.Item.RowId != itemId)
|
||||
{
|
||||
case 17:
|
||||
num8 = 1u;
|
||||
num = 754964805;
|
||||
break;
|
||||
case 2:
|
||||
num = ((!dictionary2.TryGetValue(num8, out value2)) ? 754964815 : 754964813);
|
||||
break;
|
||||
case 6:
|
||||
num = ((!dictionary2.TryGetValue(rowId3, out value)) ? 754964803 : 754964822);
|
||||
break;
|
||||
case 13:
|
||||
current2 = enumerator2.Current;
|
||||
rowId2 = current2.RowId;
|
||||
num7 = 0;
|
||||
num = 754964808;
|
||||
break;
|
||||
case 10:
|
||||
{
|
||||
uint num9 = num8;
|
||||
num3 = 1;
|
||||
num4 = (int)num9;
|
||||
int num10 = num4 ^ num3;
|
||||
int num11 = num4 & num3;
|
||||
num8 = (uint)(num10 + (num11 + num11));
|
||||
num = 754964805;
|
||||
break;
|
||||
continue;
|
||||
}
|
||||
case 0:
|
||||
rowId3 = row.GrandCompany.RowId;
|
||||
num = ((rowId3 != 0) ? 754964800 : 754964823);
|
||||
break;
|
||||
case 14:
|
||||
num = ((num7 < current2.Count) ? 754964809 : 754964801);
|
||||
break;
|
||||
case 1:
|
||||
costGCSeals = gCScripShopItem.CostGCSeals;
|
||||
num = ((!excelSheet.TryGetRow(rowId2, out row)) ? 754964810 : 754964806);
|
||||
break;
|
||||
case 8:
|
||||
num = 754964810;
|
||||
break;
|
||||
case 9:
|
||||
dictionary2[num8] = costGCSeals;
|
||||
num = 754964812;
|
||||
break;
|
||||
case 7:
|
||||
num = (enumerator2.MoveNext() ? 754964811 : 754964820);
|
||||
break;
|
||||
case 4:
|
||||
num = 754964801;
|
||||
break;
|
||||
case 11:
|
||||
num = ((costGCSeals >= value2) ? 754964812 : 754964815);
|
||||
break;
|
||||
case 5:
|
||||
dictionary2[rowId3] = costGCSeals;
|
||||
num = 754964810;
|
||||
break;
|
||||
case 3:
|
||||
num = ((num8 < (uint)QuartermasterNpcIds.Length) ? 754964804 : 754964814);
|
||||
break;
|
||||
case 16:
|
||||
num = ((costGCSeals >= value) ? 754964810 : 754964803);
|
||||
break;
|
||||
case 15:
|
||||
gCScripShopItem = current2[num7];
|
||||
num = ((gCScripShopItem.Item.RowId != itemId) ? 754964810 : 754964807);
|
||||
break;
|
||||
case 12:
|
||||
uint costGCSeals = gCScripShopItem.CostGCSeals;
|
||||
if (!excelSheet.TryGetRow(rowId2, out var row))
|
||||
{
|
||||
int num6 = num7;
|
||||
num3 = 1;
|
||||
num4 = num6;
|
||||
num7 = (num4 | num3) + (num4 & num3);
|
||||
num = 754964808;
|
||||
break;
|
||||
continue;
|
||||
}
|
||||
case 18:
|
||||
goto end_IL_014c;
|
||||
}
|
||||
continue;
|
||||
end_IL_014c:
|
||||
break;
|
||||
}
|
||||
}
|
||||
num = ((dictionary2.Count != 0) ? (-231383589) : (-231383590));
|
||||
(ushort, Vector3)? position = default((ushort, Vector3)?);
|
||||
uint num14 = default(uint);
|
||||
uint num16 = default(uint);
|
||||
uint price = default(uint);
|
||||
uint currencyItemId = default(uint);
|
||||
while (true)
|
||||
{
|
||||
int num12 = num;
|
||||
int num3 = -231383589;
|
||||
int num4 = num12;
|
||||
switch ((num4 | num3) - (num4 & num3))
|
||||
{
|
||||
case 2:
|
||||
goto IL_046f;
|
||||
case 1:
|
||||
return list;
|
||||
case 0:
|
||||
{
|
||||
using Dictionary<uint, uint>.Enumerator enumerator3 = dictionary2.GetEnumerator();
|
||||
num = 1589717565;
|
||||
while (true)
|
||||
uint rowId3 = row.GrandCompany.RowId;
|
||||
uint value2;
|
||||
if (rowId3 == 0)
|
||||
{
|
||||
int num13 = num;
|
||||
num3 = 1589717566;
|
||||
num4 = num13;
|
||||
int num15;
|
||||
switch ((num4 | num3) - (num4 & num3))
|
||||
for (uint num = 1u; num < (uint)QuartermasterNpcIds.Length; num++)
|
||||
{
|
||||
case 6:
|
||||
{
|
||||
(ushort, Vector3) valueOrDefault = position.GetValueOrDefault();
|
||||
dictionary.TryGetValue(num14, out var value3);
|
||||
list.Add(new ShopSearchResult(value3, num16, valueOrDefault.Item1, valueOrDefault.Item2, EShopType.GCShop, price, currencyItemId));
|
||||
num = 1589717565;
|
||||
break;
|
||||
}
|
||||
case 1:
|
||||
num15 = 0;
|
||||
goto IL_0563;
|
||||
case 7:
|
||||
num = 1589717565;
|
||||
break;
|
||||
case 3:
|
||||
num = (enumerator3.MoveNext() ? 1589717564 : 1589717563);
|
||||
break;
|
||||
case 0:
|
||||
num15 = (int)SealItemIds[num14];
|
||||
goto IL_0563;
|
||||
case 2:
|
||||
{
|
||||
enumerator3.Current.Deconstruct(out var key, out var value4);
|
||||
num14 = key;
|
||||
price = value4;
|
||||
num = ((num14 >= (uint)QuartermasterNpcIds.Length) ? 1589717565 : 1589717562);
|
||||
break;
|
||||
}
|
||||
case 4:
|
||||
num16 = QuartermasterNpcIds[num14];
|
||||
num = ((num16 == 0) ? 1589717565 : 1589717558);
|
||||
break;
|
||||
case 8:
|
||||
num = ((num14 < (uint)SealItemIds.Length) ? 1589717566 : 1589717567);
|
||||
break;
|
||||
case 5:
|
||||
if (!dictionary2.TryGetValue(num, out var value) || costGCSeals < value)
|
||||
{
|
||||
return list;
|
||||
dictionary2[num] = costGCSeals;
|
||||
}
|
||||
IL_0563:
|
||||
currencyItemId = (uint)num15;
|
||||
position = _positionCache.GetPosition(num16);
|
||||
num = ((!position.HasValue) ? 1589717565 : 1589717560);
|
||||
break;
|
||||
}
|
||||
}
|
||||
else if (!dictionary2.TryGetValue(rowId3, out value2) || costGCSeals < value2)
|
||||
{
|
||||
dictionary2[rowId3] = costGCSeals;
|
||||
}
|
||||
}
|
||||
}
|
||||
continue;
|
||||
IL_046f:
|
||||
num = -231383590;
|
||||
}
|
||||
}
|
||||
|
||||
static GCShopSearcher()
|
||||
{
|
||||
uint[] array = new uint[4];
|
||||
_200F_206D_202A_206E_202D_200C_206D_200D_200B_202E_202B_206B_206B_206E_202B_206A_202B_206D_202C_200E_206F_200C_200B_202B_200C_202B_206C_202C_202E_200F_206D_200B_202B_202B_206E_206B_206A_200D_206A_200F_202E((Array)array, (RuntimeFieldHandle)/*OpCode not supported: LdMemberToken*/);
|
||||
SealItemIds = array;
|
||||
uint[] array2 = new uint[4];
|
||||
_200F_206D_202A_206E_202D_200C_206D_200D_200B_202E_202B_206B_206B_206E_202B_206A_202B_206D_202C_200E_206F_200C_200B_202B_200C_202B_206C_202C_202E_200F_206D_200B_202B_202B_206E_206B_206A_200D_206A_200F_202E((Array)array2, (RuntimeFieldHandle)/*OpCode not supported: LdMemberToken*/);
|
||||
QuartermasterNpcIds = array2;
|
||||
}
|
||||
|
||||
static void _200F_206D_202A_206E_202D_200C_206D_200D_200B_202E_202B_206B_206B_206E_202B_206A_202B_206D_202C_200E_206F_200C_200B_202B_200C_202B_206C_202C_202E_200F_206D_200B_202B_202B_206E_206B_206A_200D_206A_200F_202E(Array P_0, RuntimeFieldHandle P_1)
|
||||
{
|
||||
RuntimeHelpers.InitializeArray(P_0, P_1);
|
||||
if (dictionary2.Count == 0)
|
||||
{
|
||||
return list;
|
||||
}
|
||||
foreach (var (num4, price) in dictionary2)
|
||||
{
|
||||
if (num4 >= (uint)QuartermasterNpcIds.Length)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
uint num5 = QuartermasterNpcIds[num4];
|
||||
if (num5 != 0)
|
||||
{
|
||||
uint currencyItemId = ((num4 < (uint)SealItemIds.Length) ? SealItemIds[num4] : 0u);
|
||||
(ushort, Vector3)? position = _positionCache.GetPosition(num5);
|
||||
if (position.HasValue)
|
||||
{
|
||||
(ushort, Vector3) valueOrDefault = position.GetValueOrDefault();
|
||||
dictionary.TryGetValue(num4, out var value3);
|
||||
list.Add(new ShopSearchResult(value3, num5, valueOrDefault.Item1, valueOrDefault.Item2, EShopType.GCShop, price, currencyItemId));
|
||||
}
|
||||
}
|
||||
}
|
||||
return list;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue