diff --git a/.vscode/settings.json b/.vscode/settings.json index 4f0fdb8..d244f37 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -56,5 +56,5 @@ "temp/": true, "Temp/": true }, - "dotnet.defaultSolution": "Let-Him-Cook.sln" + "dotnet.defaultSolution": "Let Him Cook.sln" } \ No newline at end of file diff --git a/Assets/Scenes/Noahs kælder.unity b/Assets/Scenes/Noahs kælder.unity index fa88097..48dcb55 100644 --- a/Assets/Scenes/Noahs kælder.unity +++ b/Assets/Scenes/Noahs kælder.unity @@ -104,7 +104,7 @@ NavMeshSettings: serializedVersion: 2 m_ObjectHideFlags: 0 m_BuildSettings: - serializedVersion: 3 + serializedVersion: 2 agentTypeID: 0 agentRadius: 0.5 agentHeight: 2 @@ -117,7 +117,7 @@ NavMeshSettings: cellSize: 0.16666667 manualTileSize: 0 tileSize: 256 - buildHeightMesh: 0 + accuratePlacement: 0 maxJobWorkers: 0 preserveTilesOutsideBounds: 0 debug: @@ -146,9 +146,8 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 24980075} - serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: -7.28, y: 6.29, z: 0} + m_LocalPosition: {x: -8.28, y: -3.95, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: @@ -162,6 +161,7 @@ Transform: - {fileID: 1420342330} - {fileID: 1575942282} m_Father: {fileID: 0} + m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &143107362 GameObject: @@ -189,13 +189,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 143107362} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 6, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 2} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 24980076} + m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!61 &143107364 BoxCollider2D: @@ -207,25 +207,6 @@ BoxCollider2D: m_Enabled: 1 m_Density: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_LayerOverridePriority: 0 - m_ForceSendLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ForceReceiveLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ContactCaptureLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_CallbackLayers: - serializedVersion: 2 - m_Bits: 4294967295 m_IsTrigger: 1 m_UsedByEffector: 0 m_UsedByComposite: 0 @@ -258,7 +239,7 @@ MonoBehaviour: IngredientIn: - {fileID: 1790468147} - {fileID: 1714471222} - NutritionalValue: 0 + NutritionalValue: 50 --- !u!212 &143107366 SpriteRenderer: m_ObjectHideFlags: 0 @@ -337,13 +318,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 389679690} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 12, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 2} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 24980076} + m_RootOrder: 6 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!61 &389679692 BoxCollider2D: @@ -355,25 +336,6 @@ BoxCollider2D: m_Enabled: 1 m_Density: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_LayerOverridePriority: 0 - m_ForceSendLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ForceReceiveLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ContactCaptureLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_CallbackLayers: - serializedVersion: 2 - m_Bits: 4294967295 m_IsTrigger: 1 m_UsedByEffector: 0 m_UsedByComposite: 0 @@ -406,7 +368,7 @@ MonoBehaviour: IngredientIn: - {fileID: 460072661} - {fileID: 1525651426} - NutritionalValue: 0 + NutritionalValue: 15 --- !u!212 &389679694 SpriteRenderer: m_ObjectHideFlags: 0 @@ -459,6 +421,133 @@ SpriteRenderer: m_WasSpriteAssigned: 1 m_MaskInteraction: 0 m_SpriteSortPoint: 0 +--- !u!1 &449563471 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 449563472} + - component: {fileID: 449563475} + - component: {fileID: 449563474} + - component: {fileID: 449563473} + m_Layer: 0 + m_Name: Hard-Boiled Egg + m_TagString: Ingredient + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &449563472 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 449563471} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: -1.2199998, y: -0.119999886, z: -0.038593948} + m_LocalScale: {x: 2, y: 2, z: 2} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 1325490341} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &449563473 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 449563471} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: af04675200abb744bb6ce073aae8899d, type: 3} + m_Name: + m_EditorClassIdentifier: + RequiredIngredients: + - {fileID: 885031692} + NutritionalValue: 78 +--- !u!61 &449563474 +BoxCollider2D: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 449563471} + m_Enabled: 1 + m_Density: 1 + m_Material: {fileID: 0} + m_IsTrigger: 1 + m_UsedByEffector: 0 + m_UsedByComposite: 0 + m_Offset: {x: 0, y: 0} + m_SpriteTilingProperty: + border: {x: 0, y: 0, z: 0, w: 0} + pivot: {x: 0.5, y: 0.5} + oldSize: {x: 0.64, y: 0.64} + newSize: {x: 1, y: 1} + adaptiveTilingThreshold: 0.5 + drawMode: 0 + adaptiveTiling: 0 + m_AutoTiling: 0 + serializedVersion: 2 + m_Size: {x: 0.64, y: 0.64} + m_EdgeRadius: 0 +--- !u!212 &449563475 +SpriteRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 449563471} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 0 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 0 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_Sprite: {fileID: 21300000, guid: ff55674392a0b614d93550c947d37083, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 + m_DrawMode: 0 + m_Size: {x: 1, y: 1} + m_AdaptiveModeThreshold: 0.5 + m_SpriteTileMode: 0 + m_WasSpriteAssigned: 1 + m_MaskInteraction: 0 + m_SpriteSortPoint: 0 --- !u!1 &460072661 GameObject: m_ObjectHideFlags: 0 @@ -554,13 +643,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 460072661} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: 0.011939, w: -0.9999287} m_LocalPosition: {x: 4.06, y: 0.01, z: 0} m_LocalScale: {x: 2, y: 2, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1325490341} + m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: -1.368} --- !u!1 &537514707 GameObject: @@ -640,13 +729,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 537514707} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 1.97, y: -0.06, z: 0} m_LocalScale: {x: 2, y: 2, z: 2} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 24980076} + m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &537514710 MonoBehaviour: @@ -664,7 +753,7 @@ MonoBehaviour: IngredientIn: - {fileID: 867381650} - {fileID: 1714471222} - NutritionalValue: 0 + NutritionalValue: 50 --- !u!61 &537514711 BoxCollider2D: m_ObjectHideFlags: 0 @@ -675,25 +764,6 @@ BoxCollider2D: m_Enabled: 1 m_Density: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_LayerOverridePriority: 0 - m_ForceSendLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ForceReceiveLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ContactCaptureLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_CallbackLayers: - serializedVersion: 2 - m_Bits: 4294967295 m_IsTrigger: 1 m_UsedByEffector: 0 m_UsedByComposite: 0 @@ -710,6 +780,90 @@ BoxCollider2D: serializedVersion: 2 m_Size: {x: 0.64, y: 0.64} m_EdgeRadius: 0 +--- !u!1 &557296747 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 557296748} + - component: {fileID: 557296749} + m_Layer: 0 + m_Name: Costumer + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &557296748 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 557296747} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 12.37, y: 4.11, z: 0.040322114} + m_LocalScale: {x: 6.213878, y: 15.796195, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 5 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!212 &557296749 +SpriteRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 557296747} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 0 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 1 + m_SelectedEditorRenderState: 0 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_Sprite: {fileID: 21300000, guid: 82bbbf75f69133741a4810d58beb7b49, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 + m_DrawMode: 0 + m_Size: {x: 0.64, y: 0.64} + m_AdaptiveModeThreshold: 0.5 + m_SpriteTileMode: 0 + m_WasSpriteAssigned: 1 + m_MaskInteraction: 0 + m_SpriteSortPoint: 0 --- !u!1 &578240409 GameObject: m_ObjectHideFlags: 0 @@ -744,7 +898,7 @@ MonoBehaviour: - {fileID: 1001436608} - {fileID: 1274549341} - {fileID: 1659394507} - NutritionalValue: 0 + NutritionalValue: 13 --- !u!212 &578240411 SpriteRenderer: m_ObjectHideFlags: 0 @@ -804,13 +958,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 578240409} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 6, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1325490341} + m_RootOrder: 4 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &755662324 GameObject: @@ -837,13 +991,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 755662324} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 14, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1325490341} + m_RootOrder: 8 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &755662326 MonoBehaviour: @@ -860,8 +1014,7 @@ MonoBehaviour: RequiredIngredients: - {fileID: 1420342329} - {fileID: 1575942281} - - {fileID: 885031692} - NutritionalValue: 0 + NutritionalValue: 3 --- !u!212 &755662327 SpriteRenderer: m_ObjectHideFlags: 0 @@ -954,17 +1107,9 @@ Camera: m_projectionMatrixMode: 1 m_GateFitMode: 2 m_FOVAxisMode: 0 - m_Iso: 200 - m_ShutterSpeed: 0.005 - m_Aperture: 16 - m_FocusDistance: 10 - m_FocalLength: 50 - m_BladeCount: 5 - m_Curvature: {x: 2, y: 11} - m_BarrelClipping: 0.25 - m_Anamorphism: 0 m_SensorSize: {x: 36, y: 24} m_LensShift: {x: 0, y: 0} + m_FocalLength: 50 m_NormalizedViewPortRect: serializedVersion: 2 x: 0 @@ -998,13 +1143,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 759826127} - serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: -10} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 0} + m_RootOrder: 4 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &867381650 GameObject: @@ -1031,13 +1176,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 867381650} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 0.34, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1325490341} + m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!212 &867381652 SpriteRenderer: @@ -1105,7 +1250,7 @@ MonoBehaviour: m_EditorClassIdentifier: RequiredIngredients: - {fileID: 537514707} - NutritionalValue: 0 + NutritionalValue: 3 --- !u!1 &885031692 GameObject: m_ObjectHideFlags: 0 @@ -1132,13 +1277,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 885031692} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: -0.01, y: -0.03, z: 0} m_LocalScale: {x: 2, y: 2, z: 2} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 24980076} + m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!61 &885031694 BoxCollider2D: @@ -1150,25 +1295,6 @@ BoxCollider2D: m_Enabled: 1 m_Density: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_LayerOverridePriority: 0 - m_ForceSendLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ForceReceiveLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ContactCaptureLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_CallbackLayers: - serializedVersion: 2 - m_Bits: 4294967295 m_IsTrigger: 1 m_UsedByEffector: 0 m_UsedByComposite: 0 @@ -1200,7 +1326,8 @@ MonoBehaviour: transform: {fileID: 885031693} IngredientIn: - {fileID: 460072661} - NutritionalValue: 0 + - {fileID: 1680633067} + NutritionalValue: 20 --- !u!212 &885031696 SpriteRenderer: m_ObjectHideFlags: 0 @@ -1279,13 +1406,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1001436608} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 3.84, y: -0.11, z: 0} m_LocalScale: {x: 2, y: 2, z: 2} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 24980076} + m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!61 &1001436610 BoxCollider2D: @@ -1297,25 +1424,6 @@ BoxCollider2D: m_Enabled: 1 m_Density: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_LayerOverridePriority: 0 - m_ForceSendLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ForceReceiveLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ContactCaptureLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_CallbackLayers: - serializedVersion: 2 - m_Bits: 4294967295 m_IsTrigger: 1 m_UsedByEffector: 0 m_UsedByComposite: 0 @@ -1348,7 +1456,7 @@ MonoBehaviour: IngredientIn: - {fileID: 1790468147} - {fileID: 578240409} - NutritionalValue: 0 + NutritionalValue: 5 --- !u!212 &1001436612 SpriteRenderer: m_ObjectHideFlags: 0 @@ -1477,13 +1585,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1147379266} - serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 1.1} m_LocalScale: {x: 1.7, y: 1.7, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 0} + m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1274549341 GameObject: @@ -1511,13 +1619,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1274549341} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 8, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 2} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 24980076} + m_RootOrder: 4 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!61 &1274549343 BoxCollider2D: @@ -1529,25 +1637,6 @@ BoxCollider2D: m_Enabled: 1 m_Density: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_LayerOverridePriority: 0 - m_ForceSendLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ForceReceiveLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ContactCaptureLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_CallbackLayers: - serializedVersion: 2 - m_Bits: 4294967295 m_IsTrigger: 1 m_UsedByEffector: 0 m_UsedByComposite: 0 @@ -1582,7 +1671,7 @@ MonoBehaviour: - {fileID: 460072661} - {fileID: 578240409} - {fileID: 1525651426} - NutritionalValue: 0 + NutritionalValue: 40 --- !u!212 &1274549345 SpriteRenderer: m_ObjectHideFlags: 0 @@ -1660,13 +1749,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1325467679} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 16, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1325490341} + m_RootOrder: 9 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &1325467681 MonoBehaviour: @@ -1683,7 +1772,7 @@ MonoBehaviour: RequiredIngredients: - {fileID: 1575942281} - {fileID: 885031692} - NutritionalValue: 0 + NutritionalValue: 5 --- !u!212 &1325467682 SpriteRenderer: m_ObjectHideFlags: 0 @@ -1759,12 +1848,12 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1325490340} - serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: -7.36, y: 8.16, z: 0.038593948} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: + - {fileID: 449563472} - {fileID: 867381651} - {fileID: 1790468148} - {fileID: 460072664} @@ -1775,6 +1864,7 @@ Transform: - {fileID: 755662325} - {fileID: 1325467680} m_Father: {fileID: 0} + m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1420342329 GameObject: @@ -1802,13 +1892,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1420342329} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 14, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 2} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 24980076} + m_RootOrder: 7 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!61 &1420342331 BoxCollider2D: @@ -1820,25 +1910,6 @@ BoxCollider2D: m_Enabled: 1 m_Density: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_LayerOverridePriority: 0 - m_ForceSendLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ForceReceiveLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ContactCaptureLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_CallbackLayers: - serializedVersion: 2 - m_Bits: 4294967295 m_IsTrigger: 1 m_UsedByEffector: 0 m_UsedByComposite: 0 @@ -1870,7 +1941,9 @@ MonoBehaviour: transform: {fileID: 1420342330} IngredientIn: - {fileID: 460072661} - NutritionalValue: 0 + - {fileID: 755662324} + - {fileID: 1680633067} + NutritionalValue: 35 --- !u!212 &1420342333 SpriteRenderer: m_ObjectHideFlags: 0 @@ -1953,25 +2026,6 @@ BoxCollider2D: m_Enabled: 1 m_Density: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_LayerOverridePriority: 0 - m_ForceSendLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ForceReceiveLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ContactCaptureLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_CallbackLayers: - serializedVersion: 2 - m_Bits: 4294967295 m_IsTrigger: 1 m_UsedByEffector: 0 m_UsedByComposite: 0 @@ -2047,7 +2101,6 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1517788312} - serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: -0.19, y: 3.03, z: 1} m_LocalScale: {x: 4.0825, y: 3.375, z: 1} @@ -2055,6 +2108,7 @@ Transform: m_Children: - {fileID: 1639705739} m_Father: {fileID: 0} + m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &1517788316 MonoBehaviour: @@ -2069,6 +2123,7 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: FinishedDishPosition: {x: -4.66, y: 2.89, z: 0} + AllIngredients: {fileID: 24980075} --- !u!50 &1517788317 Rigidbody2D: serializedVersion: 4 @@ -2086,12 +2141,6 @@ Rigidbody2D: m_AngularDrag: 0.05 m_GravityScale: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 m_Interpolate: 0 m_SleepingMode: 1 m_CollisionDetection: 0 @@ -2121,13 +2170,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1525651426} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 10, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1325490341} + m_RootOrder: 6 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &1525651428 MonoBehaviour: @@ -2224,13 +2273,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1575942281} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 16, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 2} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 24980076} + m_RootOrder: 8 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!61 &1575942283 BoxCollider2D: @@ -2242,25 +2291,6 @@ BoxCollider2D: m_Enabled: 1 m_Density: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_LayerOverridePriority: 0 - m_ForceSendLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ForceReceiveLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ContactCaptureLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_CallbackLayers: - serializedVersion: 2 - m_Bits: 4294967295 m_IsTrigger: 1 m_UsedByEffector: 0 m_UsedByComposite: 0 @@ -2292,7 +2322,9 @@ MonoBehaviour: transform: {fileID: 1575942282} IngredientIn: - {fileID: 1680633067} - NutritionalValue: 0 + - {fileID: 755662324} + - {fileID: 1325467679} + NutritionalValue: 30 --- !u!212 &1575942285 SpriteRenderer: m_ObjectHideFlags: 0 @@ -2372,13 +2404,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1639705738} - serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0.033, y: -0.604, z: -1} m_LocalScale: {x: 0.4, y: 0.4, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1517788315} + m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!212 &1639705740 SpriteRenderer: @@ -2455,25 +2487,6 @@ BoxCollider2D: m_Enabled: 1 m_Density: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_LayerOverridePriority: 0 - m_ForceSendLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ForceReceiveLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ContactCaptureLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_CallbackLayers: - serializedVersion: 2 - m_Bits: 4294967295 m_IsTrigger: 1 m_UsedByEffector: 0 m_UsedByComposite: 0 @@ -2507,12 +2520,6 @@ Rigidbody2D: m_AngularDrag: 0.05 m_GravityScale: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 m_Interpolate: 0 m_SleepingMode: 1 m_CollisionDetection: 0 @@ -2530,7 +2537,7 @@ GameObject: - component: {fileID: 1659394510} - component: {fileID: 1659394509} m_Layer: 0 - m_Name: Toast + m_Name: Bread m_TagString: Ingredient m_Icon: {fileID: 0} m_NavMeshLayer: 0 @@ -2543,13 +2550,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1659394507} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 10, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 2} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 24980076} + m_RootOrder: 5 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!61 &1659394509 BoxCollider2D: @@ -2561,25 +2568,6 @@ BoxCollider2D: m_Enabled: 1 m_Density: 1 m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_LayerOverridePriority: 0 - m_ForceSendLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ForceReceiveLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_ContactCaptureLayers: - serializedVersion: 2 - m_Bits: 4294967295 - m_CallbackLayers: - serializedVersion: 2 - m_Bits: 4294967295 m_IsTrigger: 1 m_UsedByEffector: 0 m_UsedByComposite: 0 @@ -2612,7 +2600,7 @@ MonoBehaviour: IngredientIn: - {fileID: 578240409} - {fileID: 1525651426} - NutritionalValue: 0 + NutritionalValue: 25 --- !u!212 &1659394511 SpriteRenderer: m_ObjectHideFlags: 0 @@ -2698,7 +2686,8 @@ MonoBehaviour: RequiredIngredients: - {fileID: 1420342329} - {fileID: 1575942281} - NutritionalValue: 0 + - {fileID: 885031692} + NutritionalValue: 2 --- !u!212 &1680633069 SpriteRenderer: m_ObjectHideFlags: 0 @@ -2758,13 +2747,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1680633067} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 12, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1325490341} + m_RootOrder: 7 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1714471222 GameObject: @@ -2799,7 +2788,8 @@ MonoBehaviour: RequiredIngredients: - {fileID: 143107362} - {fileID: 537514707} - NutritionalValue: 25 + - {fileID: 1001436608} + NutritionalValue: 0 --- !u!212 &1714471224 SpriteRenderer: m_ObjectHideFlags: 0 @@ -2859,13 +2849,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1714471222} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 8, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1325490341} + m_RootOrder: 5 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1790468147 GameObject: @@ -2892,13 +2882,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1790468147} - serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 2, y: 0, z: 0} m_LocalScale: {x: 2, y: 2, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1325490341} + m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &1790468149 MonoBehaviour: @@ -2916,7 +2906,7 @@ MonoBehaviour: - {fileID: 143107362} - {fileID: 1274549341} - {fileID: 1001436608} - NutritionalValue: 0 + NutritionalValue: 300 --- !u!212 &1790468150 SpriteRenderer: m_ObjectHideFlags: 0 @@ -2969,12 +2959,3 @@ SpriteRenderer: m_WasSpriteAssigned: 1 m_MaskInteraction: 0 m_SpriteSortPoint: 0 ---- !u!1660057539 &9223372036854775807 -SceneRoots: - m_ObjectHideFlags: 0 - m_Roots: - - {fileID: 759826130} - - {fileID: 24980076} - - {fileID: 1147379268} - - {fileID: 1517788315} - - {fileID: 1325490341} diff --git a/Assets/Scripts/Cooking.cs b/Assets/Scripts/Cooking.cs index 7b6c32d..ca708b9 100644 --- a/Assets/Scripts/Cooking.cs +++ b/Assets/Scripts/Cooking.cs @@ -15,6 +15,7 @@ public class Cooking : MonoBehaviour // } public Vector3 FinishedDishPosition; + public GameObject AllIngredients; public void CreateDish() { List Ingredients = GetIngredients(); @@ -29,8 +30,6 @@ public class Cooking : MonoBehaviour foreach (GameObject Ingredient in Ingredients) { - Debug.Log(Ingredient.name); - List Dishes = Ingredient.GetComponent().IngredientIn; foreach (GameObject Dish in Dishes) { @@ -97,14 +96,27 @@ public class Cooking : MonoBehaviour } } - // Remove ingredients and add the dish + // // Remove ingredients and add the dish + // foreach (GameObject Ingredient in UsedIngredients) { + // Transform transform = Ingredient.GetComponent().transform; + // transform.position = Vector3.up * 50; + // } + + BestDish.transform.position = FinishedDishPosition; + foreach (GameObject Ingredient in UsedIngredients) { Transform transform = Ingredient.GetComponent().transform; transform.position = Vector3.up * 50; } - BestDish.transform.position = FinishedDishPosition; + // Return ingredients to table + for (int i = 0; i < AllIngredients.transform.childCount; i++) + { + GameObject ingredient = AllIngredients.transform.GetChild(i).gameObject; + + ingredient.GetComponent().ResetPosition(); + } } diff --git a/Assets/Scripts/Dish.cs b/Assets/Scripts/Dish.cs index a1dba51..60a15ed 100644 --- a/Assets/Scripts/Dish.cs +++ b/Assets/Scripts/Dish.cs @@ -5,18 +5,26 @@ using UnityEngine; public class Dish : MonoBehaviour { public List RequiredIngredients; - public int NutritionalValue; + public int NutritionalValue = 0; // Start is called before the first frame update void Start() { + + if (NutritionalValue > 0) { + return; + } + + NutritionalValue = 0; + foreach (GameObject Ingredient in RequiredIngredients) { + + int IngredientValue = Ingredient.GetComponent().NutritionalValue; + + NutritionalValue += IngredientValue; + + } } - // Update is called once per frame - void Update() - { - - } } diff --git a/Assets/Scripts/Ingredient.cs b/Assets/Scripts/Ingredient.cs index 2ea459e..21e4be0 100644 --- a/Assets/Scripts/Ingredient.cs +++ b/Assets/Scripts/Ingredient.cs @@ -12,9 +12,10 @@ public class Ingredient : MonoBehaviour public int NutritionalValue; bool isMoving = false; //public GameObject table; + private Transform DefaultTransform; void Start() { - + DefaultTransform = transform; //TODO pointer error } // Update is called once per frame @@ -24,9 +25,10 @@ public class Ingredient : MonoBehaviour { Vector3 mousePosition = Camera.main.ScreenToWorldPoint(Input.mousePosition); transform.position = new Vector3 (mousePosition.x, mousePosition.y, transform.position.z); - //Debug.Log(table.Bounds.Contains(mousePosition)); } + ResetPosition(); + } @@ -37,4 +39,12 @@ public class Ingredient : MonoBehaviour else isMoving = true; } + + public void ResetPosition() + { + transform.position = DefaultTransform.position; + Debug.Log(gameObject.name); + Debug.Log(transform.position); + Debug.Log(DefaultTransform.position); + } }