using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using BepInEx;
using BepInEx.Logging;
using DiskCardGame;
using HarmonyLib;
using UnityEngine;
[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: TargetFramework(".NETStandard,Version=v2.0", FrameworkDisplayName = ".NET Standard 2.0")]
[assembly: AssemblyCompany("MoreCabinNodes")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyDescription("A StarCraft inspired mod that brings StarCraftCore into the world of Inscryption")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0")]
[assembly: AssemblyProduct("MoreCabinNodes")]
[assembly: AssemblyTitle("MoreCabinNodes")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("1.0.0.0")]
[module: UnverifiableCode]
[BepInPlugin("jamesgames.inscryption.morecabinnodes", "More Cabin Nodes", "1.0.0.0")]
[BepInDependency(/*Could not decode attribute arguments.*/)]
public class Plugin : BaseUnityPlugin
{
public const string PluginGuid = "jamesgames.inscryption.morecabinnodes";
public const string PluginName = "More Cabin Nodes";
public const string PluginVersion = "1.0.0.0";
public static Plugin Instance;
public static ManualLogSource Log;
private void Awake()
{
//IL_0028: Unknown result type (might be due to invalid IL or missing references)
((BaseUnityPlugin)this).Logger.LogInfo((object)"Loading More Cabin Nodes...");
Instance = this;
Log = ((BaseUnityPlugin)this).Logger;
new Harmony("jamesgames.inscryption.morecabinnodes").PatchAll();
}
private void Start()
{
//IL_006c: Unknown result type (might be due to invalid IL or missing references)
//IL_0071: Unknown result type (might be due to invalid IL or missing references)
//IL_007c: Unknown result type (might be due to invalid IL or missing references)
//IL_0083: Unknown result type (might be due to invalid IL or missing references)
//IL_008a: Unknown result type (might be due to invalid IL or missing references)
//IL_0092: Unknown result type (might be due to invalid IL or missing references)
//IL_0097: Unknown result type (might be due to invalid IL or missing references)
//IL_00a1: Expected O, but got Unknown
//IL_00a3: Unknown result type (might be due to invalid IL or missing references)
//IL_00a8: Unknown result type (might be due to invalid IL or missing references)
//IL_00b3: Unknown result type (might be due to invalid IL or missing references)
//IL_00ba: Unknown result type (might be due to invalid IL or missing references)
//IL_00c1: Unknown result type (might be due to invalid IL or missing references)
//IL_00c9: Unknown result type (might be due to invalid IL or missing references)
//IL_00ce: Unknown result type (might be due to invalid IL or missing references)
//IL_00d8: Expected O, but got Unknown
PredefinedNodes[] array = (from a in Resources.LoadAll<PredefinedNodes>("data/authoredmapdata")
where a.nodeRows.Count == 3 && ((Object)a).name.ToLower().Contains("final")
select a).ToArray();
PredefinedNodes[] array2 = array;
foreach (PredefinedNodes val in array2)
{
List<NodeData> list = val.nodeRows[1];
float y = ((MapElementData)list[0]).position.y;
List<NodeData> collection = new List<NodeData>
{
(NodeData)new DuplicateMergeNodeData
{
id = 1337,
gridX = 4,
gridY = 1,
position = new Vector2(0f, y)
},
(NodeData)new CardRemoveNodeData
{
id = 1338,
gridX = 5,
gridY = 1,
position = new Vector2(1f, y)
}
};
list.AddRange(collection);
float num = 0.08f;
float x = ((MapElementData)val.nodeRows[0][0]).position.x;
float num2 = x - (float)(list.Count - 1) * num / 2f;
for (int j = 0; j < list.Count; j++)
{
NodeData val2 = list[j];
((MapElementData)val2).position.x = num2 + (float)j * num;
}
foreach (NodeData item in val.nodeRows[0])
{
item.connectedNodes.AddRange(collection);
}
}
}
}
namespace StarCraftCore;
public static class PluginInfo
{
public const string PLUGIN_GUID = "MoreCabinNodes";
public const string PLUGIN_NAME = "MoreCabinNodes";
public const string PLUGIN_VERSION = "1.0.0";
}