diff --git a/Builds/Managed/1.0.0.R2/Assembly-CSharp.dll b/Builds/Managed/1.0.0.R2/Assembly-CSharp.dll
new file mode 100644
index 0000000..6b0c96d
Binary files /dev/null and b/Builds/Managed/1.0.0.R2/Assembly-CSharp.dll differ
diff --git a/Source/Assembly-CSharp.csproj b/Source/Assembly-CSharp.csproj
new file mode 100644
index 0000000..45e9ba1
--- /dev/null
+++ b/Source/Assembly-CSharp.csproj
@@ -0,0 +1,126 @@
+
+
+
+ {9AE3EB35-37E3-4DF8-B859-C0B29D6851C6}
+ Debug
+ AnyCPU
+ Library
+ Assembly-CSharp
+ v2.0
+ 4
+
+
+ AnyCPU
+
+
+ bin\Debug\
+ true
+ full
+ false
+
+
+ bin\Release\
+ true
+ pdbonly
+ true
+
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\UnityEngine.dll
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\UnityEngine.CoreModule.dll
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\UnityEngine.UI.dll
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\UnityEngine.UIModule.dll
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\UnityEngine.AudioModule.dll
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\UnityEngine.Physics2DModule.dll
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\UnityEngine.TextRenderingModule.dll
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\UnityEngine.ParticleSystemModule.dll
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\Sirenix.OdinInspector.Attributes.dll
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\UnityEngine.JSONSerializeModule.dll
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\UnityEngine.ImageConversionModule.dll
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\UnityEngine.ScreenCaptureModule.dll
+
+
+ ..\Spaceflight Simulator Pc v1.2\spaceflight simulator pc 1.2_data\Managed\UnityEngine.GameCenterModule.dll
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Source/Assembly-CSharp.sln b/Source/Assembly-CSharp.sln
new file mode 100644
index 0000000..3450cf2
--- /dev/null
+++ b/Source/Assembly-CSharp.sln
@@ -0,0 +1,25 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio 15
+VisualStudioVersion = 15.0.27004.2005
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Assembly-CSharp", "Assembly-CSharp.csproj", "{9AE3EB35-37E3-4DF8-B859-C0B29D6851C6}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {9AE3EB35-37E3-4DF8-B859-C0B29D6851C6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {9AE3EB35-37E3-4DF8-B859-C0B29D6851C6}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {9AE3EB35-37E3-4DF8-B859-C0B29D6851C6}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {9AE3EB35-37E3-4DF8-B859-C0B29D6851C6}.Release|Any CPU.Build.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {3A3D0368-D060-40E0-81F0-36EC8D1C5B60}
+ EndGlobalSection
+EndGlobal
diff --git a/Source/Blur.cs b/Source/Blur.cs
index fda5220..d332bbf 100644
--- a/Source/Blur.cs
+++ b/Source/Blur.cs
@@ -5,40 +5,40 @@
public class Blur : MonoBehaviour
{
- public Texture2D shade;
+ public Texture2D shade;
- public Texture2D blur;
+ public Texture2D blur;
- public float blurStreght;
+ public float blurStreght;
- [Button("Generate Shade Texture", ButtonSizes.Small)]
- public void Generate()
- {
- Texture2D texture2D = new Texture2D(this.shade.width, this.shade.height, TextureFormat.Alpha8, false);
- MonoBehaviour.print(texture2D.width + " " + texture2D.height);
- texture2D.filterMode = FilterMode.Point;
- for (int i = 0; i < this.shade.width; i++)
- {
- for (int j = 0; j < this.shade.height; j++)
- {
- if (this.blur.GetPixel(i, j).a > 0f)
- {
- int num = (int)(this.blur.GetPixel(i, j).a * 12f);
- float num2 = 0f;
- for (int k = 0; k < num * 2 + 1; k++)
- {
- num2 += this.shade.GetPixel(Mathf.Clamp(i - num + k, 0, this.shade.width), j).a;
- }
- num2 = Mathf.Lerp(this.shade.GetPixel(i, j).a, num2 / (float)(num * 2 + 1), this.blurStreght);
- texture2D.SetPixel(i, j, new Color(1f, 1f, 1f, num2));
- }
- else
- {
- texture2D.SetPixel(i, j, this.shade.GetPixel(i, j));
- }
- }
- }
- texture2D.Apply();
- File.WriteAllBytes(Application.dataPath + "/Textures/Combined.png", texture2D.EncodeToPNG());
- }
-}
+ [Button("Generate Shade Texture", ButtonSizes.Small)]
+ public void Generate()
+ {
+ Texture2D texture2D = new Texture2D(this.shade.width, this.shade.height, TextureFormat.Alpha8, false);
+ MonoBehaviour.print(texture2D.width + " " + texture2D.height);
+ texture2D.filterMode = FilterMode.Point;
+ for (int i = 0; i < this.shade.width; i++)
+ {
+ for (int j = 0; j < this.shade.height; j++)
+ {
+ if (this.blur.GetPixel(i, j).a > 0f)
+ {
+ int num = (int)(this.blur.GetPixel(i, j).a * 12f);
+ float num2 = 0f;
+ for (int k = 0; k < num * 2 + 1; k++)
+ {
+ num2 += this.shade.GetPixel(Mathf.Clamp(i - num + k, 0, this.shade.width), j).a;
+ }
+ num2 = Mathf.Lerp(this.shade.GetPixel(i, j).a, num2 / (float)(num * 2 + 1), this.blurStreght);
+ texture2D.SetPixel(i, j, new Color(1f, 1f, 1f, num2));
+ }
+ else
+ {
+ texture2D.SetPixel(i, j, this.shade.GetPixel(i, j));
+ }
+ }
+ }
+ texture2D.Apply();
+ File.WriteAllBytes(Application.dataPath + "/Textures/Combined.png", texture2D.EncodeToPNG());
+ }
+}
\ No newline at end of file
diff --git a/Source/NewBuildSystem/Build.cs b/Source/NewBuildSystem/Build.cs
index 6ed438b..b318d5b 100644
--- a/Source/NewBuildSystem/Build.cs
+++ b/Source/NewBuildSystem/Build.cs
@@ -1,7 +1,7 @@
using SFSML;
-using SFSML.GameManager.Hooks.BuildRelated;
-using SFSML.GameManager.Hooks.FrameRelated;
-using SFSML.GameManager.Hooks.UnityRelated;
+using SFSML.HookSystem.ReWork;
+using SFSML.HookSystem.ReWork.BaseHooks;
+using SFSML.HookSystem.ReWork.BaseHooks.BuildHooks;
using Sirenix.OdinInspector;
using System;
using System.Collections.Generic;
@@ -238,7 +238,6 @@ private void Start()
this.dragAndDropInstruction.gameObject.SetActive(true);
Saving.SaveSetting(Saving.SettingKey.seenBuildInstructions, true);
}
- ModLoader.manager.castHook(new MyBuildMenuStartedHook());
}
public void MoveCamera(Vector3 delta)
@@ -288,7 +287,11 @@ public void OnTouchStay(int fingerId, Vector2 touchPosWorld, Vector2 deltaPixel)
Vector2 autoCorrect = this.GetAutoCorrect(vector, fingerId);
if (this.holdingParts[fingerId].part.partIcon != null)
{
- this.holdingParts[fingerId].part.partIcon.position = Vector3.Lerp(vector, autoCorrect, 1f - this.roundStrength);
+ PlacedPart tgtPart = this.holdingParts[fingerId].part;
+ Vector3 tgtPos = Vector3.Lerp(vector, autoCorrect, 1f - this.roundStrength);
+ MyPartStartDragHook hook = new MyPartStartDragHook(tgtPart, tgtPos);
+ if (hook.isCanceled()) { return; }
+ this.holdingParts[fingerId].part.partIcon.position = hook.pos;
}
}
@@ -306,8 +309,12 @@ public void OnTouchEnd(int fingerId, Vector2 touchPosWorld)
bool flag2 = this.pickGrid.IsInsideDropArea(Utility.ToDepth(v, this.pickMenuDistance));
if (flag && !flag2)
{
- this.dragAndDropInstruction.InvokeEvenets();
- this.buildGrid.PlacePart(new PlacedPart(null, (Vector3)autoCorrect - this.buildGrid.transform.position, this.holdingParts[fingerId].part.orientation.DeepCopy(), this.holdingParts[fingerId].part.partData));
+ PlacedPart newPart = new PlacedPart(null, (Vector3)autoCorrect - this.buildGrid.transform.position, this.holdingParts[fingerId].part.orientation.DeepCopy(), this.holdingParts[fingerId].part.partData);
+ MyPartCreatedHook hook = new MyPartCreatedHook(newPart);
+ hook = MyHookSystem.executeHook(hook);
+ if (hook.isCanceled()) { return; }
+ this.dragAndDropInstruction.InvokeEvenets();
+ this.buildGrid.PlacePart(hook.target);
}
if (this.holdingParts[fingerId].part.partIcon != null)
{
@@ -507,8 +514,8 @@ private void TryLaunch()
private void GoForLaunch()
{
- MyRocketLaunchHook result = ModLoader.manager.castHook(new MyRocketLaunchHook(this.buildGrid.parts));
- if (result.isCanceled()) return;
+ MyRocketToLaunchpadHook res = MyHookSystem.executeHook(new MyRocketToLaunchpadHook());
+ if (res.isCanceled()) return;
string jsonString = JsonUtility.ToJson(new Build.BuildSave("To Launch", Ref.cam.transform.position, this.buildGrid.parts));
Ref.SaveJsonString(jsonString, Saving.SaveKey.ToLaunch);
Ref.LoadScene(Ref.SceneType.Game);
@@ -535,9 +542,5 @@ public void EnableDescription()
{
}
- public void OnGUI()
- {
- ModLoader.manager.castHook(new MyBuildMenuOnGuiHook());
- }
}
}
diff --git a/Source/Part.cs b/Source/Part.cs
index 8c0d6a0..d95921a 100644
--- a/Source/Part.cs
+++ b/Source/Part.cs
@@ -1,6 +1,7 @@
using NewBuildSystem;
using SFSML;
-using SFSML.GameManager.Hooks.PartRelated;
+using SFSML.HookSystem.ReWork;
+using SFSML.HookSystem.ReWork.BaseHooks.PartHooks;
using Sirenix.OdinInspector;
using System;
using System.Collections.Generic;
@@ -198,7 +199,7 @@ public void UsePart()
{
try
{
- MyOnUseHook result = ModLoader.manager.castHook(new MyOnUseHook(this));
+ MyPartUsedHook result = MyHookSystem.executeHook(new MyPartUsedHook(this));
if (result.isCanceled()) { return; }
}
catch (Exception e)
@@ -230,8 +231,8 @@ public void Collision(Collision2D collision)
public void DestroyPart(bool createExplosion, bool disablePartToPartDamage)
{
- MyBeforeDestroyHook hook = new MyBeforeDestroyHook(this);
- hook = ModLoader.manager.castHook(hook);
+ MyPartUsedHook hook = new MyPartUsedHook(this);
+ hook = MyHookSystem.executeHook(hook);
if (hook.isCanceled()) return;
while (this.joints.Count > 0)
{
diff --git a/Source/Ref.cs b/Source/Ref.cs
index 6d03457..62381df 100644
--- a/Source/Ref.cs
+++ b/Source/Ref.cs
@@ -9,8 +9,9 @@
using System.Text;
using UnityEngine;
using UnityEngine.SceneManagement;
-using SFSML.GameManager.Hooks.UnityRelated;
-using SFSML.GameManager.Hooks.FrameRelated;
+using SFSML.HookSystem.ReWork;
+using SFSML.HookSystem.ReWork.BaseHooks;
+using SFSML.HookSystem.ReWork.BaseHooks.FrameHooks;
public class Ref : MonoBehaviour
{
@@ -230,13 +231,13 @@ private Double3 VelocityOffset
public static void LoadScene(Ref.SceneType sceneToLoad)
{
- MySceneChangeHook res = ModLoader.manager.castHook(new MySceneChangeHook(Ref.lastScene, sceneToLoad));
+ MySceneChangeHook res = MyHookSystem.executeHook(new MySceneChangeHook(Ref.lastScene, sceneToLoad));
if (res.isCanceled()) return;
- sceneToLoad = res.targetScene;
+ sceneToLoad = res.newScene;
Ref.SceneType oldScene = Ref.lastScene;
Ref.lastScene = Ref.currentScene;
SceneManager.LoadScene(sceneToLoad.ToString(), LoadSceneMode.Single);
- ModLoader.manager.castHook(new MySceneChangedHook(oldScene, sceneToLoad));
+ MyHookSystem.executeHook(new MySceneChangedHook(oldScene, sceneToLoad));
}
public static int GetFigure(double value)
@@ -379,8 +380,7 @@ public static CelestialBodyData GetPlanetByName(string adress)
private void OnGUI()
{
- if (ModLoader.manager != null)
- ModLoader.manager.castHook(new MyGeneralOnGuiHook(this.CurrentScene));
+ MyHookSystem.executeHook(new MyOnGuiHook(Ref.currentScene));
}
public static float GetSizeOfWord(TextMesh text, string word)
diff --git a/Source/ResourceModule.cs b/Source/ResourceModule.cs
index 906d500..c9e487e 100644
--- a/Source/ResourceModule.cs
+++ b/Source/ResourceModule.cs
@@ -1,5 +1,6 @@
using SFSML;
-using SFSML.GameManager.Hooks.ModuleRelated;
+using SFSML.HookSystem.ReWork;
+using SFSML.HookSystem.ReWork.BaseHooks.PartHooks;
using Sirenix.OdinInspector;
using System;
using System.Collections.Generic;
@@ -91,16 +92,10 @@ public Grup(ResourceModule start)
public void TakeResource(float removeAmount)
{
- MyResourceOnTakeHook hook = new MyResourceOnTakeHook(this, removeAmount);
- try
- {
- hook = ModLoader.manager.castHook(hook);
- if (hook.isCanceled()) return;
- } catch (Exception e)
- {
- ModLoader.mainConsole.logError(e);
- }
- this.resourceAmount = Mathf.Max(this.resourceAmount - hook.amount, 0f);
+ float newAmount = this.resourceAmount - removeAmount;
+ MyDrainResourceHook hook = new MyDrainResourceHook(removeAmount, newAmount, this);
+ hook = MyHookSystem.executeHook(hook);
+ this.resourceAmount = Mathf.Max(this.resourceAmount - hook.amountToTake, 0f);
this.SetTanks();
}
diff --git a/Source/SFSML/Attributes/MyHookListener.cs b/Source/SFSML/Attributes/MyHookListener.cs
new file mode 100644
index 0000000..fee79cd
--- /dev/null
+++ b/Source/SFSML/Attributes/MyHookListener.cs
@@ -0,0 +1,11 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.Attributes
+{
+ public class MyListenerAttribute : Attribute
+ {
+ }
+}
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/BuildHooks/MyPartCreatedHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/BuildHooks/MyPartCreatedHook.cs
new file mode 100644
index 0000000..ec7de63
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/BuildHooks/MyPartCreatedHook.cs
@@ -0,0 +1,20 @@
+using NewBuildSystem;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.BuildHooks
+{
+ ///
+ /// Called when user drags a part from the part menu and it gets created for the first time.
+ ///
+ public class MyPartCreatedHook : MyHook
+ {
+ public PlacedPart target;
+ public MyPartCreatedHook(PlacedPart targetPart)
+ {
+ this.target = targetPart;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/BuildHooks/MyPartStartDragHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/BuildHooks/MyPartStartDragHook.cs
new file mode 100644
index 0000000..d551b7f
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/BuildHooks/MyPartStartDragHook.cs
@@ -0,0 +1,20 @@
+using NewBuildSystem;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using UnityEngine;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.BuildHooks
+{
+ public class MyPartStartDragHook : MyHook
+ {
+ public PlacedPart target;
+ public Vector3 pos;
+ public MyPartStartDragHook(PlacedPart part, Vector3 newPos)
+ {
+ this.target = part;
+ this.pos = newPos;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/BuildHooks/MyRocketToLaunchpadHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/BuildHooks/MyRocketToLaunchpadHook.cs
new file mode 100644
index 0000000..921c523
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/BuildHooks/MyRocketToLaunchpadHook.cs
@@ -0,0 +1,11 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.BuildHooks
+{
+ public class MyRocketToLaunchpadHook : MyHook
+ {
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/FrameHooks/MyOnGuiHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/FrameHooks/MyOnGuiHook.cs
new file mode 100644
index 0000000..2537172
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/FrameHooks/MyOnGuiHook.cs
@@ -0,0 +1,16 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.FrameHooks
+{
+ public class MyOnGuiHook : MyHook
+ {
+ public Ref.SceneType currentScene;
+ public MyOnGuiHook(Ref.SceneType scene)
+ {
+ this.currentScene = scene;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/FrameHooks/MySceneChangeHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/FrameHooks/MySceneChangeHook.cs
new file mode 100644
index 0000000..40d60c8
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/FrameHooks/MySceneChangeHook.cs
@@ -0,0 +1,18 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.FrameHooks
+{
+ public class MySceneChangeHook : MyHook
+ {
+ public Ref.SceneType oldScene;
+ public Ref.SceneType newScene;
+ public MySceneChangeHook(Ref.SceneType current, Ref.SceneType target)
+ {
+ this.oldScene = current;
+ this.newScene = target;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/FrameHooks/MySceneChangedHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/FrameHooks/MySceneChangedHook.cs
new file mode 100644
index 0000000..1d84d6c
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/FrameHooks/MySceneChangedHook.cs
@@ -0,0 +1,18 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.FrameHooks
+{
+ public class MySceneChangedHook : MyHook
+ {
+ public Ref.SceneType oldScene;
+ public Ref.SceneType newScene;
+ public MySceneChangedHook(Ref.SceneType current, Ref.SceneType target)
+ {
+ this.oldScene = current;
+ this.newScene = target;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/PartHooks/MyDrainResourceHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/PartHooks/MyDrainResourceHook.cs
new file mode 100644
index 0000000..0bb91fa
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/PartHooks/MyDrainResourceHook.cs
@@ -0,0 +1,23 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.PartHooks
+{
+ public class MyDrainResourceHook : MyHook
+ {
+ ///
+ /// Can be changed to edit what amount should be removed from the tank.
+ ///
+ public float amountToTake;
+ public float newAmount;
+ public ResourceModule.Grup part;
+ public MyDrainResourceHook(float take, float newA, ResourceModule.Grup targetPart)
+ {
+ this.amountToTake = take;
+ this.newAmount = newA;
+ this.part = targetPart;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/PartHooks/MyPartBeforeDestroyHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/PartHooks/MyPartBeforeDestroyHook.cs
new file mode 100644
index 0000000..9455744
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/PartHooks/MyPartBeforeDestroyHook.cs
@@ -0,0 +1,16 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.PartHooks
+{
+ public class MyPartBeforeDestroyHook : MyHook
+ {
+ public Part part;
+ public MyPartBeforeDestroyHook(Part targetPart)
+ {
+ this.part = targetPart;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/PartHooks/MyPartUsedHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/PartHooks/MyPartUsedHook.cs
new file mode 100644
index 0000000..cd75860
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/PartHooks/MyPartUsedHook.cs
@@ -0,0 +1,16 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.PartHooks
+{
+ public class MyPartUsedHook : MyHook
+ {
+ public Part used;
+ public MyPartUsedHook(Part targetPart)
+ {
+ this.used = targetPart;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MyKeyDownHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MyKeyDownHook.cs
new file mode 100644
index 0000000..5a2bda9
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MyKeyDownHook.cs
@@ -0,0 +1,18 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using UnityEngine;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.UtilHooks
+{
+ public class MyKeyDownHook : MyHook
+ {
+ public KeyCode keyDown;
+ public bool register;
+ public MyKeyDownHook(KeyCode key)
+ {
+ this.keyDown = key;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MyKeyUpHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MyKeyUpHook.cs
new file mode 100644
index 0000000..048ce45
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MyKeyUpHook.cs
@@ -0,0 +1,18 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using UnityEngine;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.UtilHooks
+{
+ public class MyKeyUpHook : MyHook
+ {
+ KeyCode keyUp;
+ public bool register;
+ public MyKeyUpHook(KeyCode key)
+ {
+ this.keyUp = key;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MyModLoadedHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MyModLoadedHook.cs
new file mode 100644
index 0000000..e29bf28
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MyModLoadedHook.cs
@@ -0,0 +1,16 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.UtilHooks
+{
+ public class MyModLoadedHook
+ {
+ public MyMod targetHook;
+ public MyModLoadedHook(MyMod mod)
+ {
+ this.targetHook = mod;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MySceneChangeHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MySceneChangeHook.cs
new file mode 100644
index 0000000..701a1f2
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MySceneChangeHook.cs
@@ -0,0 +1,19 @@
+using SFSML.HookSystem.ReWork;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.UtilHooks
+{
+ public class MySceneChangeHook : MyHook
+ {
+ public Ref.SceneType oldScene;
+ public Ref.SceneType newScene;
+ public MySceneChangeHook(Ref.SceneType old, Ref.SceneType nw)
+ {
+ this.oldScene = old;
+ this.newScene = nw;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MySceneChangedHook.cs b/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MySceneChangedHook.cs
new file mode 100644
index 0000000..800c355
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/BaseHooks/UtilHooks/MySceneChangedHook.cs
@@ -0,0 +1,19 @@
+using SFSML.HookSystem.ReWork;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork.BaseHooks.UtilHooks
+{
+ public class MySceneChangedHook : MyHook
+ {
+ public Ref.SceneType oldScene;
+ public Ref.SceneType newScene;
+ public MySceneChangedHook(Ref.SceneType old, Ref.SceneType nw)
+ {
+ this.oldScene = old;
+ this.newScene = nw;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/MyHook.cs b/Source/SFSML/HookSystem/ReWork/MyHook.cs
new file mode 100644
index 0000000..310fd9f
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/MyHook.cs
@@ -0,0 +1,26 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork
+{
+ public class MyHook : ICloneable
+ {
+ private bool cancel;
+ public object Clone()
+ {
+ return this.MemberwiseClone();
+ }
+
+ public bool isCanceled()
+ {
+ return this.cancel;
+ }
+
+ public void setCanceled(bool can)
+ {
+ this.cancel = can;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/MyHookListener.cs b/Source/SFSML/HookSystem/ReWork/MyHookListener.cs
new file mode 100644
index 0000000..e48d4cb
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/MyHookListener.cs
@@ -0,0 +1,68 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Reflection;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork
+{
+ public class MyHookListener
+ {
+ public readonly Type targetHook;
+ public readonly Func listenMethod;
+
+ ///
+ /// Runtime method.
+ ///
+ ///
+ public MyHookListener(Func method,Type target)
+ {
+ this.targetHook = target;
+ this.listenMethod = method;
+ MyHookSystem.listeners.Add(this);
+ }
+
+ ///
+ /// Init method.
+ ///
+ ///
+ ///
+ public MyHookListener(MethodInfo listenMethod, object context)
+ {
+ this.targetHook = listenMethod.GetParameters()[0].ParameterType;
+ Type retType = listenMethod.ReturnType;
+ if (!IsSubclassOfRawGeneric(typeof(MyHook), retType))
+ {
+ throw new Exception("Does not return a subtype of MyHook.");
+ }
+ this.listenMethod = (e) =>
+ {
+ return (MyHook) listenMethod.Invoke(context, new object[] { e });
+ };
+ MyHookSystem.listeners.Add(this);
+ }
+
+
+ public MyHook invokeHook(MyHook e)
+ {
+ return this.listenMethod(e);
+ }
+
+
+ static bool IsSubclassOfRawGeneric(Type generic, Type toCheck)
+ {
+ while (toCheck != null && toCheck != typeof(object))
+ {
+ var cur = toCheck.IsGenericType ? toCheck.GetGenericTypeDefinition() : toCheck;
+ if (generic == cur)
+ {
+ return true;
+ }
+ toCheck = toCheck.BaseType;
+ }
+ return false;
+ }
+
+
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/HookSystem/ReWork/MyHookSystem.cs b/Source/SFSML/HookSystem/ReWork/MyHookSystem.cs
new file mode 100644
index 0000000..3b914e3
--- /dev/null
+++ b/Source/SFSML/HookSystem/ReWork/MyHookSystem.cs
@@ -0,0 +1,41 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Reflection;
+using System.Text;
+
+namespace SFSML.HookSystem.ReWork
+{
+ public class MyHookSystem
+ {
+ public static List listeners = new List();
+ public static T executeHook(T baseHook)
+ {
+ MyHook hookToEdit = (MyHook)((MyHook)(object)baseHook).Clone();
+ bool cancel = false;
+ FieldInfo[] mainFields = hookToEdit.GetType().GetFields(BindingFlags.NonPublic | BindingFlags.Public | BindingFlags.Instance);
+ List safeCopy = new List(MyHookSystem.listeners);
+ foreach (MyHookListener listener in safeCopy)
+ {
+ if (!listener.targetHook.Equals(typeof(T))) continue;
+ MyHook invokeResult = listener.invokeHook(hookToEdit);
+ if (invokeResult.isCanceled())
+ {
+ cancel = true;
+ }
+ foreach (FieldInfo field in mainFields)
+ {
+ FieldInfo targetField = invokeResult.GetType().GetField(field.Name, BindingFlags.NonPublic | BindingFlags.Public | BindingFlags.Instance);
+ object mainFieldContent = field.GetValue(hookToEdit);
+ object invokedFieldContent = targetField.GetValue(invokeResult);
+ if (mainFieldContent != invokedFieldContent)
+ {
+ field.SetValue(hookToEdit, invokedFieldContent);
+ }
+ }
+ }
+ hookToEdit.setCanceled(cancel);
+ return (T)(object)hookToEdit;
+ }
+ }
+}
\ No newline at end of file
diff --git a/Source/SFSML/ModLoader.cs b/Source/SFSML/ModLoader.cs
index aaa1897..3f79bff 100644
--- a/Source/SFSML/ModLoader.cs
+++ b/Source/SFSML/ModLoader.cs
@@ -15,12 +15,12 @@
using SFSML.HookSystem;
using SFSML.Exceptions;
using SFSML.Attributes;
-using SFSML.GameManager;
using System.Collections.Generic;
-using SFSML.GameManager.Hooks.InputRelated;
using System.Threading;
using Assets.SFSML.Utility;
-using Assets.SFSML.GameManager.Hooks.ModLoader;
+using UnityEngine.Purchasing;
+using SFSML.HookSystem.ReWork;
+using SFSML.HookSystem.ReWork.BaseHooks.UtilHooks;
namespace SFSML
{
@@ -28,7 +28,7 @@ namespace SFSML
/// The coreclass of SFSML.
///
[MyModEntryPoint]
- public class ModLoader : MyBaseHookable
+ public class ModLoader
{
public static MyConsole mainConsole;
@@ -41,9 +41,8 @@ public class ModLoader : MyBaseHookable
/// This will receive all the NON-STATIC OBJECT hooks.
/// Things like the main entry point of the game will have their own hook manager!
///
- public readonly static MyGameManager manager = new MyGameManager();
- public static readonly string version = "1.0.0.R1";
+ public static readonly string version = "1.0.0.R2";
private static readonly string logTag = "ModLoader "+version;
private GameObject overlay;
public ModLoader()
@@ -164,23 +163,12 @@ private void loadModFromFile(String modFile)
mainConsole.log("Loading mod: " + modFileName, logTag);
Assembly modAssembly = Assembly.LoadFrom(modFile);
MyMod entryObject = null;
- bool hasTextureHolder = false;
- MyAssetHolder textureHolder = null;
foreach (Type modType in modAssembly.GetTypes())
{
object[] attributeList = modType.GetCustomAttributes(typeof(MyModEntryPoint), true);
if (attributeList.Length == 1)
{
entryObject = Activator.CreateInstance(modType) as MyMod;
- foreach (FieldInfo fi in modType.GetFields(BindingFlags.Instance | BindingFlags.Public))
- {
- if (fi.FieldType.Equals(typeof(MyAssetHolder)))
- {
- mainConsole.tryLogCustom("Assigning assetHolder", logTag, LogType.Generic);
- hasTextureHolder = true;
- textureHolder = fi.GetValue(entryObject) as MyAssetHolder;
- }
- }
}
}
if (entryObject == null)
@@ -205,11 +193,20 @@ private void loadModFromFile(String modFile)
}
string dataPath = this.getMyDataDirectory() + modFileName;
entryObject.assignDataPath(dataPath);
+ MethodInfo[] methods = entryObject.GetType().GetMethods(BindingFlags.NonPublic | BindingFlags.Public | BindingFlags.Instance);
+ foreach (MethodInfo method in methods)
+ {
+ MyListenerAttribute[] att = (MyListenerAttribute[]) method.GetCustomAttributes(typeof(MyListenerAttribute), true);
+ if (att.Length == 1)
+ {
+ new HookSystem.ReWork.MyHookListener(method,entryObject);
+ }
+ }
entryObject.Load();
mainConsole.tryLogCustom("Loaded " + entryObject.myName+".\n"+entryObject.myDescription+"\nVersion "+entryObject.myVersion, logTag, LogType.Generic);
this.loadedMods++;
mods[entryObject.myName] = entryObject;
- manager.castHook(new MyModLoadedHook(entryObject));
+ MyHookSystem.executeHook(new MyModLoadedHook(entryObject));
}
catch (MyCoreException e)
{
@@ -241,7 +238,7 @@ private void KeyUpdate()
{
if (!keyDown.Contains(code))
{
- MyKeyDownHook result = manager.castHook(new MyKeyDownHook(code,true));
+ MyKeyDownHook result = MyHookSystem.executeHook(new MyKeyDownHook(code));
if (result.isCanceled())
{
if (result.register)
@@ -261,8 +258,8 @@ private void KeyUpdate()
{
if (!Input.GetKey(down))
{
- MyKeyUpHook hook = new MyKeyUpHook(down, true);
- MyKeyUpHook result = ModLoader.manager.castHook(hook);
+ MyKeyUpHook hook = new MyKeyUpHook(down);
+ MyKeyUpHook result = MyHookSystem.executeHook(hook);
if (result.isCanceled())
{
if (result.register)
diff --git a/Source/SFSML/MyMod.cs b/Source/SFSML/MyMod.cs
index e875c39..cb8fa23 100644
--- a/Source/SFSML/MyMod.cs
+++ b/Source/SFSML/MyMod.cs
@@ -8,7 +8,7 @@
namespace SFSML
{
- public abstract class MyMod : MyBaseHookable
+ public abstract class MyMod
{
public readonly String myName;
public readonly String myDescription;
@@ -83,7 +83,7 @@ public bool LoadAssets(string path)
AssetBundle ab = AssetBundle.LoadFromFile(file);
if (ab == null)
{
- ModLoader.mainConsole.tryLogCustom("Tried to load ModLoader-Assets from " + file + ", but failed.", this.myName, LogType.Generic);
+ ModLoader.mainConsole.tryLogCustom("Tried to load ModLoader-Assets from " + file + ", but failed.", this.myName, LogType.Error);
continue;
}
this.assetHolder = new MyAssetHolder(ab);
@@ -94,7 +94,7 @@ public bool LoadAssets(string path)
}
else
{
- ModLoader.mainConsole.tryLogCustom("Mod doesn't have asset folder. Skippig asset load proccess", this.myName, LogType.Generic);
+ ModLoader.mainConsole.tryLogCustom("Mod doesn't have asset folder. Skipping asset load proccess", this.myName, LogType.Generic);
}
return false;
}
diff --git a/Source/obj/Debug/CoreCompileInputs.cache b/Source/obj/Debug/CoreCompileInputs.cache
new file mode 100644
index 0000000..cb8f8fe
--- /dev/null
+++ b/Source/obj/Debug/CoreCompileInputs.cache
@@ -0,0 +1 @@
+67628c62b17003f299448487a5786452e5b152e0
diff --git a/Source/obj/Release/CoreCompileInputs.cache b/Source/obj/Release/CoreCompileInputs.cache
new file mode 100644
index 0000000..cb8f8fe
--- /dev/null
+++ b/Source/obj/Release/CoreCompileInputs.cache
@@ -0,0 +1 @@
+67628c62b17003f299448487a5786452e5b152e0
diff --git a/Source/sfsml_proj.unity b/Source/sfsml_proj.unity
new file mode 100644
index 0000000..48568b8
--- /dev/null
+++ b/Source/sfsml_proj.unity
@@ -0,0 +1,478 @@
+%YAML 1.1
+%TAG !u! tag:unity3d.com,2011:
+--- !u!29 &1
+OcclusionCullingSettings:
+ m_ObjectHideFlags: 0
+ serializedVersion: 2
+ m_OcclusionBakeSettings:
+ smallestOccluder: 5
+ smallestHole: 0.25
+ backfaceThreshold: 100
+ m_SceneGUID: 00000000000000000000000000000000
+ m_OcclusionCullingData: {fileID: 0}
+--- !u!104 &2
+RenderSettings:
+ m_ObjectHideFlags: 0
+ serializedVersion: 8
+ m_Fog: 0
+ m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1}
+ m_FogMode: 3
+ m_FogDensity: 0.01
+ m_LinearFogStart: 0
+ m_LinearFogEnd: 300
+ m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1}
+ m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1}
+ m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1}
+ m_AmbientIntensity: 1
+ m_AmbientMode: 3
+ m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1}
+ m_SkyboxMaterial: {fileID: 0}
+ m_HaloStrength: 0.5
+ m_FlareStrength: 1
+ m_FlareFadeSpeed: 3
+ m_HaloTexture: {fileID: 0}
+ m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0}
+ m_DefaultReflectionMode: 0
+ m_DefaultReflectionResolution: 128
+ m_ReflectionBounces: 1
+ m_ReflectionIntensity: 1
+ m_CustomReflection: {fileID: 0}
+ m_Sun: {fileID: 0}
+ m_IndirectSpecularColor: {r: 0, g: 0, b: 0, a: 1}
+--- !u!157 &3
+LightmapSettings:
+ m_ObjectHideFlags: 0
+ serializedVersion: 11
+ m_GIWorkflowMode: 1
+ m_GISettings:
+ serializedVersion: 2
+ m_BounceScale: 1
+ m_IndirectOutputScale: 1
+ m_AlbedoBoost: 1
+ m_TemporalCoherenceThreshold: 1
+ m_EnvironmentLightingMode: 0
+ m_EnableBakedLightmaps: 0
+ m_EnableRealtimeLightmaps: 0
+ m_LightmapEditorSettings:
+ serializedVersion: 9
+ m_Resolution: 2
+ m_BakeResolution: 40
+ m_TextureWidth: 1024
+ m_TextureHeight: 1024
+ m_AO: 0
+ m_AOMaxDistance: 1
+ m_CompAOExponent: 1
+ m_CompAOExponentDirect: 0
+ m_Padding: 2
+ m_LightmapParameters: {fileID: 0}
+ m_LightmapsBakeMode: 1
+ m_TextureCompression: 1
+ m_FinalGather: 0
+ m_FinalGatherFiltering: 1
+ m_FinalGatherRayCount: 256
+ m_ReflectionCompression: 2
+ m_MixedBakeMode: 2
+ m_BakeBackend: 0
+ m_PVRSampling: 1
+ m_PVRDirectSampleCount: 32
+ m_PVRSampleCount: 500
+ m_PVRBounces: 2
+ m_PVRFilterTypeDirect: 0
+ m_PVRFilterTypeIndirect: 0
+ m_PVRFilterTypeAO: 0
+ m_PVRFilteringMode: 1
+ m_PVRCulling: 1
+ m_PVRFilteringGaussRadiusDirect: 1
+ m_PVRFilteringGaussRadiusIndirect: 5
+ m_PVRFilteringGaussRadiusAO: 2
+ m_PVRFilteringAtrousPositionSigmaDirect: 0.5
+ m_PVRFilteringAtrousPositionSigmaIndirect: 2
+ m_PVRFilteringAtrousPositionSigmaAO: 1
+ m_ShowResolutionOverlay: 1
+ m_LightingDataAsset: {fileID: 0}
+ m_UseShadowmask: 1
+--- !u!196 &4
+NavMeshSettings:
+ serializedVersion: 2
+ m_ObjectHideFlags: 0
+ m_BuildSettings:
+ serializedVersion: 2
+ agentTypeID: 0
+ agentRadius: 0.5
+ agentHeight: 2
+ agentSlope: 45
+ agentClimb: 0.4
+ ledgeDropHeight: 0
+ maxJumpAcrossDistance: 0
+ minRegionArea: 2
+ manualCellSize: 0
+ cellSize: 0.16666667
+ manualTileSize: 0
+ tileSize: 256
+ accuratePlacement: 0
+ debug:
+ m_Flags: 0
+ m_NavMeshData: {fileID: 0}
+--- !u!1 &52112650
+GameObject:
+ m_ObjectHideFlags: 0
+ m_PrefabParentObject: {fileID: 0}
+ m_PrefabInternal: {fileID: 0}
+ serializedVersion: 5
+ m_Component:
+ - component: {fileID: 52112654}
+ - component: {fileID: 52112653}
+ - component: {fileID: 52112652}
+ - component: {fileID: 52112651}
+ m_Layer: 0
+ m_Name: Main Camera
+ m_TagString: MainCamera
+ m_Icon: {fileID: 0}
+ m_NavMeshLayer: 0
+ m_StaticEditorFlags: 0
+ m_IsActive: 1
+--- !u!81 &52112651
+AudioListener:
+ m_ObjectHideFlags: 0
+ m_PrefabParentObject: {fileID: 0}
+ m_PrefabInternal: {fileID: 0}
+ m_GameObject: {fileID: 52112650}
+ m_Enabled: 1
+--- !u!124 &52112652
+Behaviour:
+ m_ObjectHideFlags: 0
+ m_PrefabParentObject: {fileID: 0}
+ m_PrefabInternal: {fileID: 0}
+ m_GameObject: {fileID: 52112650}
+ m_Enabled: 1
+--- !u!20 &52112653
+Camera:
+ m_ObjectHideFlags: 0
+ m_PrefabParentObject: {fileID: 0}
+ m_PrefabInternal: {fileID: 0}
+ m_GameObject: {fileID: 52112650}
+ m_Enabled: 1
+ serializedVersion: 2
+ m_ClearFlags: 1
+ m_BackGroundColor: {r: 1, g: 0.50735295, b: 0.50735295, a: 1}
+ m_NormalizedViewPortRect:
+ serializedVersion: 2
+ x: 0
+ y: 0
+ width: 1
+ height: 1
+ near clip plane: 0.3
+ far clip plane: 1000
+ field of view: 60
+ orthographic: 1
+ orthographic size: 5
+ m_Depth: -1
+ m_CullingMask:
+ serializedVersion: 2
+ m_Bits: 4294967295
+ m_RenderingPath: -1
+ m_TargetTexture: {fileID: 0}
+ m_TargetDisplay: 0
+ m_TargetEye: 3
+ m_HDR: 1
+ m_AllowMSAA: 1
+ m_AllowDynamicResolution: 0
+ m_ForceIntoRT: 0
+ m_OcclusionCulling: 1
+ m_StereoConvergence: 10
+ m_StereoSeparation: 0.022
+--- !u!4 &52112654
+Transform:
+ m_ObjectHideFlags: 0
+ m_PrefabParentObject: {fileID: 0}
+ m_PrefabInternal: {fileID: 0}
+ m_GameObject: {fileID: 52112650}
+ m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
+ m_LocalPosition: {x: 0, y: 0, z: -10}
+ m_LocalScale: {x: 1, y: 1, z: 1}
+ m_Children: []
+ m_Father: {fileID: 0}
+ m_RootOrder: 0
+ m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
+--- !u!1001 &106041034
+Prefab:
+ m_ObjectHideFlags: 0
+ serializedVersion: 2
+ m_Modification:
+ m_TransformParent: {fileID: 0}
+ m_Modifications:
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_LocalPosition.x
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_LocalPosition.y
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_LocalPosition.z
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_LocalRotation.x
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_LocalRotation.y
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_LocalRotation.z
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_LocalRotation.w
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_RootOrder
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchoredPosition.x
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchoredPosition.y
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_SizeDelta.x
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_SizeDelta.y
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMin.x
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMin.y
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.x
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.y
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_Pivot.x
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224837287458710002, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_Pivot.y
+ value: 0
+ objectReference: {fileID: 0}
+ - target: {fileID: 224094204168789442, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.x
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224094204168789442, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.y
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224243678807994634, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.x
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224243678807994634, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.y
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224593222887912688, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.x
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224593222887912688, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.y
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224223388176973422, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.x
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224223388176973422, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.y
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224627099327784512, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.x
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224627099327784512, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.y
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224627099327784512, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_SizeDelta.x
+ value: -17
+ objectReference: {fileID: 0}
+ - target: {fileID: 224627099327784512, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_SizeDelta.y
+ value: -17
+ objectReference: {fileID: 0}
+ - target: {fileID: 224115041303937318, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.x
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224115041303937318, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_SizeDelta.x
+ value: -17
+ objectReference: {fileID: 0}
+ - target: {fileID: 224663998688316600, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.y
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224663998688316600, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_SizeDelta.y
+ value: -17
+ objectReference: {fileID: 0}
+ - target: {fileID: 224955009841009212, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.x
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224955009841009212, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.y
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224955009841009212, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_SizeDelta.x
+ value: -17
+ objectReference: {fileID: 0}
+ - target: {fileID: 224955009841009212, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_SizeDelta.y
+ value: -17
+ objectReference: {fileID: 0}
+ - target: {fileID: 224944865977290456, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.x
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224944865977290456, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_SizeDelta.x
+ value: -17
+ objectReference: {fileID: 0}
+ - target: {fileID: 224035371931222276, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_AnchorMax.y
+ value: 1
+ objectReference: {fileID: 0}
+ - target: {fileID: 224035371931222276, guid: ee38840bb975cb94a875938ae5df89d7,
+ type: 2}
+ propertyPath: m_SizeDelta.y
+ value: -17
+ objectReference: {fileID: 0}
+ m_RemovedComponents: []
+ m_ParentPrefab: {fileID: 100100000, guid: ee38840bb975cb94a875938ae5df89d7, type: 2}
+ m_IsPrefabParent: 0
+--- !u!1 &487428671
+GameObject:
+ m_ObjectHideFlags: 0
+ m_PrefabParentObject: {fileID: 0}
+ m_PrefabInternal: {fileID: 0}
+ serializedVersion: 5
+ m_Component:
+ - component: {fileID: 487428674}
+ - component: {fileID: 487428673}
+ - component: {fileID: 487428672}
+ m_Layer: 0
+ m_Name: EventSystem
+ m_TagString: Untagged
+ m_Icon: {fileID: 0}
+ m_NavMeshLayer: 0
+ m_StaticEditorFlags: 0
+ m_IsActive: 1
+--- !u!114 &487428672
+MonoBehaviour:
+ m_ObjectHideFlags: 0
+ m_PrefabParentObject: {fileID: 0}
+ m_PrefabInternal: {fileID: 0}
+ m_GameObject: {fileID: 487428671}
+ m_Enabled: 1
+ m_EditorHideFlags: 0
+ m_Script: {fileID: 1077351063, guid: f70555f144d8491a825f0804e09c671c, type: 3}
+ m_Name:
+ m_EditorClassIdentifier:
+ m_HorizontalAxis: Horizontal
+ m_VerticalAxis: Vertical
+ m_SubmitButton: Submit
+ m_CancelButton: Cancel
+ m_InputActionsPerSecond: 10
+ m_RepeatDelay: 0.5
+ m_ForceModuleActive: 0
+--- !u!114 &487428673
+MonoBehaviour:
+ m_ObjectHideFlags: 0
+ m_PrefabParentObject: {fileID: 0}
+ m_PrefabInternal: {fileID: 0}
+ m_GameObject: {fileID: 487428671}
+ m_Enabled: 1
+ m_EditorHideFlags: 0
+ m_Script: {fileID: -619905303, guid: f70555f144d8491a825f0804e09c671c, type: 3}
+ m_Name:
+ m_EditorClassIdentifier:
+ m_FirstSelected: {fileID: 0}
+ m_sendNavigationEvents: 1
+ m_DragThreshold: 5
+--- !u!4 &487428674
+Transform:
+ m_ObjectHideFlags: 0
+ m_PrefabParentObject: {fileID: 0}
+ m_PrefabInternal: {fileID: 0}
+ m_GameObject: {fileID: 487428671}
+ m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
+ m_LocalPosition: {x: 0, y: 0, z: 0}
+ m_LocalScale: {x: 1, y: 1, z: 1}
+ m_Children: []
+ m_Father: {fileID: 0}
+ m_RootOrder: 2
+ m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}