diff --git a/Assets/Scenes/FactorySceneRefactor.unity b/Assets/Scenes/FactorySceneRefactor.unity index c845d0b..008ac55 100644 --- a/Assets/Scenes/FactorySceneRefactor.unity +++ b/Assets/Scenes/FactorySceneRefactor.unity @@ -627,82 +627,6 @@ Light: m_UseViewFrustumForShadowCasterCull: 1 m_ShadowRadius: 0 m_ShadowAngle: 0 ---- !u!1 &121661299 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 121661300} - - component: {fileID: 121661302} - - component: {fileID: 121661301} - m_Layer: 5 - m_Name: TextPanel - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!224 &121661300 -RectTransform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 121661299} - 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: - - {fileID: 409868026} - m_Father: {fileID: 1148227745} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0.5, y: 0} - m_AnchorMax: {x: 0.5, y: 0} - m_AnchoredPosition: {x: 0, y: -15} - m_SizeDelta: {x: 128, y: 30} - m_Pivot: {x: 0.5, y: 0.5} ---- !u!114 &121661301 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 121661299} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} - m_Name: - m_EditorClassIdentifier: - m_Material: {fileID: 0} - m_Color: {r: 0.21960786, g: 0.21960786, b: 0.21960786, a: 0.392} - m_RaycastTarget: 1 - m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} - m_Maskable: 1 - m_OnCullStateChanged: - m_PersistentCalls: - m_Calls: [] - m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0} - m_Type: 1 - m_PreserveAspect: 1 - m_FillCenter: 1 - m_FillMethod: 4 - m_FillAmount: 1 - m_FillClockwise: 1 - m_FillOrigin: 2 - m_UseSpriteMesh: 1 - m_PixelsPerUnitMultiplier: 1 ---- !u!222 &121661302 -CanvasRenderer: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 121661299} - m_CullTransparentMesh: 0 --- !u!1 &124338786 GameObject: m_ObjectHideFlags: 0 @@ -1439,7 +1363,7 @@ Transform: - {fileID: 2136961954} - {fileID: 558760718} m_Father: {fileID: 0} - m_RootOrder: 1 + m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 90, z: 0} --- !u!114 &244415060 MonoBehaviour: @@ -1579,12 +1503,12 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 289008714} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 331.5, y: 130.5, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] - m_Father: {fileID: 629645471} - m_RootOrder: 1 + m_Father: {fileID: 0} + m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &289008716 MonoBehaviour: @@ -1682,7 +1606,7 @@ MonoBehaviour: m_faceColor: serializedVersion: 2 rgba: 4294967295 - m_fontSize: 64.85 + m_fontSize: 48.3 m_fontSizeBase: 36 m_fontWeight: 400 m_enableAutoSizing: 1 @@ -1732,6 +1656,82 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 302437816} m_CullTransparentMesh: 1 +--- !u!1 &351782238 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 351782239} + - component: {fileID: 351782241} + - component: {fileID: 351782240} + m_Layer: 5 + m_Name: InnerPanel + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &351782239 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 351782238} + 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: + - {fileID: 1105805518} + m_Father: {fileID: 674764865} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: -10, y: -10} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &351782240 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 351782238} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.392} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &351782241 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 351782238} + m_CullTransparentMesh: 1 --- !u!1 &353088461 GameObject: m_ObjectHideFlags: 0 @@ -1889,7 +1889,46 @@ Transform: type: 3} m_PrefabInstance: {fileID: 359816381} m_PrefabAsset: {fileID: 0} ---- !u!1 &409868025 +--- !u!1 &363737813 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 363737814} + m_Layer: 5 + m_Name: EquationSystemSelection + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &363737814 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 363737813} + 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: + - {fileID: 1398016557} + - {fileID: 913394910} + - {fileID: 1767776369} + - {fileID: 674764865} + m_Father: {fileID: 809097727} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.375, y: 1} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 64} + m_Pivot: {x: 0, y: 1} +--- !u!1 &380997637 GameObject: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} @@ -1897,9 +1936,9 @@ GameObject: m_PrefabAsset: {fileID: 0} serializedVersion: 6 m_Component: - - component: {fileID: 409868026} - - component: {fileID: 409868028} - - component: {fileID: 409868027} + - component: {fileID: 380997638} + - component: {fileID: 380997640} + - component: {fileID: 380997639} m_Layer: 5 m_Name: Text m_TagString: Untagged @@ -1907,32 +1946,32 @@ GameObject: m_NavMeshLayer: 0 m_StaticEditorFlags: 0 m_IsActive: 1 ---- !u!224 &409868026 +--- !u!224 &380997638 RectTransform: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 409868025} + m_GameObject: {fileID: 380997637} 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: 121661300} + m_Father: {fileID: 913394910} m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0.5, y: 0.5} - m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} m_AnchoredPosition: {x: 0, y: 0} - m_SizeDelta: {x: 128, y: 30} + m_SizeDelta: {x: 0, y: 0} m_Pivot: {x: 0.5, y: 0.5} ---- !u!114 &409868027 +--- !u!114 &380997639 MonoBehaviour: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 409868025} + m_GameObject: {fileID: 380997637} m_Enabled: 1 m_EditorHideFlags: 0 m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3} @@ -1946,7 +1985,9 @@ MonoBehaviour: m_OnCullStateChanged: m_PersistentCalls: m_Calls: [] - m_text: Load Scene + m_text: 'Next + + Eqsys' m_isRightToLeft: 0 m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} @@ -1955,8 +1996,8 @@ MonoBehaviour: m_fontMaterials: [] m_fontColor32: serializedVersion: 2 - rgba: 4294967295 - m_fontColor: {r: 1, g: 1, b: 1, a: 1} + rgba: 4278190080 + m_fontColor: {r: 0, g: 0, b: 0, a: 1} m_enableVertexGradient: 0 m_colorMode: 3 m_fontColorGradient: @@ -1973,10 +2014,10 @@ MonoBehaviour: m_faceColor: serializedVersion: 2 rgba: 4294967295 - m_fontSize: 16 - m_fontSizeBase: 16 + m_fontSize: 28.2 + m_fontSizeBase: 36 m_fontWeight: 400 - m_enableAutoSizing: 0 + m_enableAutoSizing: 1 m_fontSizeMin: 18 m_fontSizeMax: 72 m_fontStyle: 0 @@ -2015,13 +2056,13 @@ MonoBehaviour: m_hasFontAssetChanged: 0 m_baseMaterial: {fileID: 0} m_maskOffset: {x: 0, y: 0, z: 0, w: 0} ---- !u!222 &409868028 +--- !u!222 &380997640 CanvasRenderer: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 409868025} + m_GameObject: {fileID: 380997637} m_CullTransparentMesh: 0 --- !u!1 &418479318 GameObject: @@ -2114,7 +2155,7 @@ GameObject: - component: {fileID: 420712356} - component: {fileID: 420712355} m_Layer: 5 - m_Name: GeneratorImage + m_Name: MotorImage m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -3245,9 +3286,8 @@ Transform: m_LocalScale: {x: 1, y: 1, z: 1} m_Children: - {fileID: 429563992} - - {fileID: 289008715} m_Father: {fileID: 0} - m_RootOrder: 5 + m_RootOrder: 6 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &667342353 GameObject: @@ -3344,6 +3384,82 @@ MeshFilter: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 667342353} m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &674764864 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 674764865} + - component: {fileID: 674764867} + - component: {fileID: 674764866} + m_Layer: 5 + m_Name: CurrentEquationSystem + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &674764865 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 674764864} + 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: + - {fileID: 351782239} + m_Father: {fileID: 363737814} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 0, y: -32} + m_SizeDelta: {x: 300, y: 32} + m_Pivot: {x: 0, y: 1} +--- !u!114 &674764866 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 674764864} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0, g: 0, b: 0, a: 0.392} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &674764867 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 674764864} + m_CullTransparentMesh: 1 --- !u!1 &693913464 GameObject: m_ObjectHideFlags: 0 @@ -3723,7 +3839,7 @@ MonoBehaviour: m_faceColor: serializedVersion: 2 rgba: 4294967295 - m_fontSize: 70.5 + m_fontSize: 48.3 m_fontSizeBase: 36 m_fontWeight: 400 m_enableAutoSizing: 1 @@ -3910,7 +4026,7 @@ GameObject: - component: {fileID: 809097727} - component: {fileID: 809097730} - component: {fileID: 809097729} - - component: {fileID: 809097728} + - component: {fileID: 809097731} m_Layer: 5 m_Name: KBSimulationPanel m_TagString: Untagged @@ -3930,6 +4046,7 @@ RectTransform: m_LocalScale: {x: 1, y: 1, z: 1} m_Children: - {fileID: 1460017165} + - {fileID: 363737814} - {fileID: 1020458011} - {fileID: 2138628973} - {fileID: 1999216287} @@ -3938,10 +4055,10 @@ RectTransform: m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} - m_AnchoredPosition: {x: 0, y: 0} - m_SizeDelta: {x: -960, y: -532.25} + m_AnchoredPosition: {x: 0, y: -64} + m_SizeDelta: {x: -512, y: -384} m_Pivot: {x: 0.5, y: 0.5} ---- !u!114 &809097728 +--- !u!114 &809097729 MonoBehaviour: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} @@ -3950,25 +4067,7 @@ MonoBehaviour: m_GameObject: {fileID: 809097726} m_Enabled: 1 m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: cd5232732dfcc9349ba219bfc1f979e3, type: 3} - m_Name: - m_EditorClassIdentifier: - equationsContent: {fileID: 1826016068} - equationsPrefab: {fileID: 3362519755123188993, guid: 7eb90e8113b3eea4fb146a40931212d8, - type: 3} - rankAText: {fileID: 886607292} - solutionsText: {fileID: 764140785} - rankAbText: {fileID: 302437816} ---- !u!114 &809097729 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 809097726} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} m_Name: m_EditorClassIdentifier: m_Material: {fileID: 0} @@ -3997,6 +4096,26 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 809097726} m_CullTransparentMesh: 1 +--- !u!114 &809097731 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 809097726} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 7e0836ede8357f04d832bd34e417bc59, type: 3} + m_Name: + m_EditorClassIdentifier: + equationsContent: {fileID: 1826016068} + equationsPrefab: {fileID: 3362519755123188993, guid: 7eb90e8113b3eea4fb146a40931212d8, + type: 3} + rankAText: {fileID: 886607292} + solutionsText: {fileID: 764140785} + rankAbText: {fileID: 302437816} + NumberEquationSystemsText: {fileID: 1364306501} + CurrentEquationSystemText: {fileID: 1105805517} --- !u!1 &818921729 GameObject: m_ObjectHideFlags: 0 @@ -4355,7 +4474,7 @@ Transform: - {fileID: 31349802} - {fileID: 944887866} m_Father: {fileID: 0} - m_RootOrder: 3 + m_RootOrder: 4 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &848194813 GameObject: @@ -4580,7 +4699,7 @@ MonoBehaviour: m_faceColor: serializedVersion: 2 rgba: 4294967295 - m_fontSize: 72 + m_fontSize: 48.3 m_fontSizeBase: 36 m_fontWeight: 400 m_enableAutoSizing: 1 @@ -4823,7 +4942,7 @@ MeshFilter: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 903893025} m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} ---- !u!1 &927204669 +--- !u!1 &913394909 GameObject: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} @@ -4831,73 +4950,130 @@ GameObject: m_PrefabAsset: {fileID: 0} serializedVersion: 6 m_Component: - - component: {fileID: 927204670} - - component: {fileID: 927204672} - - component: {fileID: 927204671} + - component: {fileID: 913394910} + - component: {fileID: 913394913} + - component: {fileID: 913394912} + - component: {fileID: 913394911} m_Layer: 5 - m_Name: TextPanel + m_Name: NextEquationSystemButton m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 m_IsActive: 1 ---- !u!224 &927204670 +--- !u!224 &913394910 RectTransform: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 927204669} + m_GameObject: {fileID: 913394909} 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: - - {fileID: 1511094049} - m_Father: {fileID: 1666110546} - m_RootOrder: 0 + - {fileID: 380997638} + m_Father: {fileID: 363737814} + m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0.5, y: 0} - m_AnchorMax: {x: 0.5, y: 0} - m_AnchoredPosition: {x: 0, y: -15} - m_SizeDelta: {x: 128, y: 30} - m_Pivot: {x: 0.5, y: 0.5} ---- !u!114 &927204671 + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 320, y: 0} + m_SizeDelta: {x: 128, y: 64} + m_Pivot: {x: 0, y: 1} +--- !u!114 &913394911 MonoBehaviour: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 927204669} + m_GameObject: {fileID: 913394909} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 0.78431374} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.49056602, g: 0.49056602, b: 0.49056602, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Selected + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 913394912} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 809097731} + m_TargetAssemblyTypeName: EquationsDisplayPanel, Assembly-CSharp + m_MethodName: showNextEquationSystem + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &913394912 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 913394909} m_Enabled: 1 m_EditorHideFlags: 0 m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} m_Name: m_EditorClassIdentifier: m_Material: {fileID: 0} - m_Color: {r: 0.21960786, g: 0.21960786, b: 0.21960786, a: 0.392} + m_Color: {r: 1, g: 1, b: 1, a: 0.78431374} m_RaycastTarget: 1 m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: m_Calls: [] - m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} m_Type: 1 - m_PreserveAspect: 1 + m_PreserveAspect: 0 m_FillCenter: 1 m_FillMethod: 4 m_FillAmount: 1 m_FillClockwise: 1 - m_FillOrigin: 2 - m_UseSpriteMesh: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 m_PixelsPerUnitMultiplier: 1 ---- !u!222 &927204672 +--- !u!222 &913394913 CanvasRenderer: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 927204669} + m_GameObject: {fileID: 913394909} m_CullTransparentMesh: 0 --- !u!1001 &944887865 PrefabInstance: @@ -4991,7 +5167,7 @@ Transform: m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] m_Father: {fileID: 0} - m_RootOrder: 6 + m_RootOrder: 7 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &953526398 MonoBehaviour: @@ -5112,13 +5288,13 @@ RectTransform: m_Children: - {fileID: 1433731997} m_Father: {fileID: 809097727} - m_RootOrder: 1 + m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 1, y: 1} m_AnchorMax: {x: 1, y: 1} - m_AnchoredPosition: {x: -50, y: -50} - m_SizeDelta: {x: 100, y: 100} - m_Pivot: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 64, y: 64} + m_Pivot: {x: 1, y: 1} --- !u!114 &1020458012 MonoBehaviour: m_ObjectHideFlags: 0 @@ -5556,7 +5732,7 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1083582963} m_CullTransparentMesh: 1 ---- !u!1 &1148227744 +--- !u!1 &1105805517 GameObject: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} @@ -5564,158 +5740,132 @@ GameObject: m_PrefabAsset: {fileID: 0} serializedVersion: 6 m_Component: - - component: {fileID: 1148227745} - - component: {fileID: 1148227750} - - component: {fileID: 1148227749} - - component: {fileID: 1148227748} - - component: {fileID: 1148227747} - - component: {fileID: 1148227746} + - component: {fileID: 1105805518} + - component: {fileID: 1105805520} + - component: {fileID: 1105805519} m_Layer: 5 - m_Name: OpenImage + m_Name: CurrentEquationSystemText m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 m_IsActive: 1 ---- !u!224 &1148227745 +--- !u!224 &1105805518 RectTransform: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1148227744} + m_GameObject: {fileID: 1105805517} 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: - - {fileID: 121661300} - m_Father: {fileID: 1183769316} - m_RootOrder: 5 + m_Children: [] + m_Father: {fileID: 351782239} + m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 64, y: 80} - m_SizeDelta: {x: 128, y: 100} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} m_Pivot: {x: 0.5, y: 0.5} ---- !u!33 &1148227746 -MeshFilter: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1148227744} - m_Mesh: {fileID: 0} ---- !u!114 &1148227747 +--- !u!114 &1105805519 MonoBehaviour: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1148227744} + m_GameObject: {fileID: 1105805517} m_Enabled: 1 m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 2879753099386ed458cc84fada329d25, type: 3} - m_Name: - m_EditorClassIdentifier: - prefabCogwheel: {fileID: 652212249053607688, guid: a0a7a151db478af43acc112832da27d5, - type: 3} - prefabGenerator: {fileID: 272001209807832530, guid: 64f717dc282a6104eb2039998285217c, - type: 3} - prefabShaft: {fileID: 3325967553317399253, guid: f20a0401de365144a9041094a9498611, - type: 3} - prefabShaftHolder: {fileID: 458557811768577588, guid: 6d879228ef449024d91897c9784e5005, - type: 3} ---- !u!114 &1148227748 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1148227744} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} - m_Name: - m_EditorClassIdentifier: - m_Navigation: - m_Mode: 3 - m_WrapAround: 0 - m_SelectOnUp: {fileID: 0} - m_SelectOnDown: {fileID: 0} - m_SelectOnLeft: {fileID: 0} - m_SelectOnRight: {fileID: 0} - m_Transition: 1 - m_Colors: - m_NormalColor: {r: 1, g: 1, b: 1, a: 1} - m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} - m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} - m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} - m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} - m_ColorMultiplier: 1 - m_FadeDuration: 0.1 - m_SpriteState: - m_HighlightedSprite: {fileID: 0} - m_PressedSprite: {fileID: 0} - m_SelectedSprite: {fileID: 0} - m_DisabledSprite: {fileID: 0} - m_AnimationTriggers: - m_NormalTrigger: Normal - m_HighlightedTrigger: Highlighted - m_PressedTrigger: Pressed - m_SelectedTrigger: Selected - m_DisabledTrigger: Disabled - m_Interactable: 1 - m_TargetGraphic: {fileID: 1148227749} - m_OnClick: - m_PersistentCalls: - m_Calls: - - m_Target: {fileID: 1148227747} - m_TargetAssemblyTypeName: OpenJsonConfig, Assembly-CSharp - m_MethodName: openJsonConfig - m_Mode: 1 - m_Arguments: - m_ObjectArgument: {fileID: 0} - m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine - m_IntArgument: 0 - m_FloatArgument: 0 - m_StringArgument: - m_BoolArgument: 0 - m_CallState: 2 ---- !u!114 &1148227749 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1148227744} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 1344c3c82d62a2a41a3576d8abb8e3ea, type: 3} + m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3} m_Name: m_EditorClassIdentifier: m_Material: {fileID: 0} - m_Color: {r: 0.74509805, g: 0.74509805, b: 0.74509805, a: 1} + m_Color: {r: 1, g: 1, b: 1, a: 1} m_RaycastTarget: 1 m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: m_Calls: [] - m_Texture: {fileID: 2800000, guid: 6858630af33a95049aea740db5794cd3, type: 3} - m_UVRect: + m_text: 'current Equation System:' + m_isRightToLeft: 0 + m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_fontSharedMaterials: [] + m_fontMaterial: {fileID: 0} + m_fontMaterials: [] + m_fontColor32: serializedVersion: 2 - x: 0 - y: 0 - width: 1 - height: 1 ---- !u!222 &1148227750 + rgba: 4278190080 + m_fontColor: {r: 0, g: 0, b: 0, a: 1} + m_enableVertexGradient: 0 + m_colorMode: 3 + m_fontColorGradient: + topLeft: {r: 1, g: 1, b: 1, a: 1} + topRight: {r: 1, g: 1, b: 1, a: 1} + bottomLeft: {r: 1, g: 1, b: 1, a: 1} + bottomRight: {r: 1, g: 1, b: 1, a: 1} + m_fontColorGradientPreset: {fileID: 0} + m_spriteAsset: {fileID: 0} + m_tintAllSprites: 0 + m_StyleSheet: {fileID: 0} + m_TextStyleHashCode: -1183493901 + m_overrideHtmlColors: 0 + m_faceColor: + serializedVersion: 2 + rgba: 4294967295 + m_fontSize: 19.65 + m_fontSizeBase: 36 + m_fontWeight: 400 + m_enableAutoSizing: 1 + m_fontSizeMin: 5 + m_fontSizeMax: 72 + m_fontStyle: 0 + m_HorizontalAlignment: 2 + m_VerticalAlignment: 512 + m_textAlignment: 65535 + m_characterSpacing: 0 + m_wordSpacing: 0 + m_lineSpacing: 0 + m_lineSpacingMax: 0 + m_paragraphSpacing: 0 + m_charWidthMaxAdj: 0 + m_enableWordWrapping: 1 + m_wordWrappingRatios: 0.4 + m_overflowMode: 0 + m_linkedTextComponent: {fileID: 0} + parentLinkedComponent: {fileID: 0} + m_enableKerning: 1 + m_enableExtraPadding: 0 + checkPaddingRequired: 0 + m_isRichText: 1 + m_parseCtrlCharacters: 1 + m_isOrthographic: 1 + m_isCullingEnabled: 0 + m_horizontalMapping: 0 + m_verticalMapping: 0 + m_uvLineOffset: 0 + m_geometrySortingOrder: 0 + m_IsTextObjectScaleStatic: 0 + m_VertexBufferAutoSizeReduction: 1 + m_useMaxVisibleDescender: 1 + m_pageToDisplay: 1 + m_margin: {x: 0, y: 0, z: 0, w: 0} + m_isUsingLegacyAnimationComponent: 0 + m_isVolumetricText: 0 + m_hasFontAssetChanged: 0 + m_baseMaterial: {fileID: 0} + m_maskOffset: {x: 0, y: 0, z: 0, w: 0} +--- !u!222 &1105805520 CanvasRenderer: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1148227744} - m_CullTransparentMesh: 0 + m_GameObject: {fileID: 1105805517} + m_CullTransparentMesh: 1 --- !u!1 &1183769315 GameObject: m_ObjectHideFlags: 0 @@ -5750,8 +5900,6 @@ RectTransform: - {fileID: 420712354} - {fileID: 703511599} - {fileID: 79453076} - - {fileID: 1148227745} - - {fileID: 1666110546} - {fileID: 1646860088} m_Father: {fileID: 429563992} m_RootOrder: 0 @@ -6176,6 +6324,140 @@ Light: m_UseViewFrustumForShadowCasterCull: 1 m_ShadowRadius: 0 m_ShadowAngle: 0 +--- !u!1 &1364306501 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1364306502} + - component: {fileID: 1364306504} + - component: {fileID: 1364306503} + m_Layer: 5 + m_Name: NumberEquationSystemsText + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1364306502 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1364306501} + 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: 2080700865} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1364306503 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1364306501} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_text: 'Number of Equation Systems:' + m_isRightToLeft: 0 + m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_fontSharedMaterials: [] + m_fontMaterial: {fileID: 0} + m_fontMaterials: [] + m_fontColor32: + serializedVersion: 2 + rgba: 4278190080 + m_fontColor: {r: 0, g: 0, b: 0, a: 1} + m_enableVertexGradient: 0 + m_colorMode: 3 + m_fontColorGradient: + topLeft: {r: 1, g: 1, b: 1, a: 1} + topRight: {r: 1, g: 1, b: 1, a: 1} + bottomLeft: {r: 1, g: 1, b: 1, a: 1} + bottomRight: {r: 1, g: 1, b: 1, a: 1} + m_fontColorGradientPreset: {fileID: 0} + m_spriteAsset: {fileID: 0} + m_tintAllSprites: 0 + m_StyleSheet: {fileID: 0} + m_TextStyleHashCode: -1183493901 + m_overrideHtmlColors: 0 + m_faceColor: + serializedVersion: 2 + rgba: 4294967295 + m_fontSize: 19.65 + m_fontSizeBase: 36 + m_fontWeight: 400 + m_enableAutoSizing: 1 + m_fontSizeMin: 5 + m_fontSizeMax: 72 + m_fontStyle: 0 + m_HorizontalAlignment: 2 + m_VerticalAlignment: 512 + m_textAlignment: 65535 + m_characterSpacing: 0 + m_wordSpacing: 0 + m_lineSpacing: 0 + m_lineSpacingMax: 0 + m_paragraphSpacing: 0 + m_charWidthMaxAdj: 0 + m_enableWordWrapping: 1 + m_wordWrappingRatios: 0.4 + m_overflowMode: 0 + m_linkedTextComponent: {fileID: 0} + parentLinkedComponent: {fileID: 0} + m_enableKerning: 1 + m_enableExtraPadding: 0 + checkPaddingRequired: 0 + m_isRichText: 1 + m_parseCtrlCharacters: 1 + m_isOrthographic: 1 + m_isCullingEnabled: 0 + m_horizontalMapping: 0 + m_verticalMapping: 0 + m_uvLineOffset: 0 + m_geometrySortingOrder: 0 + m_IsTextObjectScaleStatic: 0 + m_VertexBufferAutoSizeReduction: 1 + m_useMaxVisibleDescender: 1 + m_pageToDisplay: 1 + m_margin: {x: 0, y: 0, z: 0, w: 0} + m_isUsingLegacyAnimationComponent: 0 + m_isVolumetricText: 0 + m_hasFontAssetChanged: 0 + m_baseMaterial: {fileID: 0} + m_maskOffset: {x: 0, y: 0, z: 0, w: 0} +--- !u!222 &1364306504 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1364306501} + m_CullTransparentMesh: 1 --- !u!1 &1392798706 GameObject: m_ObjectHideFlags: 0 @@ -6269,8 +6551,141 @@ MeshFilter: m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1392798706} - m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} + m_GameObject: {fileID: 1392798706} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &1398016556 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1398016557} + - component: {fileID: 1398016560} + - component: {fileID: 1398016559} + - component: {fileID: 1398016558} + m_Layer: 5 + m_Name: PreviousEquationSystemButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1398016557 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1398016556} + 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: + - {fileID: 1692849810} + m_Father: {fileID: 363737814} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 450, y: 0} + m_SizeDelta: {x: 128, y: 64} + m_Pivot: {x: 0, y: 1} +--- !u!114 &1398016558 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1398016556} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 0.78431374} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.49056602, g: 0.49056602, b: 0.49056602, a: 1} + m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Selected + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 1398016559} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 809097731} + m_TargetAssemblyTypeName: EquationsDisplayPanel, Assembly-CSharp + m_MethodName: showPreviousEquationSystem + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &1398016559 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1398016556} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.78431374} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1398016560 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1398016556} + m_CullTransparentMesh: 0 --- !u!1 &1422111505 GameObject: m_ObjectHideFlags: 0 @@ -6304,11 +6719,11 @@ RectTransform: m_Father: {fileID: 1999216287} m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 1, y: 0} - m_AnchorMax: {x: 1, y: 0} - m_AnchoredPosition: {x: -160, y: 50} - m_SizeDelta: {x: 320, y: 100} - m_Pivot: {x: 0.5, y: 0.5} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 512, y: 0} + m_SizeDelta: {x: 256, y: 64} + m_Pivot: {x: 0, y: 0} --- !u!114 &1422111507 MonoBehaviour: m_ObjectHideFlags: 0 @@ -6431,7 +6846,7 @@ MonoBehaviour: m_faceColor: serializedVersion: 2 rgba: 4294967295 - m_fontSize: 72 + m_fontSize: 57.25 m_fontSizeBase: 36 m_fontWeight: 400 m_enableAutoSizing: 1 @@ -6592,9 +7007,9 @@ RectTransform: m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1} - m_AnchoredPosition: {x: 430, y: -50} - m_SizeDelta: {x: 860, y: 100} - m_Pivot: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 512, y: 64} + m_Pivot: {x: 0, y: 1} --- !u!114 &1460017166 MonoBehaviour: m_ObjectHideFlags: 0 @@ -6642,8 +7057,8 @@ MonoBehaviour: m_faceColor: serializedVersion: 2 rgba: 4294967295 - m_fontSize: 63.1 - m_fontSizeBase: 36 + m_fontSize: 36.3 + m_fontSizeBase: 48 m_fontWeight: 400 m_enableAutoSizing: 1 m_fontSizeMin: 18 @@ -6741,9 +7156,9 @@ RectTransform: m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 0} - m_AnchoredPosition: {x: 160, y: 50} - m_SizeDelta: {x: 320, y: 100} - m_Pivot: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 256, y: 64} + m_Pivot: {x: 0, y: 0} --- !u!114 &1484724398 MonoBehaviour: m_ObjectHideFlags: 0 @@ -6998,140 +7413,6 @@ MonoBehaviour: debug: 0 debugMaterial: {fileID: 0} lineRenderer: {fileID: 0} ---- !u!1 &1511094048 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 1511094049} - - component: {fileID: 1511094051} - - component: {fileID: 1511094050} - m_Layer: 5 - m_Name: Text - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!224 &1511094049 -RectTransform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1511094048} - 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: 927204670} - m_RootOrder: 0 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0.5, y: 0.5} - m_AnchorMax: {x: 0.5, y: 0.5} - m_AnchoredPosition: {x: 0, y: 0} - m_SizeDelta: {x: 128, y: 30} - m_Pivot: {x: 0.5, y: 0.5} ---- !u!114 &1511094050 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1511094048} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3} - m_Name: - m_EditorClassIdentifier: - m_Material: {fileID: 0} - m_Color: {r: 1, g: 1, b: 1, a: 1} - m_RaycastTarget: 1 - m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} - m_Maskable: 1 - m_OnCullStateChanged: - m_PersistentCalls: - m_Calls: [] - m_text: Save Scene - m_isRightToLeft: 0 - m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} - m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} - m_fontSharedMaterials: [] - m_fontMaterial: {fileID: 0} - m_fontMaterials: [] - m_fontColor32: - serializedVersion: 2 - rgba: 4294967295 - m_fontColor: {r: 1, g: 1, b: 1, a: 1} - m_enableVertexGradient: 0 - m_colorMode: 3 - m_fontColorGradient: - topLeft: {r: 1, g: 1, b: 1, a: 1} - topRight: {r: 1, g: 1, b: 1, a: 1} - bottomLeft: {r: 1, g: 1, b: 1, a: 1} - bottomRight: {r: 1, g: 1, b: 1, a: 1} - m_fontColorGradientPreset: {fileID: 0} - m_spriteAsset: {fileID: 0} - m_tintAllSprites: 0 - m_StyleSheet: {fileID: 0} - m_TextStyleHashCode: -1183493901 - m_overrideHtmlColors: 0 - m_faceColor: - serializedVersion: 2 - rgba: 4294967295 - m_fontSize: 16 - m_fontSizeBase: 16 - m_fontWeight: 400 - m_enableAutoSizing: 0 - m_fontSizeMin: 18 - m_fontSizeMax: 72 - m_fontStyle: 0 - m_HorizontalAlignment: 2 - m_VerticalAlignment: 512 - m_textAlignment: 65535 - m_characterSpacing: 0 - m_wordSpacing: 0 - m_lineSpacing: 0 - m_lineSpacingMax: 0 - m_paragraphSpacing: 0 - m_charWidthMaxAdj: 0 - m_enableWordWrapping: 1 - m_wordWrappingRatios: 0.4 - m_overflowMode: 0 - m_linkedTextComponent: {fileID: 0} - parentLinkedComponent: {fileID: 0} - m_enableKerning: 1 - m_enableExtraPadding: 0 - checkPaddingRequired: 0 - m_isRichText: 1 - m_parseCtrlCharacters: 1 - m_isOrthographic: 1 - m_isCullingEnabled: 0 - m_horizontalMapping: 0 - m_verticalMapping: 0 - m_uvLineOffset: 0 - m_geometrySortingOrder: 0 - m_IsTextObjectScaleStatic: 0 - m_VertexBufferAutoSizeReduction: 1 - m_useMaxVisibleDescender: 1 - m_pageToDisplay: 1 - m_margin: {x: 0, y: 0, z: 0, w: 0} - m_isUsingLegacyAnimationComponent: 0 - m_isVolumetricText: 0 - m_hasFontAssetChanged: 0 - m_baseMaterial: {fileID: 0} - m_maskOffset: {x: 0, y: 0, z: 0, w: 0} ---- !u!222 &1511094051 -CanvasRenderer: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1511094048} - m_CullTransparentMesh: 0 --- !u!1 &1534278503 GameObject: m_ObjectHideFlags: 0 @@ -7772,7 +8053,7 @@ RectTransform: m_Children: - {fileID: 144699795} m_Father: {fileID: 1183769316} - m_RootOrder: 7 + m_RootOrder: 5 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1} @@ -8039,173 +8320,149 @@ Transform: MonoBehaviour: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1651565275} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: b8edcb818369855428183c2afa2b19aa, type: 3} - m_Name: - m_EditorClassIdentifier: ---- !u!1 &1666110545 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 1666110546} - - component: {fileID: 1666110551} - - component: {fileID: 1666110550} - - component: {fileID: 1666110549} - - component: {fileID: 1666110548} - - component: {fileID: 1666110547} - m_Layer: 5 - m_Name: SaveImage - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!224 &1666110546 -RectTransform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1666110545} - 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: - - {fileID: 927204670} - m_Father: {fileID: 1183769316} - m_RootOrder: 6 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 1, y: 0} - m_AnchorMax: {x: 1, y: 0} - m_AnchoredPosition: {x: -64, y: 80} - m_SizeDelta: {x: 128, y: 100} - m_Pivot: {x: 0.5, y: 0.5} ---- !u!33 &1666110547 -MeshFilter: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1666110545} - m_Mesh: {fileID: 0} ---- !u!114 &1666110548 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1666110545} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 2879753099386ed458cc84fada329d25, type: 3} - m_Name: - m_EditorClassIdentifier: - prefabCogwheel: {fileID: 652212249053607688, guid: a0a7a151db478af43acc112832da27d5, - type: 3} - prefabGenerator: {fileID: 272001209807832530, guid: 64f717dc282a6104eb2039998285217c, - type: 3} - prefabShaft: {fileID: 3325967553317399253, guid: f20a0401de365144a9041094a9498611, - type: 3} - prefabShaftHolder: {fileID: 458557811768577588, guid: 6d879228ef449024d91897c9784e5005, - type: 3} ---- !u!114 &1666110549 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1666110545} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} - m_Name: - m_EditorClassIdentifier: - m_Navigation: - m_Mode: 3 - m_WrapAround: 0 - m_SelectOnUp: {fileID: 0} - m_SelectOnDown: {fileID: 0} - m_SelectOnLeft: {fileID: 0} - m_SelectOnRight: {fileID: 0} - m_Transition: 1 - m_Colors: - m_NormalColor: {r: 1, g: 1, b: 1, a: 1} - m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} - m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} - m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} - m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} - m_ColorMultiplier: 1 - m_FadeDuration: 0.1 - m_SpriteState: - m_HighlightedSprite: {fileID: 0} - m_PressedSprite: {fileID: 0} - m_SelectedSprite: {fileID: 0} - m_DisabledSprite: {fileID: 0} - m_AnimationTriggers: - m_NormalTrigger: Normal - m_HighlightedTrigger: Highlighted - m_PressedTrigger: Pressed - m_SelectedTrigger: Selected - m_DisabledTrigger: Disabled - m_Interactable: 1 - m_TargetGraphic: {fileID: 1666110550} - m_OnClick: - m_PersistentCalls: - m_Calls: - - m_Target: {fileID: 1666110548} - m_TargetAssemblyTypeName: JsonConfigInteraction, Assembly-CSharp - m_MethodName: saveJsonConfig - m_Mode: 1 - m_Arguments: - m_ObjectArgument: {fileID: 0} - m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine - m_IntArgument: 0 - m_FloatArgument: 0 - m_StringArgument: - m_BoolArgument: 0 - m_CallState: 2 ---- !u!114 &1666110550 + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1651565275} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: b8edcb818369855428183c2afa2b19aa, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!1 &1692849809 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1692849810} + - component: {fileID: 1692849812} + - component: {fileID: 1692849811} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1692849810 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1692849809} + 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: 1398016557} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1692849811 MonoBehaviour: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1666110545} + m_GameObject: {fileID: 1692849809} m_Enabled: 1 m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 1344c3c82d62a2a41a3576d8abb8e3ea, type: 3} + m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3} m_Name: m_EditorClassIdentifier: m_Material: {fileID: 0} - m_Color: {r: 0.8784314, g: 0.8784314, b: 0.8784314, a: 1} + m_Color: {r: 1, g: 1, b: 1, a: 1} m_RaycastTarget: 1 m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: m_Calls: [] - m_Texture: {fileID: 2800000, guid: 7e286d1e519c9ec4881430685e5c4a02, type: 3} - m_UVRect: + m_text: 'Previous + + Eqsys' + m_isRightToLeft: 0 + m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} + m_fontSharedMaterials: [] + m_fontMaterial: {fileID: 0} + m_fontMaterials: [] + m_fontColor32: serializedVersion: 2 - x: 0 - y: 0 - width: 1 - height: 1 ---- !u!222 &1666110551 + rgba: 4278190080 + m_fontColor: {r: 0, g: 0, b: 0, a: 1} + m_enableVertexGradient: 0 + m_colorMode: 3 + m_fontColorGradient: + topLeft: {r: 1, g: 1, b: 1, a: 1} + topRight: {r: 1, g: 1, b: 1, a: 1} + bottomLeft: {r: 1, g: 1, b: 1, a: 1} + bottomRight: {r: 1, g: 1, b: 1, a: 1} + m_fontColorGradientPreset: {fileID: 0} + m_spriteAsset: {fileID: 0} + m_tintAllSprites: 0 + m_StyleSheet: {fileID: 0} + m_TextStyleHashCode: -1183493901 + m_overrideHtmlColors: 0 + m_faceColor: + serializedVersion: 2 + rgba: 4294967295 + m_fontSize: 28.2 + m_fontSizeBase: 36 + m_fontWeight: 400 + m_enableAutoSizing: 1 + m_fontSizeMin: 18 + m_fontSizeMax: 72 + m_fontStyle: 0 + m_HorizontalAlignment: 2 + m_VerticalAlignment: 512 + m_textAlignment: 65535 + m_characterSpacing: 0 + m_wordSpacing: 0 + m_lineSpacing: 0 + m_lineSpacingMax: 0 + m_paragraphSpacing: 0 + m_charWidthMaxAdj: 0 + m_enableWordWrapping: 1 + m_wordWrappingRatios: 0.4 + m_overflowMode: 0 + m_linkedTextComponent: {fileID: 0} + parentLinkedComponent: {fileID: 0} + m_enableKerning: 1 + m_enableExtraPadding: 0 + checkPaddingRequired: 0 + m_isRichText: 1 + m_parseCtrlCharacters: 1 + m_isOrthographic: 1 + m_isCullingEnabled: 0 + m_horizontalMapping: 0 + m_verticalMapping: 0 + m_uvLineOffset: 0 + m_geometrySortingOrder: 0 + m_IsTextObjectScaleStatic: 0 + m_VertexBufferAutoSizeReduction: 1 + m_useMaxVisibleDescender: 1 + m_pageToDisplay: 1 + m_margin: {x: 0, y: 0, z: 0, w: 0} + m_isUsingLegacyAnimationComponent: 0 + m_isVolumetricText: 0 + m_hasFontAssetChanged: 0 + m_baseMaterial: {fileID: 0} + m_maskOffset: {x: 0, y: 0, z: 0, w: 0} +--- !u!222 &1692849812 CanvasRenderer: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1666110545} + m_GameObject: {fileID: 1692849809} m_CullTransparentMesh: 0 --- !u!1001 &1729097011 PrefabInstance: @@ -8270,6 +8527,82 @@ Transform: type: 3} m_PrefabInstance: {fileID: 1729097011} m_PrefabAsset: {fileID: 0} +--- !u!1 &1767776368 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1767776369} + - component: {fileID: 1767776371} + - component: {fileID: 1767776370} + m_Layer: 5 + m_Name: NumerEquationSystems + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1767776369 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1767776368} + 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: + - {fileID: 2080700865} + m_Father: {fileID: 363737814} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 300, y: 32} + m_Pivot: {x: 0, y: 1} +--- !u!114 &1767776370 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1767776368} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0, g: 0, b: 0, a: 0.392} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1767776371 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1767776368} + m_CullTransparentMesh: 1 --- !u!1 &1770898662 GameObject: m_ObjectHideFlags: 0 @@ -8531,7 +8864,7 @@ Transform: - {fileID: 837822087} - {fileID: 14063130} m_Father: {fileID: 0} - m_RootOrder: 2 + m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1826016068 GameObject: @@ -8567,7 +8900,7 @@ RectTransform: m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 1} m_AnchorMax: {x: 1, y: 1} - m_AnchoredPosition: {x: 0, y: 0.00004666443} + m_AnchoredPosition: {x: 0, y: 0} m_SizeDelta: {x: 0, y: 0} m_Pivot: {x: 0, y: 1} --- !u!114 &1826016070 @@ -8882,7 +9215,7 @@ Transform: m_LocalScale: {x: 1, y: 1, z: 1} m_Children: [] m_Father: {fileID: 0} - m_RootOrder: 4 + m_RootOrder: 5 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1001 &1855492789 PrefabInstance: @@ -8992,11 +9325,11 @@ RectTransform: m_Father: {fileID: 1999216287} m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} - m_AnchorMin: {x: 0.5, y: 0} - m_AnchorMax: {x: 0.5, y: 0} - m_AnchoredPosition: {x: 0, y: 50} - m_SizeDelta: {x: 320, y: 100} - m_Pivot: {x: 0.5, y: 0.5} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 256, y: 0} + m_SizeDelta: {x: 256, y: 64} + m_Pivot: {x: 0, y: 0} --- !u!114 &1858116677 MonoBehaviour: m_ObjectHideFlags: 0 @@ -9577,10 +9910,10 @@ RectTransform: - {fileID: 1858116676} - {fileID: 1422111506} m_Father: {fileID: 809097727} - m_RootOrder: 3 + m_RootOrder: 4 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} - m_AnchorMax: {x: 1, y: 1} + m_AnchorMax: {x: 1, y: 0.2} m_AnchoredPosition: {x: 0, y: 0} m_SizeDelta: {x: 0, y: 0} m_Pivot: {x: 0.5, y: 0.5} @@ -9618,7 +9951,7 @@ Transform: - {fileID: 91820188} - {fileID: 667342354} m_Father: {fileID: 0} - m_RootOrder: 0 + m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &2040131914 GameObject: @@ -9771,7 +10104,7 @@ MonoBehaviour: m_OnCullStateChanged: m_PersistentCalls: m_Calls: [] - m_text: Generator + m_text: Motor m_isRightToLeft: 0 m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} @@ -9943,6 +10276,82 @@ MeshFilter: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 2066595094} m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!1 &2080700864 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2080700865} + - component: {fileID: 2080700867} + - component: {fileID: 2080700866} + m_Layer: 5 + m_Name: InnerPanel + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &2080700865 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2080700864} + 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: + - {fileID: 1364306502} + m_Father: {fileID: 1767776369} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 1, y: 1} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: -10, y: -10} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &2080700866 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2080700864} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0.392} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &2080700867 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2080700864} + m_CullTransparentMesh: 1 --- !u!1 &2080856282 GameObject: m_ObjectHideFlags: 0 @@ -10031,7 +10440,7 @@ GameObject: - component: {fileID: 2106744674} - component: {fileID: 2106744673} m_Layer: 5 - m_Name: SimulatonControlsPanel + m_Name: SimulationControlsPanel m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -10160,12 +10569,12 @@ RectTransform: - {fileID: 1650448564} - {fileID: 1053507111} m_Father: {fileID: 809097727} - m_RootOrder: 2 + m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0.5} m_AnchorMax: {x: 1, y: 0.5} m_AnchoredPosition: {x: 0, y: 0} - m_SizeDelta: {x: 0, y: 332.25} + m_SizeDelta: {x: 0, y: 375} m_Pivot: {x: 0.5, y: 0.5} --- !u!114 &2138628974 MonoBehaviour: diff --git a/Assets/Scripts/Communication/Knowledge/Fact.cs b/Assets/Scripts/Communication/Knowledge/Fact.cs index 78529b9..b4689ec 100644 --- a/Assets/Scripts/Communication/Knowledge/Fact.cs +++ b/Assets/Scripts/Communication/Knowledge/Fact.cs @@ -451,7 +451,7 @@ public override bool Equals(System.Object obj) } else { - CogwheelEqsysFact p = (CogwheelEqsysFact)obj; + CogChainEqsysFact p = (CogChainEqsysFact)obj; return this.CogwheelIds.Equals(p.CogwheelIds); } } diff --git a/Assets/Scripts/Gadgets/ChainPlacementToolOld.cs b/Assets/Scripts/Gadgets/ChainPlacementToolOld.cs index ce4d35f..5581b42 100644 --- a/Assets/Scripts/Gadgets/ChainPlacementToolOld.cs +++ b/Assets/Scripts/Gadgets/ChainPlacementToolOld.cs @@ -270,7 +270,7 @@ void CheckMouseButtons() // ChainFact newFact = new ChainFact(chnId, cogIds, orientatins, GameState.Facts); ChainFact newFact = null; - newFact.Representation = newChain; + //newFact.Representation = newChain; GameState.Facts.Insert(chnId, newFact); UnityEngine.Debug.Log("Successfully added new ChainFact with backendUri: " + newFact.backendURI); @@ -308,7 +308,7 @@ void CheckMouseButtons() //ChainFact newFact = new ChainFact(chnId, cogIds, orientatins, GameState.Facts); ChainFact newFact = null; - newFact.Representation = newChain; + //newFact.Representation = newChain; GameState.Facts.Insert(chnId, newFact); UnityEngine.Debug.Log("Successfully added new ChainFact with backendUri: " + newFact.backendURI); diff --git a/Assets/Scripts/General/CommunicationEvents.cs b/Assets/Scripts/General/CommunicationEvents.cs index a1fd1a6..045a5bf 100644 --- a/Assets/Scripts/General/CommunicationEvents.cs +++ b/Assets/Scripts/General/CommunicationEvents.cs @@ -12,7 +12,8 @@ public class AnimationEvent : UnityEvent{} public class SimulationEvent : UnityEvent {} public class EquationSystemEvent : UnityEvent {} - + public class EquationSystemsEvent : UnityEvent, List, List, List> {} + public static SignalEvent closeUIEvent = new SignalEvent(); public static SignalEvent openUIEvent = new SignalEvent(); public static SignalEvent openPanelEvent = new SignalEvent(); @@ -25,4 +26,5 @@ public class EquationSystemEvent : UnityEvent {} public static SignalEvent generatorOffEvent = new SignalEvent(); public static EquationSystemEvent showEquationSystemEvent = new EquationSystemEvent(); + public static EquationSystemsEvent showEquationSystemsEvent = new EquationSystemsEvent(); } diff --git a/Assets/Scripts/General/GameState.cs b/Assets/Scripts/General/GameState.cs index b253bab..c84bce1 100644 --- a/Assets/Scripts/General/GameState.cs +++ b/Assets/Scripts/General/GameState.cs @@ -1,6 +1,10 @@ using System; using System.Collections.Generic; + +/** + * + */ public static class GameState { public static bool ServerRunning = false; diff --git a/Assets/Scripts/Refactor/Simulation/Interaction.cs b/Assets/Scripts/Refactor/Simulation/Interaction.cs index f41f979..2e8ad82 100644 --- a/Assets/Scripts/Refactor/Simulation/Interaction.cs +++ b/Assets/Scripts/Refactor/Simulation/Interaction.cs @@ -2,6 +2,11 @@ using System.Collections.Generic; using UnityEngine; +/** + * class that represents Interactions between simulated objects + * interactions have their own id + * interactions have a associated Fact representing them on the MMT side + */ public class Interaction { protected int id; diff --git a/Assets/Scripts/Refactor/Simulation/KnowlegeBasedSimulationRefactor.cs b/Assets/Scripts/Refactor/Simulation/KnowlegeBasedSimulationRefactor.cs index bbcd64b..c4f83fb 100644 --- a/Assets/Scripts/Refactor/Simulation/KnowlegeBasedSimulationRefactor.cs +++ b/Assets/Scripts/Refactor/Simulation/KnowlegeBasedSimulationRefactor.cs @@ -1,27 +1,40 @@ using System; +using System.Collections; using System.Collections.Generic; using System.Linq; using UnityEngine; using UnityEngine.Networking; using MathNet.Numerics.LinearAlgebra; +using MathNet.Numerics.LinearAlgebra.Factorization; using static JSONManager; + +/** + * provides functionality for extracting and solving the equationsystem returned by the server + */ public class KnowlegeBasedSimulationRefactor : MonoBehaviour { - public static Dictionary knowledgeBasedSimulation(List facts, List valuesOfIntrest, List sFactList) + /** + * takes a list of simplified facts and a list of the current Values of interest + * trys solving the equationsystem + * if successfull returns a Dictionary mapping the values of interest to the calculated valuse from the equation system + */ + public static Dictionary knowledgeBasedSimulation(List valuesOfIntrest, List sFactList) { - + if (sFactList == null) - { + { return null; } else { + //extract all simplifiedEquationSystemFacts out of the list of all simplified facts List sEqsysFacts = sFactList.FindAll(sFact => sFact.GetType().Equals(typeof(SEqsysFact))) .Select(sFact => (SEqsysFact)sFact) .ToList(); SEqsysFact eqsysFactForSimulation = null; - + //extract the most recent simplifiedEquationSystemFact from the list of all simplifiedEquationSystemFacts + //to be used for subsequent calculations if (sEqsysFacts.Count == 0) { Debug.Log("KnowledgeBasedSimulation: sFactList contains no SEqsysFact."); @@ -41,6 +54,11 @@ public class KnowlegeBasedSimulationRefactor : MonoBehaviour Debug.Log("eqsysFactForSimulation: " + eqsysFactForSimulation); + //parse the equation system in the simplified equation-system fact into a form + //that can be solved by the MathNet.Numerics.LinearAlgebra library + //(list of lists of doubles for representing Matrix A + // list of doubles for representing the vecto b + // list of MMTTerms for representing the variable for which are to be solved) Tuple>, List, List> glsTuple = eqsysFactForSimulation.parseEquationSystem(); if (glsTuple == null) @@ -54,69 +72,84 @@ public class KnowlegeBasedSimulationRefactor : MonoBehaviour List bData = glsTuple.Item2; List variables = glsTuple.Item3; - int numberOfVariables = AData[0].Count; - Matrix A = Matrix.Build.DenseOfRows(AData); Vector b = Vector.Build.DenseOfEnumerable(bData); - string[] equations = equationsToString(AData, bData, variables, valuesOfIntrest); + //parse the equations encoded in the glsTuple into a human readable form + string[] equations = equationsToString(A, b, variables, valuesOfIntrest); /****DETERMINE HOW MANY SOLUTIONS THE LINEAR-EQUATION-SYSTEM HAS AND REACT CORRESPONDINGLY****/ int rankA = A.Rank(); - if (AData.Count == bData.Count) + if (AData.Count != bData.Count) { - for (int i = 0; i < AData.Count; i++) - { - AData[i].Add(bData[i]); - } + Debug.Log("Row-Count of Matrix A and Vector b were not equal!"); + return null; + } - Matrix AExtended = Matrix.Build.DenseOfRows(AData); - int rankAExtended = AExtended.Rank(); - string solutions = ""; + Tuple>, List>, List>> independentMatrices = seperateIndependentEqsysComponents(A, b, variables); + List ARanks = new List(); + List AExtendedRanks = new List(); + List equationsList = new List(); + List numbersOfSolutions = new List(); - //TODO: SHOW EQUATION-SYSTEM / RANKS ETC. / MAYBE WITH USING COMMUNICATIONEVENTS + Dictionary discoveredVoiVals = new Dictionary(); - if (rankA != rankAExtended) + for (int i = 0; i < independentMatrices.Item1.Count; i++) + { + int ARank = independentMatrices.Item1[i].Rank(); + ARanks.Add(ARank); + int AExtendedRank = independentMatrices.Item1[i].InsertColumn(independentMatrices.Item1[i].ColumnCount, independentMatrices.Item2[i]).Rank(); + AExtendedRanks.Add(AExtendedRank); + int numberOfVariables = independentMatrices.Item3[i].Count; + + + if (ARank != AExtendedRank) { - solutions = "0"; - Debug.Log(String.Format("The linear EquationSystem has NO solution. Reason: rank of A and rank of AExtended are not equal. RankA = {0}, RankAExtended = {1}", rankA, rankAExtended)); - CommunicationEvents.showEquationSystemEvent.Invoke(equations, rankA, rankAExtended, solutions); - return null; + numbersOfSolutions.Add("0"); + equationsList.Add(new string[0]); + + Debug.Log(String.Format("The linear EquationSystem has NO solution. Reason: rank of A and rank of AExtended are not equal. RankA = {0}, RankAExtended = {1}", ARank, AExtendedRank)); + + continue; } - else if (rankA < numberOfVariables) + + string[] eqs = equationsToString(independentMatrices.Item1[i], independentMatrices.Item2[i], independentMatrices.Item3[i], valuesOfIntrest); + + + if (ARank < numberOfVariables) { - solutions = "∞"; + numbersOfSolutions.Add("∞"); + equationsList.Add(eqs); + Debug.Log(String.Format("The linear EquationSystem has an infinite number of solutions. Reason: rank of A = rank of AExtended = {0} < varNum = {1}", rankA, numberOfVariables)); - CommunicationEvents.showEquationSystemEvent.Invoke(equations, rankA, rankAExtended, solutions); - return null; + continue; } - else if (rankA == numberOfVariables) + else if (ARank == numberOfVariables) { - solutions = "1"; - Debug.Log(String.Format("The linear EquationSystem has exactly one solution. Reason: rank of A = rank of AExtended = {0} = varNum = {1}", rankA, numberOfVariables)); + numbersOfSolutions.Add("1"); + equationsList.Add(eqs); - CommunicationEvents.showEquationSystemEvent.Invoke(equations, rankA, rankAExtended, solutions); - - //Solve GLS of the form 'A * x = b': - Vector glsSolution = A.Solve(b); + Debug.Log(String.Format("The linear EquationSystem has exactly one solution. Reason: rank of A = rank of AExtended = {0} = varNum = {1}", rankA, numberOfVariables)); + Vector glsSolution = independentMatrices.Item1[i].Solve(independentMatrices.Item2[i]); + getNewlyDiscoveredAvsMap(discoveredVoiVals, independentMatrices.Item3[i], glsSolution, valuesOfIntrest); - //Map the glsSolution to the variables and to the corresponding cogwheels - return getNewlyDiscoveredAvsMap(variables, glsSolution, valuesOfIntrest); + continue; } else { - solutions = "?"; + numbersOfSolutions.Add("?"); + equationsList.Add(new string[0]); + Debug.Log(String.Format("Rank of A = rank of AExtended = {0} > varNum = {1}", rankA, numberOfVariables)); - CommunicationEvents.showEquationSystemEvent.Invoke(equations, rankA, rankAExtended, solutions); - return null; - } - } - else - { - Debug.Log("Row-Count of Matrix A and Vector b were not equal!"); - return null; + + continue; + } } + Debug.Log("test"); + CommunicationEvents.showEquationSystemsEvent.Invoke(equationsList, ARanks, AExtendedRanks, numbersOfSolutions); + + return discoveredVoiVals; } } else @@ -126,6 +159,7 @@ public class KnowlegeBasedSimulationRefactor : MonoBehaviour } } + /* private static List listSimplifiedFacts() { UnityWebRequest request = UnityWebRequest.Get(GameSettings.ServerAdress + "/fact/list"); @@ -144,13 +178,22 @@ private static List listSimplifiedFacts() return SimplifiedFact.FromJSON(response); } } + */ - private static Dictionary getNewlyDiscoveredAvsMap(List variables, Vector glsSolution, List valuesOfIntrest) - { - Dictionary discoveredAvsMap = new Dictionary(); - //Find KeyValuePairs ... - if (glsSolution.Count.Equals(variables.Count)) + //function that maps the values in the solution of our equation-system to the corresponding values of interest + //takes the variables of the eqaution-system, the solution of the eqaution system and a List of all relevant values of interest as input + private static void getNewlyDiscoveredAvsMap(Dictionary discoveredVoiVals, List variables, Vector glsSolution, List valuesOfIntrest) + { + //dictionary that will map the values of interest to the corresponding values in the solution of our eqaution system + //Dictionary discoveredVoiVals = new Dictionary(); + + /* + * for each value of interest + * see wether one of the variables in the equation-system corresponds to that value of interest + * and if yes, map the corresponding value from the solution of the eqsys to that value of interest + */ + if (glsSolution.Count.Equals(variables.Count)) //only continue if our solution has a value for each of our variables { foreach (ValueOfInterest valueOfInterest in valuesOfIntrest) { @@ -158,124 +201,73 @@ private static List listSimplifiedFacts() { continue; } + //get the fact representing the object associated with the value of interest Fact fact = valueOfInterest.getRelevantFact(); + //see if one of the variable in our equation-system represents the value of interest + MMTTerm correspondingVariable = null; if (fact.GetType().Equals(typeof(CogwheelFact))) { - Debug.Log("getNewlyDiscoveredAvsMap: encountered Cogwheel valOfInt in valsOfInt."); - /* - MMTTerm knownAvVariable = variables.Find(variable => variable.isSimplifiedCogwheelAvTerm() - && ((OMF)((RECARG)((OMA)((OMA)variable).arguments.ElementAt(0)).arguments.ElementAt(0)).value).f.Equals(((CogwheelFact)fact).Radius) - && ((OMF)((OMA)((RECARG)((OMA)((OMA)variable).arguments.ElementAt(0)).arguments.ElementAt(3)).value).arguments.ElementAt(0)).f.Equals(((CogwheelFact)fact).Point.x) - && ((OMF)((OMA)((RECARG)((OMA)((OMA)variable).arguments.ElementAt(0)).arguments.ElementAt(3)).value).arguments.ElementAt(1)).f.Equals(((CogwheelFact)fact).Point.y) - && ((OMF)((OMA)((RECARG)((OMA)((OMA)variable).arguments.ElementAt(0)).arguments.ElementAt(3)).value).arguments.ElementAt(2)).f.Equals(((CogwheelFact)fact).Point.z)); - */ - MMTTerm knownAvVariable = variables.Find(variable => variable.isSimplifiedCogwheelAvTerm() + //Debug.Log("getNewlyDiscoveredAvsMap: encountered Cogwheel valOfInt in valsOfInt."); + correspondingVariable = variables.Find(variable => variable.isSimplifiedCogwheelAvTerm() && ((OMF)((RECARG)((OMA)((OMA)variable).arguments.ElementAt(0)).arguments.ElementAt(7)).value).f.Equals((float)((CogwheelFact)fact).Id)); - //If an element was found - if (knownAvVariable != null) - { - double newlyDiscoveredAv = glsSolution.ElementAt(variables.IndexOf(knownAvVariable)); - //Now we know that the Fact = fact should rotate with angularVelocity = newlyDiscoveredAv - discoveredAvsMap.Add(valueOfInterest, (float)newlyDiscoveredAv); - } } - //ToDo else if (fact.GetType().Equals(typeof(ChainFact))) { - Debug.Log("getNewlyDiscoveredAvsMap: encountered Chain valOfInt in valsOfInt."); - MMTTerm knownCvVariable; - knownCvVariable = variables.Find(variable => variable.isSimplifiedChainCvTerm() + //Debug.Log("getNewlyDiscoveredAvsMap: encountered Chain valOfInt in valsOfInt."); + correspondingVariable = variables.Find(variable => variable.isSimplifiedChainCvTerm() && ((OMF)((RECARG)((OMA)((OMA)variable).arguments.ElementAt(0)).arguments.ElementAt(1)).value).f.Equals((float)((ChainFact)fact).Id)); - if (knownCvVariable != null) - { - Debug.Log("knownCvVariable not null."); - double newlyDiscoveredCv = glsSolution.ElementAt(variables.IndexOf(knownCvVariable)); - //Now we know that the Fact = fact should rotate with angularVelocity = newlyDiscoveredAv - discoveredAvsMap.Add(valueOfInterest, (float)newlyDiscoveredCv); - } - else - { - Debug.Log("knownCvVariable null."); - } } else if (fact.GetType().Equals(typeof(ShaftFact))) { - Debug.Log("getNewlyDiscoveredAvsMap: encountered Shaft valOfInt in valsOfInt."); - MMTTerm knownAvVariable; - knownAvVariable = variables.Find(variable => variable.isSimplifiedShaftAvTerm() + //Debug.Log("getNewlyDiscoveredAvsMap: encountered Shaft valOfInt in valsOfInt."); + correspondingVariable = variables.Find(variable => variable.isSimplifiedShaftAvTerm() && ((OMF)((RECARG)((OMA)((OMA)variable).arguments.ElementAt(0)).arguments.ElementAt(0)).value).f.Equals((float)((ShaftFact)fact).Id)); - if (knownAvVariable != null) - { - Debug.Log("knownCvVariable not null."); - double newlyDiscoveredCv = glsSolution.ElementAt(variables.IndexOf(knownAvVariable)); - //Now we know that the Fact = fact should rotate with angularVelocity = newlyDiscoveredAv - discoveredAvsMap.Add(valueOfInterest, (float)newlyDiscoveredCv); - } - else - { - Debug.Log("knownCvVariable null."); - } } + //if the value of interest is represented by one of the variables + //then get the value from the solution corresponding to that variable from the solution + //and map the value to the value of interest + if (correspondingVariable != null) + { + double discoveredVal = glsSolution.ElementAt(variables.IndexOf(correspondingVariable)); + discoveredVoiVals.Add(valueOfInterest, (float)discoveredVal); + } } } else { Debug.Log("KnowledgeBasedSimulation.getNewlyDiscoveredAvsMap: Variables and GLS-Solution don't have the same number of elements."); - return null; } - //Build relative complement A \ B => discoveredAvsMap \ knownAvMap - return discoveredAvsMap.ToDictionary(x => x.Key, x => x.Value); } - private static string[] equationsToString(List> AData, List bData, List variables, List valuesOfInterest) + //function for parseing the equations encoded in the glsTuple into a human readable form + private static string[] equationsToString(Matrix A, Vector b, List variables, List valuesOfInterest) { List equations = new List(); - if (AData.Count == bData.Count) + if (A.RowCount == b.Count) { - for (int i = 0; i < AData.Count; i++) + for (int i = 0; i < A.RowCount; i++) //for each equation is the equation system { - string equation = ""; + string equation = ""; //have a string into which the equation is written - for (int j = 0; j < AData[i].Count; j++) + for (int j = 0; j < A.ColumnCount; j++) //for each variable in the current equation { + //get the value of interest represented by the current variable MMTTerm variable = variables.ElementAt(j); - - if (valuesOfInterest == null) - { - Debug.Log("valuesOfInterest == null"); - } - if (variable == null) - { - Debug.Log("variable == null"); - } - - //debug - Debug.Log("values of intrest:"); - foreach (ValueOfInterest v in valuesOfInterest) - { - Debug.Log(v + " :"); - Debug.Log("voi name :"+ v.getName()); - Debug.Log("voi relevant fact :" + v.getRelevantFact()); - Debug.Log("voi relevant value :" + v.getRelevantValue()); - } - Debug.Log("variable: " + variable); - ValueOfInterest voi = variableGetValueOfIntrest(valuesOfInterest, variable); + //get the name of said value of interest string voiName = voi.getName(); - //TODO - - if (j == AData[i].Count - 1) + if (j == A.ColumnCount - 1) { - equation += AData[i][j].ToString() + "*" + voiName + " = " + bData[i].ToString(); + equation += A.Row(i)[j].ToString() + "*" + voiName + " = " + b[i].ToString(); } else { - equation += AData[i][j].ToString() + "*" + voiName + " + "; + equation += A.Row(i)[j].ToString() + "*" + voiName + " + "; } } @@ -288,30 +280,287 @@ private static string[] equationsToString(List> AData, List return equations.ToArray(); } + + //function that given the current values of interest and a variable from our equation-system + //returns the value of interest that is represented by the variable + //(if no value of interest is found null is returned) private static ValueOfInterest variableGetValueOfIntrest(List valuesOfInterest, MMTTerm variable) { - Debug.Log("test"); ValueOfInterest valueOfInterest = null; + //see what 'kind' of value of interest is beeing represented by the variable if (variable.isSimplifiedCogwheelAvTerm()) { - Debug.Log("Cogwheel"); + //get the id of the object fact associated with the variable float id = ((OMF)((RECARG)((OMA)((OMA)variable).arguments.ElementAt(0)).arguments.ElementAt(7)).value).f; + //find the value of interest that has an object fact associated with it + //that has the same id as the object fact associated with the variable valueOfInterest = valuesOfInterest.Find(voi => voi.getRelevantFact() != null && ((float)voi.getRelevantFact().Id).Equals(id)); } else if (variable.isSimplifiedChainCvTerm()) { - Debug.Log("Chain"); float id = ((OMF)((RECARG)((OMA)((OMA)variable).arguments.ElementAt(0)).arguments.ElementAt(1)).value).f; valueOfInterest = valuesOfInterest.Find(voi => voi.getRelevantFact() != null && ((float)voi.getRelevantFact().Id).Equals(id)); } else if (variable.isSimplifiedShaftAvTerm()) { - Debug.Log("Shaft"); float id = ((OMF)((RECARG)((OMA)((OMA)variable).arguments.ElementAt(0)).arguments.ElementAt(0)).value).f; valueOfInterest = valuesOfInterest.Find(voi => voi.getRelevantFact() != null && ((float)voi.getRelevantFact().Id).Equals(id)); } return valueOfInterest; } + + + + private static Tuple>, List>, List>> seperateIndependentEqsysComponents(Matrix A, Vector b, List variables) + { + /* + * 1. Turn matrix A into a list of arrays containing the matrix rows + * Turn vector b into a list of double values + * + * 2. Initialize the lists in which to gather the a matrices, b vectors and variable lists of our independent equation systems + * + * 3. Create a ‘group’ of equations in which to gather all equations that share ‘non-0 variables’ across them. Remove the first row out of the row list and add it to the group (do the same for the first b value int the list of b values). Iterate over the remaining rows (and by extension b values) and remove and add all rows (and corresponding b values) which share a ‘non-0 variable’ with any row collected in the group. Repeat this until no such rows remain in the rows list. + * + * 4. Turn the list of collected rows of the group into a matrix. Remove all columns out of the matrix that contain only zeros + * + * 5. Once all rows of a group are collected save all variables out of the input variables list that are not 0 in any of the rows in a list. + * + * 6. add the created matrix, a vector created out of the collected b values, and the created list of variables to the lists created in 2. + * + * 7. repeat 3. - 6. until no rows remain in the rows list + * + * 8. create a tuple out of the Lists created in 2. and return it + */ + + + + // 1. + List ARows = A.ToRowArrays().ToList(); + List bValues = b.ToList(); + + // 2. + List> Matrices = new List>(); + List> bValuesGroups = new List>(); + List> variablesGroups = new List>(); + + // 7. + while (ARows.Count > 0) + { + //3. + List currentGroup = new List(); + currentGroup.Add(ARows.ElementAt(0)); + ARows.RemoveAt(0); + + // + List currentGroup_bValues = new List(); + currentGroup_bValues.Add(bValues.ElementAt(0)); + bValues.RemoveAt(0); + + // + BitArray currentGroupNon0Variables = new BitArray(currentGroup.ElementAt(0).Length); + for (int i = 0; i < currentGroupNon0Variables.Length; i++) + { + currentGroupNon0Variables[i] = System.Convert.ToBoolean(currentGroup.ElementAt(0)[i]); + } + + // + bool expandetGroup; + do + { + // + List ARowsList = ARows.ToList(); + + // + expandetGroup = false; + + + for (int i = ARowsList.Count - 1; i >= 0; i--) + { + // + BitArray equationNon0Variables = new BitArray(ARowsList[i].Length); + for (int j = 0; j < ARowsList[i].Length; j++) + { + equationNon0Variables[j] = Convert.ToBoolean(ARowsList[i][j]); + } + + // + BitArray equationNon0VariablesClone = (BitArray)equationNon0Variables.Clone(); + if (equationNon0VariablesClone.And(currentGroupNon0Variables).Cast().Contains(true)) + { + // + expandetGroup = true; + + // + currentGroup.Add(ARowsList[i]); + ARows.Remove(ARowsList[i]); + + // + currentGroup_bValues.Add(bValues[i]); + bValues.RemoveAt(i); + + // + currentGroupNon0Variables.Or(equationNon0Variables); + + } + } + } + while (expandetGroup == true); + + // 4. + Matrix matrix = Matrix.Build.DenseOfRows(currentGroup); + bValuesGroups.Add(currentGroup_bValues); + + // + for (int i = currentGroupNon0Variables.Count - 1; i >= 0; i--) + { + if (!currentGroupNon0Variables[i]) + { + // + matrix = matrix.RemoveColumn(i); + } + } + + // 5. + List currentGroupVariables = new List(); + for (int i = 0; i < currentGroupNon0Variables.Count; i++) + { + if (currentGroupNon0Variables[i]) + { + // + currentGroupVariables.Add(variables.ElementAt(i)); + } + } + // 6. + variablesGroups.Add(currentGroupVariables); + + // 6. + Matrices.Add(matrix); + + // + } + + // 6. + List> bValueVectors = new List>(); + foreach (List bValueGroup in bValuesGroups) + { + bValueVectors.Add(Vector.Build.DenseOfEnumerable(bValueGroup)); + } + + // 7. + return new Tuple>, List>, List>>(Matrices, bValueVectors, variablesGroups); + } + + /* + private static Tuple>, List>, List>> seperateIndependentEqsysComponents(Matrix eqsys, Vector bVector, List variables) + { + Debug.Log("seperateIndependentEqsysComponents:"); + + List inputEquations = eqsys.ToRowArrays().ToList(); + + List> remainingEquations = new List>(); + foreach(double[] eq in inputEquations) + { + remainingEquations.Add(eq.ToList()); + } + + List remaining_bValues = bVector.ToList(); + + List>> equationGroups = new List>>(); + List> bValueGroups = new List>(); + List> variablesGroups = new List>(); + + while (remainingEquations.Count > 0) + { + List> currentEquationGroup = new List>(); + currentEquationGroup.Add(remainingEquations.ElementAt(0)); + remainingEquations.RemoveAt(0); + List currentGroup_bValues = new List(); + currentGroup_bValues.Add(remaining_bValues.ElementAt(0)); + remaining_bValues.RemoveAt(0); + + BitArray currentGroupNon0Variables = new BitArray(currentEquationGroup.ElementAt(0).Count); + Debug.Log("currentGroupVariables:"); + for (int i = 0; i < currentGroupNon0Variables.Length; i++) + { + currentGroupNon0Variables[i] = System.Convert.ToBoolean(currentEquationGroup.ElementAt(0)[i]); + Debug.Log(currentGroupNon0Variables[i]); + } + + bool expandetGroup; + do + { + List> remainingEquationsList = remainingEquations.ToList(); + expandetGroup = false; + for (int i = 0; i < remainingEquationsList.Count; i++) + { + BitArray equationGroupVariables = new BitArray(remainingEquationsList[i].Count); + Debug.Log("equationGroupVariables"); + for (int j = 0; j < remainingEquationsList[i].Count; j++) + { + equationGroupVariables[j] = Convert.ToBoolean(remainingEquationsList[i][j]); + Debug.Log(equationGroupVariables[j]); + } + + BitArray equationGroupVariablesClone = (BitArray)equationGroupVariables.Clone(); + if (equationGroupVariablesClone.And(currentGroupNon0Variables).Cast().Contains(true)) + { + Debug.Log("dependant equations"); + expandetGroup = true; + + currentEquationGroup.Add(remainingEquationsList[i]); + remainingEquations.Remove(remainingEquationsList[i]); + + currentGroup_bValues.Add(remaining_bValues[i]); + remaining_bValues.Remove(remaining_bValues[i]); + + currentGroupNon0Variables.Or(equationGroupVariables); + Debug.Log("currentGroupNon0Variables"); + for (int j = 0; j < currentGroupNon0Variables.Count; j++) + { + Debug.Log(currentGroupNon0Variables[j]); + } + } + } + } + while (expandetGroup == true); + + List currentGroupVariables = new List(); + + for (int i = currentGroupNon0Variables.Count - 1; i >= 0; i--) + { + if (currentGroupNon0Variables[i]) + { + currentGroupVariables.Add(variables.ElementAt(i)); + } + else + { + foreach (List eq in currentEquationGroup) + { + //eq.RemoveAt(i); + } + } + } + + equationGroups.Add(currentEquationGroup); + bValueGroups.Add(currentGroup_bValues); + variablesGroups.Add(currentGroupVariables); + } + + Debug.Log("equationGroups count: " + equationGroups.Count); + + + List> retMatrixList = new List>(); + List> retVectorList = new List>(); + + for (int i = 0; i < equationGroups.Count; i++) + { + retMatrixList.Add(Matrix.Build.DenseOfRows(equationGroups[i])); + retVectorList.Add(Vector.Build.DenseOfEnumerable(bValueGroups[i])); + } + + return new Tuple>, List>, List>>(retMatrixList, retVectorList, variablesGroups); + } + */ } diff --git a/Assets/Scripts/Refactor/Simulation/SimulatedObject.cs b/Assets/Scripts/Refactor/Simulation/SimulatedObject.cs index ad37c65..8a07e9e 100644 --- a/Assets/Scripts/Refactor/Simulation/SimulatedObject.cs +++ b/Assets/Scripts/Refactor/Simulation/SimulatedObject.cs @@ -2,6 +2,16 @@ using System.Collections.Generic; using UnityEngine; +/** + * simulated objects are all the objects that are either affecting the knowledge based simulation + * or objects that are to be 'simulated' by the knowledge based simulation + * They have + * an id + * a Fact representing the Object on the MMT side + * a GameObject representing the Object in the GameWorld + * a List of 'values of interest' representong the aspects of the object + * that the kowledge based simulation is sopposed to determine + */ public abstract class SimulatedObject { protected int id; @@ -44,6 +54,10 @@ public List getValuesOfInterest() return valuesOfInterest; } + /* + * communicate the results of the knowledge based simulation to the object + * and have the object reflect these results in the game world + */ public abstract void applyValuesOfInterest(Dictionary input); public abstract void unapplyValuesOfInterest(); diff --git a/Assets/Scripts/Refactor/Simulation/Simulation.cs b/Assets/Scripts/Refactor/Simulation/Simulation.cs index 8f2026e..c71d02d 100644 --- a/Assets/Scripts/Refactor/Simulation/Simulation.cs +++ b/Assets/Scripts/Refactor/Simulation/Simulation.cs @@ -46,46 +46,47 @@ public GearboxSimulation() public override void startSimulation() { - - List simCogwheels = simulatedObjects.Where(simObj => simObj.GetType().Equals(typeof(SimulatedCogwheel))).ToList(); - List simChains = simulatedObjects.Where(simObj => simObj.GetType().Equals(typeof(SimulatedChain))).ToList(); - List simShafts = simulatedObjects.Where(simObj => simObj.GetType().Equals(typeof(SimulatedShaft))).ToList(); - List simMotors = simulatedObjects.Where(simObj => simObj.GetType().Equals(typeof(SimulatedMotor))).ToList(); - - List cogCogInteractions = interactions + //gather the different types of interactions that are relevant for the gearbox-simulation from the list of interactions + List cogCogInteractions = this.interactions .Where(interaction => interaction.GetType().Equals(typeof(CogwheelCogwheelInteraction))) .Cast().ToList(); - Debug.Log("cogCogInteractions count: " + cogCogInteractions.Count); - List cogChainInteractions = interactions + List cogChainInteractions = this.interactions .Where(interaction => interaction.GetType().Equals(typeof(CogwheelChainInteraction))) .Cast().ToList(); - Debug.Log("cogChainInteractions count: " + cogChainInteractions.Count); - List shaftCogInteractions = interactions + List shaftCogInteractions = this.interactions .Where(interaction => interaction.GetType().Equals(typeof(ShaftCogwheelInteraction))) .Cast().ToList(); - Debug.Log("shaftCogInteractions count: " + shaftCogInteractions.Count); - List motorShaftInteractions = interactions + List motorShaftInteractions = this.interactions .Where(interaction => interaction.GetType().Equals(typeof(MotorShaftInteraction))) .Cast().ToList(); - Debug.Log("motorShaftInteractions count: " + motorShaftInteractions.Count); - List facts = getExistingFacts(); - List valuesOfInterest = simulatedObjects.Select(simObj => simObj.getValuesOfInterest()).ToList().SelectMany(i => i).ToList(); + //create a new equation-system fact(and therefore add it to the server) + //(this equation-system fact 'is created' using the different interactions of our gearbox + // and gets simplified by the server into a list of equations that define how the different objects making up the gearbox + // are supposed to behave in relation to each other) int eqsysId = GameState.simulationHandler.getNextId(); GameState.simulationHandler.activeSimAddEqsys(); new GearboxEqsys2Fact(eqsysId, cogCogInteractions, cogChainInteractions, shaftCogInteractions, motorShaftInteractions); - + //retrieve a list of all simplified facts in the servers situation-space List sfacts = listSimplifiedFacts(); - Dictionary newlyDiscoveredVoiMap = KnowlegeBasedSimulationRefactor.knowledgeBasedSimulation(facts, valuesOfInterest, sfacts); + //take the server response and calcualte from it the values of interest + //(the result is a dictionary mapping the Values of interest to their calculated values) + List valuesOfInterest = simulatedObjects.Select(simObj => simObj.getValuesOfInterest()).ToList().SelectMany(i => i).ToList(); + Dictionary newlyDiscoveredVoiMap = KnowlegeBasedSimulationRefactor.knowledgeBasedSimulation(valuesOfInterest, sfacts); + //Debug info foreach (KeyValuePair voiVal in newlyDiscoveredVoiMap) { Debug.Log(voiVal.Key.getName() + ": " + voiVal.Value); } + + + //apply the results of the knowlege-based-simulation to the simulated objects + //(and by extension to the game objects representing them in the game world) foreach (SimulatedObject simObj in simulatedObjects) { Dictionary valueOfIntrestValues = new Dictionary(); @@ -109,6 +110,7 @@ public override void stopSimulation() } } + /* private List getExistingFacts() { List existingFacts = new List(); @@ -122,19 +124,27 @@ private List getExistingFacts() return existingFacts; } + */ + /* + * method for retrieving a list of all simplified facts within the servers situation-space + */ private static List listSimplifiedFacts() { + //send hhtp request to get the list of simplified facts from the server UnityWebRequest request = UnityWebRequest.Get(GameSettings.ServerAdress + "/fact/list"); request.method = UnityWebRequest.kHttpVerbGET; AsyncOperation op = request.SendWebRequest(); + //wait for the servers answer while (!op.isDone) { } + //handle potentioal errors if (request.result == UnityWebRequest.Result.ConnectionError || request.result == UnityWebRequest.Result.ProtocolError) { Debug.LogWarning(request.error); return null; } + //process the response else { string response = request.downloadHandler.text; @@ -143,6 +153,7 @@ private static List listSimplifiedFacts() } } + /* private void debugLogList(List input) { foreach (object i in input) @@ -150,4 +161,5 @@ private void debugLogList(List input) Debug.Log(i); } } + */ } \ No newline at end of file diff --git a/Assets/Scripts/Refactor/Simulation/ValueOfInterest.cs b/Assets/Scripts/Refactor/Simulation/ValueOfInterest.cs index 8f123f3..94d46b7 100644 --- a/Assets/Scripts/Refactor/Simulation/ValueOfInterest.cs +++ b/Assets/Scripts/Refactor/Simulation/ValueOfInterest.cs @@ -3,10 +3,14 @@ using UnityEngine; using static JSONManager; +/** + * + * + */ public class ValueOfInterest { private string name; - private Fact relevantFact; + private Fact relevantFact; //Fact representing the Objec to which this value of interest applies private string relevantValue; //MMTURI public ValueOfInterest(string name) diff --git a/Assets/Scripts/Refactor/UI/EquationsDisplayPanel.cs b/Assets/Scripts/Refactor/UI/EquationsDisplayPanel.cs new file mode 100644 index 0000000..d6f697c --- /dev/null +++ b/Assets/Scripts/Refactor/UI/EquationsDisplayPanel.cs @@ -0,0 +1,111 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; +using TMPro; + +public class EquationsDisplayPanel : MonoBehaviour +{ + public GameObject equationsContent; + public GameObject equationsPrefab; + public GameObject rankAText; + public GameObject solutionsText; + public GameObject rankAbText; + public GameObject NumberEquationSystemsText; + public GameObject CurrentEquationSystemText; + + private int currentEquationSytem; + private List equationsList; + private List ARanksList; + private List AbRanksList; + private List numbersOfsolutions; + + // Start is called before the first frame update + void Start() + { + //KnowledgeBasedSimulationPanel should not be visible on startup + Deactivate(); + + CommunicationEvents.showEquationSystemsEvent.AddListener(showEquationSystems); + } + + public void showEquationSystems(List equationsList, List ARanksList, List AbRanksList, List numbersOfsolutions) + { + Debug.Log("showEquationSystems called"); + this.gameObject.SetActive(true); + + this.equationsList = equationsList; + this.ARanksList = ARanksList; + this.AbRanksList = AbRanksList; + this.numbersOfsolutions = numbersOfsolutions; + + this.currentEquationSytem = 0; + + if (equationsList.Count > 0) + { + NumberEquationSystemsText.GetComponentInChildren().text = "Number of Equation Systems: " + equationsList.Count.ToString(); + CurrentEquationSystemText.GetComponentInChildren().text = "current Equation System: " + "1"; + + showEquationSystem(equationsList[0], ARanksList[0], AbRanksList[0], numbersOfsolutions[0]); + } + + } + + private void showEquationSystem(string[] equations, int rankA, int rankAb, string numberOfsolutions) + { + + //Clear previous content + foreach (Transform child in equationsContent.transform) + { + GameObject.Destroy(child.gameObject); + } + + //Create an object for each equation + foreach (string equation in equations) + { + GameObject equationObj = Instantiate(equationsPrefab); + equationObj.transform.SetParent(equationsContent.transform, false); + equationObj.GetComponentInChildren().text = equation; + } + + rankAText.GetComponentInChildren().text = "Rank(A): " + rankA.ToString(); + rankAbText.GetComponentInChildren().text = "Rank(A|b): " + rankAb.ToString(); + solutionsText.GetComponentInChildren().text = "Solutions: " + numberOfsolutions; + } + + public void showNextEquationSystem() + { + if (this.currentEquationSytem + 1 < equationsList.Count) + { + this.currentEquationSytem++; + + CurrentEquationSystemText.GetComponentInChildren().text = "current Equation System: " + + (this.currentEquationSytem + 1); + + showEquationSystem(equationsList[this.currentEquationSytem], ARanksList[this.currentEquationSytem], + AbRanksList[this.currentEquationSytem], numbersOfsolutions[this.currentEquationSytem]); + } + } + + public void showPreviousEquationSystem() + { + if (this.currentEquationSytem - 1 >= 0) + { + this.currentEquationSytem--; + + CurrentEquationSystemText.GetComponentInChildren().text = "current Equation System: " + + (this.currentEquationSytem + 1); + + showEquationSystem(equationsList[this.currentEquationSytem], ARanksList[this.currentEquationSytem], + AbRanksList[this.currentEquationSytem], numbersOfsolutions[this.currentEquationSytem]); + } + } + + + + + public void Deactivate() + { + this.gameObject.SetActive(false); + } +} diff --git a/Assets/Scripts/Refactor/UI/EquationsDisplayPanel.cs.meta b/Assets/Scripts/Refactor/UI/EquationsDisplayPanel.cs.meta new file mode 100644 index 0000000..3d5998b --- /dev/null +++ b/Assets/Scripts/Refactor/UI/EquationsDisplayPanel.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 7e0836ede8357f04d832bd34e417bc59 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: