Commit c2581977 authored by KenzyAshour2's avatar KenzyAshour2

did the rock particle system added the replay button

parent fcf61210
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
fileFormatVersion: 2
guid: 2c01b18b37e4b314db11b69373af98b2
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
This source diff could not be displayed because it is too large. You can view the blob instead.
fileFormatVersion: 2
guid: d9ba27a385cd28d4e9e0b2b78fc0598c
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
......@@ -10,7 +10,6 @@ GameObject:
m_Component:
- component: {fileID: 6487795819855637101}
- component: {fileID: 8551629717659174405}
- component: {fileID: 7826709417781551847}
- component: {fileID: 7581605642125399447}
m_Layer: 0
m_Name: Spwaner2
......@@ -86,19 +85,6 @@ SpriteRenderer:
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
m_SpriteSortPoint: 0
--- !u!114 &7826709417781551847
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8621037051837905417}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: a988a7abe4883994ea526b4fb710800b, type: 3}
m_Name:
m_EditorClassIdentifier:
gravityscale: 0.2
--- !u!58 &7581605642125399447
CircleCollider2D:
m_ObjectHideFlags: 0
......
......@@ -10,7 +10,6 @@ GameObject:
m_Component:
- component: {fileID: 6487795819855637101}
- component: {fileID: 8551629717659174405}
- component: {fileID: 7826709417781551847}
- component: {fileID: 7581605642125399447}
m_Layer: 0
m_Name: spawner
......@@ -29,7 +28,7 @@ Transform:
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -3.93, y: -0.0374, z: 0}
m_LocalScale: {x: 0.5432894, y: 0.5432894, z: 0.5432894}
m_LocalScale: {x: 0.54328936, y: 0.54328936, z: 0.54328936}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 0}
......@@ -86,19 +85,6 @@ SpriteRenderer:
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
m_SpriteSortPoint: 0
--- !u!114 &7826709417781551847
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8621037051837905417}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: a988a7abe4883994ea526b4fb710800b, type: 3}
m_Name:
m_EditorClassIdentifier:
gravityscale: 0.2
--- !u!58 &7581605642125399447
CircleCollider2D:
m_ObjectHideFlags: 0
......
......@@ -153,6 +153,81 @@ Transform:
m_Children: []
m_Father: {fileID: 1220522346}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &63772460
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 63772461}
- component: {fileID: 63772463}
- component: {fileID: 63772462}
m_Layer: 5
m_Name: Message (1)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &63772461
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 63772460}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 0.030605495, y: 0.13068919, z: 0.24960327}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1701076841}
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: 2.1, y: 0.4}
m_SizeDelta: {x: 1642.266, y: 121.6135}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &63772462
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 63772460}
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: 1}
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: 21300000, guid: 98dbae1b612a8408ca9252d6c026b3ca, type: 3}
m_Type: 0
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 &63772463
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 63772460}
m_CullTransparentMesh: 1
--- !u!1 &120353622
GameObject:
m_ObjectHideFlags: 0
......@@ -1976,25 +2051,10 @@ Transform:
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 1719131806}
- {fileID: 873217661}
- {fileID: 1731667186}
- {fileID: 318756944}
- {fileID: 1124648097}
- {fileID: 694476250}
- {fileID: 1148162388}
- {fileID: 1802961620}
- {fileID: 1339775669}
- {fileID: 6487795820825723704}
- {fileID: 6487795820262276379}
- {fileID: 6487795819552119059}
- {fileID: 6487795820829508717}
- {fileID: 6487795820311449261}
- {fileID: 6487795820375087467}
- {fileID: 6487795819825015281}
- {fileID: 6487795820076689221}
- {fileID: 6487795819872092342}
- {fileID: 6487795820416849293}
- {fileID: 6487795819570424898}
- {fileID: 6487795820112505816}
- {fileID: 1641698562}
m_Father: {fileID: 1394706199}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &1089729862
......@@ -2303,6 +2363,42 @@ Transform:
- {fileID: 1933211609}
m_Father: {fileID: 1394706199}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &1148162387
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1148162388}
m_Layer: 0
m_Name: Rockbubble
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &1148162388
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1148162387}
serializedVersion: 2
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_ConstrainProportionsScale: 0
m_Children:
- {fileID: 873217661}
- {fileID: 1731667186}
- {fileID: 318756944}
- {fileID: 1124648097}
- {fileID: 694476250}
m_Father: {fileID: 1020260190}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &1157669036
GameObject:
m_ObjectHideFlags: 0
......@@ -2384,9 +2480,9 @@ RectTransform:
- {fileID: 613853316}
m_Father: {fileID: 1908486418}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 0, y: 0}
m_AnchoredPosition: {x: 0, y: 0}
m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 162.78, y: -693.605}
m_SizeDelta: {x: 100.7039, y: 30}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1202860662
......@@ -2631,11 +2727,13 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 39f2615ea05a10a42817d45abeaf8d89, type: 3}
m_Name:
m_EditorClassIdentifier:
rockDebrisPrefab: {fileID: 289591815371307681, guid: 9a359f478ca80654ab33a9cb76129210, type: 3}
spawnPoints:
- {fileID: 974067283}
- {fileID: 26895170}
- {fileID: 1278599776}
rockDebrisPrefab: {fileID: 289591815371307681, guid: 9a359f478ca80654ab33a9cb76129210, type: 3}
dustEffectPrefab: {fileID: 7124070107328540038, guid: 2c01b18b37e4b314db11b69373af98b2, type: 3}
effectDuration: 1
--- !u!60 &1220522348
PolygonCollider2D:
m_ObjectHideFlags: 0
......@@ -3202,7 +3300,7 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 4097764699363606736, guid: 09c49576cfb25ea4a9b324bba2313431, type: 3}
propertyPath: m_AnchoredPosition.y
value: 0.00010681152
value: -0.00015258789
objectReference: {fileID: 0}
- target: {fileID: 4816839199865668264, guid: 09c49576cfb25ea4a9b324bba2313431, type: 3}
propertyPath: m_Pivot.x
......@@ -3314,7 +3412,7 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 7282057206058197842, guid: 09c49576cfb25ea4a9b324bba2313431, type: 3}
propertyPath: m_AnchoredPosition.y
value: -407
value: -415
objectReference: {fileID: 0}
- target: {fileID: 7775766092117125703, guid: 09c49576cfb25ea4a9b324bba2313431, type: 3}
propertyPath: dialoguePrefabAR
......@@ -3322,7 +3420,7 @@ PrefabInstance:
objectReference: {fileID: 1741054887350408350, guid: 0e2d5176947e64a6596c1adb8577d8c3, type: 3}
- target: {fileID: 8682474168494590580, guid: 09c49576cfb25ea4a9b324bba2313431, type: 3}
propertyPath: m_IsActive
value: 1
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8832950163780524694, guid: 09c49576cfb25ea4a9b324bba2313431, type: 3}
propertyPath: m_AnchoredPosition.y
......@@ -3550,6 +3648,49 @@ Transform:
m_Children: []
m_Father: {fileID: 1734301001}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &1641698561
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1641698562}
m_Layer: 0
m_Name: Rocks
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &1641698562
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1641698561}
serializedVersion: 2
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_ConstrainProportionsScale: 0
m_Children:
- {fileID: 6487795820825723704}
- {fileID: 6487795820262276379}
- {fileID: 6487795819552119059}
- {fileID: 6487795820829508717}
- {fileID: 6487795820311449261}
- {fileID: 6487795820375087467}
- {fileID: 6487795819825015281}
- {fileID: 6487795820076689221}
- {fileID: 6487795819872092342}
- {fileID: 6487795820416849293}
- {fileID: 6487795819570424898}
- {fileID: 6487795820112505816}
m_Father: {fileID: 1020260190}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &1646829372
GameObject:
m_ObjectHideFlags: 0
......@@ -3782,6 +3923,155 @@ RectTransform:
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: 0}
m_Pivot: {x: 0, y: 0}
--- !u!1 &1701076836
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1701076841}
- component: {fileID: 1701076840}
- component: {fileID: 1701076838}
- component: {fileID: 1701076837}
- component: {fileID: 1701076839}
m_Layer: 5
m_Name: Replay
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 0
--- !u!114 &1701076837
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1701076836}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Navigation:
m_Mode: 0
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: 1701076838}
m_OnClick:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 1831094292}
m_TargetAssemblyTypeName: ImageSwitcher, Assembly-CSharp
m_MethodName: RestartGame
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 &1701076838
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1701076836}
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.93207544, g: 0.5561239, b: 0, 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_Sprite: {fileID: 21300000, guid: a65ce01f375554476acaef3c5d8a58a1, type: 3}
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!114 &1701076839
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1701076836}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: cfabb0440166ab443bba8876756fdfa9, type: 3}
m_Name:
m_EditorClassIdentifier:
m_EffectColor: {r: 0, g: 0, b: 0, a: 0.5}
m_EffectDistance: {x: 3.64, y: -1.31}
m_UseGraphicAlpha: 1
--- !u!222 &1701076840
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1701076836}
m_CullTransparentMesh: 1
--- !u!224 &1701076841
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1701076836}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1.0243465, y: 3.155228, z: 1.6520385}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 63772461}
m_Father: {fileID: 1908486418}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 162.78, y: -799.99994}
m_SizeDelta: {x: 100.7039, y: 30}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!1 &1719131805
GameObject:
m_ObjectHideFlags: 0
......@@ -3890,8 +4180,20 @@ PrefabInstance:
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 1020260190}
m_TransformParent: {fileID: 1148162388}
m_Modifications:
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalScale.x
value: 0.54328936
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalScale.y
value: 0.54328936
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalScale.z
value: 0.54328936
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalPosition.x
value: 1.08
......@@ -3910,15 +4212,15 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalRotation.x
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalRotation.y
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalRotation.z
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
......@@ -4220,6 +4522,8 @@ MonoBehaviour:
- {fileID: 1208495771}
- {fileID: 1020260188}
- {fileID: 1999948108}
nextButton: {fileID: 1202860662}
restartButton: {fileID: 1701076837}
--- !u!4 &1831094293
Transform:
m_ObjectHideFlags: 0
......@@ -4367,7 +4671,6 @@ GameObject:
- component: {fileID: 1908486418}
- component: {fileID: 1908486421}
- component: {fileID: 1908486420}
- component: {fileID: 1908486419}
m_Layer: 5
m_Name: Buttons Panel
m_TagString: Untagged
......@@ -4388,6 +4691,7 @@ RectTransform:
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 1202860661}
- {fileID: 1701076841}
m_Father: {fileID: 1668215516}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
......@@ -4395,32 +4699,6 @@ RectTransform:
m_AnchoredPosition: {x: 0, y: 0.0020751953}
m_SizeDelta: {x: 0, y: 0}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1908486419
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1908486417}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 59f8146938fff824cb5fd77236b75775, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Padding:
m_Left: 0
m_Right: 0
m_Top: 0
m_Bottom: 375
m_ChildAlignment: 7
m_Spacing: 0
m_ChildForceExpandWidth: 1
m_ChildForceExpandHeight: 1
m_ChildControlWidth: 0
m_ChildControlHeight: 0
m_ChildScaleWidth: 0
m_ChildScaleHeight: 0
m_ReverseArrangement: 0
--- !u!114 &1908486420
MonoBehaviour:
m_ObjectHideFlags: 0
......@@ -4999,11 +5277,12 @@ MonoBehaviour:
- {fileID: 332253923, guid: 6d7ead12437f497459e0c519a6fd20c7, type: 3}
- {fileID: -297345632, guid: 0dec8edfde20d1d4db322756ed0ac1f3, type: 3}
nextButton: {fileID: 1202860662}
moveSpeed: 5
startOffset: {x: 9, y: 10}
rotationSpeed: 360
shakeDuration: 0.1
shakeMagnitude: 0.4
hitEffectPrefab: {fileID: 7124070107328540038, guid: d9ba27a385cd28d4e9e0b2b78fc0598c, type: 3}
effectDuration: 1
--- !u!212 &2107062292
SpriteRenderer:
m_ObjectHideFlags: 0
......@@ -5160,7 +5439,7 @@ PrefabInstance:
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 1020260190}
m_TransformParent: {fileID: 1148162388}
m_Modifications:
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalPosition.x
......@@ -5180,15 +5459,15 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalRotation.x
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalRotation.y
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalRotation.z
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
......@@ -5217,11 +5496,23 @@ PrefabInstance:
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 1020260190}
m_TransformParent: {fileID: 1148162388}
m_Modifications:
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalScale.x
value: 0.54328936
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalScale.y
value: 0.54328936
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalScale.z
value: 0.54328936
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalPosition.x
value: 3.81
value: 3.8100002
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalPosition.y
......@@ -5237,15 +5528,15 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalRotation.x
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalRotation.y
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalRotation.z
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
......@@ -5274,11 +5565,23 @@ PrefabInstance:
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 1020260190}
m_TransformParent: {fileID: 1148162388}
m_Modifications:
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalScale.x
value: 0.54328936
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalScale.y
value: 0.54328936
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalScale.z
value: 0.54328936
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalPosition.x
value: -5.46
value: -5.4599996
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalPosition.y
......@@ -5294,15 +5597,15 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalRotation.x
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalRotation.y
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalRotation.z
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 51d78aefd5de06d4ca8281fb359b8068, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
......@@ -5331,11 +5634,23 @@ PrefabInstance:
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 1020260190}
m_TransformParent: {fileID: 1148162388}
m_Modifications:
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalScale.x
value: 0.54328936
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalScale.y
value: 0.54328936
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalScale.z
value: 0.54328936
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalPosition.x
value: 5.07
value: 5.0699997
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalPosition.y
......@@ -5351,15 +5666,15 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalRotation.x
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalRotation.y
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalRotation.z
value: 0
value: -0
objectReference: {fileID: 0}
- target: {fileID: 6487795819855637101, guid: 543871ca6c7e44a4392c5b1cf82a39db, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
......@@ -5391,11 +5706,11 @@ Transform:
m_GameObject: {fileID: 8621037051064486263}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 4.3736286, y: -4.112592, z: 0}
m_LocalPosition: {x: 4.3736286, y: -4.1125917, z: 0}
m_LocalScale: {x: 0.2873513, y: 0.2873513, z: 0.2873513}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1020260190}
m_Father: {fileID: 1641698562}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &6487795819570424898
Transform:
......@@ -5410,7 +5725,7 @@ Transform:
m_LocalScale: {x: 0.10360218, y: 0.10360218, z: 0.10360218}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1020260190}
m_Father: {fileID: 1641698562}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &6487795819825015281
Transform:
......@@ -5421,11 +5736,11 @@ Transform:
m_GameObject: {fileID: 8621037050799995285}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -2.4947631, y: -5.081241, z: 0}
m_LocalPosition: {x: -2.494763, y: -5.081241, z: 0}
m_LocalScale: {x: 0.10360218, y: 0.10360218, z: 0.10360218}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1020260190}
m_Father: {fileID: 1641698562}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &6487795819872092342
Transform:
......@@ -5440,7 +5755,7 @@ Transform:
m_LocalScale: {x: 0.10360218, y: 0.10360218, z: 0.10360218}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1020260190}
m_Father: {fileID: 1641698562}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &6487795820076689221
Transform:
......@@ -5451,11 +5766,11 @@ Transform:
m_GameObject: {fileID: 8621037051622094625}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -3.1160545, y: -5.081241, z: 0}
m_LocalPosition: {x: -3.1160543, y: -5.081241, z: 0}
m_LocalScale: {x: 0.10360218, y: 0.10360218, z: 0.10360218}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1020260190}
m_Father: {fileID: 1641698562}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &6487795820112505816
Transform:
......@@ -5470,7 +5785,7 @@ Transform:
m_LocalScale: {x: 0.15354612, y: 0.15354612, z: 0.15354612}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1020260190}
m_Father: {fileID: 1641698562}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &6487795820262276379
Transform:
......@@ -5481,11 +5796,11 @@ Transform:
m_GameObject: {fileID: 8621037051438574975}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: -2.3297791, y: -4.8149786, z: 0}
m_LocalPosition: {x: -2.3297791, y: -4.814978, z: 0}
m_LocalScale: {x: 0.2873513, y: 0.2873513, z: 0.2873513}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1020260190}
m_Father: {fileID: 1641698562}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &6487795820311449261
Transform:
......@@ -5500,7 +5815,7 @@ Transform:
m_LocalScale: {x: 0.2873513, y: 0.2873513, z: 0.2873513}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1020260190}
m_Father: {fileID: 1641698562}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &6487795820375087467
Transform:
......@@ -5511,11 +5826,11 @@ Transform:
m_GameObject: {fileID: 8621037052390902031}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0.19551839, y: -4.971252, z: 0}
m_LocalPosition: {x: 0.19551839, y: -4.9712515, z: 0}
m_LocalScale: {x: 0.15354612, y: 0.15354612, z: 0.15354612}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1020260190}
m_Father: {fileID: 1641698562}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &6487795820416849293
Transform:
......@@ -5526,11 +5841,11 @@ Transform:
m_GameObject: {fileID: 8621037052348122601}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 1.4410741, y: -5.081241, z: 0}
m_LocalPosition: {x: 1.441074, y: -5.081241, z: 0}
m_LocalScale: {x: 0.10360218, y: 0.10360218, z: 0.10360218}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1020260190}
m_Father: {fileID: 1641698562}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &6487795820825723704
Transform:
......@@ -5541,11 +5856,11 @@ Transform:
m_GameObject: {fileID: 8621037051935052636}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 1.9196768, y: -4.8149786, z: 0}
m_LocalPosition: {x: 1.9196768, y: -4.814978, z: 0}
m_LocalScale: {x: 0.2873513, y: 0.2873513, z: 0.2873513}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1020260190}
m_Father: {fileID: 1641698562}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!4 &6487795820829508717
Transform:
......@@ -5556,11 +5871,11 @@ Transform:
m_GameObject: {fileID: 8621037051938837513}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 2.659, y: -4.18, z: 0}
m_LocalPosition: {x: 2.6589997, y: -4.1799994, z: 0}
m_LocalScale: {x: 0.59214485, y: 0.59214485, z: 0.59214485}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 1020260190}
m_Father: {fileID: 1641698562}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!58 &7581605641843168290
CircleCollider2D:
......@@ -5982,97 +6297,6 @@ CircleCollider2D:
m_Offset: {x: -0.22, y: 0.01}
serializedVersion: 2
m_Radius: 1.89
--- !u!114 &7826709416159744481
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8621037052390902031}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: a988a7abe4883994ea526b4fb710800b, type: 3}
m_Name:
m_EditorClassIdentifier:
gravityscale: 0.2
--- !u!114 &7826709416274840498
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8621037051935052636}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: a988a7abe4883994ea526b4fb710800b, type: 3}
m_Name:
m_EditorClassIdentifier:
gravityscale: 0.2
--- !u!114 &7826709417016660377
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8621037051064486263}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: a988a7abe4883994ea526b4fb710800b, type: 3}
m_Name:
m_EditorClassIdentifier:
gravityscale: 0.2
--- !u!114 &7826709417281167739
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8621037050799995285}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: a988a7abe4883994ea526b4fb710800b, type: 3}
m_Name:
m_EditorClassIdentifier:
gravityscale: 0.2
--- !u!114 &7826709417532846031
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8621037051622094625}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: a988a7abe4883994ea526b4fb710800b, type: 3}
m_Name:
m_EditorClassIdentifier:
gravityscale: 0.2
--- !u!114 &7826709417737127996
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8621037051820150994}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: a988a7abe4883994ea526b4fb710800b, type: 3}
m_Name:
m_EditorClassIdentifier:
gravityscale: 0.2
--- !u!114 &7826709417834645031
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8621037051387092681}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: a988a7abe4883994ea526b4fb710800b, type: 3}
m_Name:
m_EditorClassIdentifier:
gravityscale: 0.2
--- !u!212 &8551629715879962629
SpriteRenderer:
m_ObjectHideFlags: 0
......@@ -6707,7 +6931,6 @@ GameObject:
m_Component:
- component: {fileID: 6487795819825015281}
- component: {fileID: 8551629717018674585}
- component: {fileID: 7826709417281167739}
- component: {fileID: 7581605642492057099}
m_Layer: 0
m_Name: Rock 8 (4)
......@@ -6744,7 +6967,6 @@ GameObject:
m_Component:
- component: {fileID: 6487795819552119059}
- component: {fileID: 8551629717291578747}
- component: {fileID: 7826709417016660377}
- component: {fileID: 7581605642756040425}
m_Layer: 0
m_Name: Rock 3
......@@ -6763,7 +6985,6 @@ GameObject:
m_Component:
- component: {fileID: 6487795820311449261}
- component: {fileID: 8551629717572166341}
- component: {fileID: 7826709417834645031}
- component: {fileID: 7581605641904763223}
m_Layer: 0
m_Name: Rock 8 (1)
......@@ -6818,7 +7039,6 @@ GameObject:
m_Component:
- component: {fileID: 6487795820076689221}
- component: {fileID: 8551629717807221549}
- component: {fileID: 7826709417532846031}
- component: {fileID: 7581605642206861503}
m_Layer: 0
m_Name: Rock 8 (6)
......@@ -6837,7 +7057,6 @@ GameObject:
m_Component:
- component: {fileID: 6487795819872092342}
- component: {fileID: 8551629717608869086}
- component: {fileID: 7826709417737127996}
- component: {fileID: 7581605642134404940}
m_Layer: 0
m_Name: Rock 8 (7)
......@@ -6856,7 +7075,6 @@ GameObject:
m_Component:
- component: {fileID: 6487795820825723704}
- component: {fileID: 8551629715883519824}
- component: {fileID: 7826709416274840498}
- component: {fileID: 7581605643630279874}
m_Layer: 0
m_Name: Rock 8
......@@ -6911,7 +7129,6 @@ GameObject:
m_Component:
- component: {fileID: 6487795820375087467}
- component: {fileID: 8551629716032140547}
- component: {fileID: 7826709416159744481}
- component: {fileID: 7581605643711260305}
m_Layer: 0
m_Name: Rock 8 (2)
......
......@@ -7,14 +7,16 @@ public class CrackableRock : MonoBehaviour
[SerializeField] Sprite[] crackSprites;
[SerializeField] Button nextButton;
[SerializeField] float moveSpeed = 5f;
private float moveSpeed = 5f;
[SerializeField] Vector2 startOffset = new Vector2(-5f, 10f);
[SerializeField] float rotationSpeed = 360f;
[SerializeField] float shakeDuration = 0.1f;
[SerializeField] float shakeMagnitude = 0.1f;
[SerializeField] GameObject hitEffectPrefab;
[SerializeField] float effectDuration = 1.0f;
private int currentClickCount = 0;
private SpriteRenderer spriteRenderer;
private Vector3 targetPosition;
......@@ -40,15 +42,12 @@ public class CrackableRock : MonoBehaviour
{
if (!canClick)
{
transform.position = Vector3.MoveTowards(transform.position, targetPosition, moveSpeed * Time.deltaTime);
transform.Rotate(Vector3.forward * rotationSpeed * Time.deltaTime);
if (Vector3.Distance(transform.position, targetPosition) < 0.01f)
{
transform.position = targetPosition;
transform.rotation = Quaternion.identity;
canClick = true;
}
}
......@@ -58,6 +57,12 @@ public class CrackableRock : MonoBehaviour
{
if (!canClick) return;
if (hitEffectPrefab != null)
{
GameObject effect = Instantiate(hitEffectPrefab, transform.position, Quaternion.identity);
Destroy(effect, effectDuration);
}
StartCoroutine(ShakeRock());
currentClickCount++;
......@@ -98,6 +103,14 @@ public class CrackableRock : MonoBehaviour
{
if (nextButton != null)
nextButton.interactable = true;
if (hitEffectPrefab != null)
{
GameObject finalEffect = Instantiate(hitEffectPrefab, transform.position, Quaternion.identity);
Destroy(finalEffect, effectDuration);
}
gameObject.SetActive(false);
}
}
\ No newline at end of file
......@@ -4,12 +4,19 @@ using UnityEngine;
public class DestroyMountain : MonoBehaviour
{
[SerializeField] GameObject rockDebrisPrefab;
[Header("Spawning Settings")]
[SerializeField] Transform[] spawnPoints;
[Header("Physical Rock")]
[SerializeField] GameObject rockDebrisPrefab; // The heavy falling rock object
[Header("Visual Effects")]
[SerializeField] GameObject dustEffectPrefab; // <-- DRAG YOUR PARTICLE PREFAB HERE
[SerializeField] float effectDuration = 1.0f; // How long the dust lasts
private float minForce = 1f;
private float maxForce = 3f;
void OnMouseDown()
{
SpawnDebris();
......@@ -17,14 +24,24 @@ public class DestroyMountain : MonoBehaviour
void SpawnDebris()
{
if (rockDebrisPrefab == null) return;
foreach (Transform point in spawnPoints)
{
// --- 1. Spawn the Visual Particle Effect ---
if (dustEffectPrefab != null)
{
GameObject dust = Instantiate(dustEffectPrefab, point.position, Quaternion.identity);
// Clean up the particle system after it finishes
Destroy(dust, effectDuration);
}
// --- 2. Spawn the Physical Rock (Your original code) ---
if (rockDebrisPrefab != null)
{
GameObject rock = Instantiate(rockDebrisPrefab, point.position, Quaternion.identity);
// Optional: Don't parent physical rocks to the mountain if you want them to fall free
rock.transform.SetParent(this.transform);
Rigidbody2D rb = rock.GetComponent<Rigidbody2D>();
if (rb != null)
{
......@@ -36,4 +53,5 @@ public class DestroyMountain : MonoBehaviour
}
}
}
}
}
\ No newline at end of file
using UnityEngine;
using UnityEngine.UI;
using UnityEngine.SceneManagement;
public class ImageSwitcher : MonoBehaviour
{
[Header("Pictures")]
public GameObject[] pictures;
[Header("Buttons")]
public Button nextButton;
public Button restartButton;
private int currentIndex = 0;
void Start()
{
if (pictures.Length > 0)
{
for (int i = 0; i < pictures.Length; i++)
......@@ -18,19 +25,39 @@ public class ImageSwitcher : MonoBehaviour
pictures[0].SetActive(true);
currentIndex = 0;
}
if (restartButton != null)
{
restartButton.gameObject.SetActive(false);
}
if (nextButton != null)
{
nextButton.gameObject.SetActive(true);
}
}
public void NextPicture()
{
if (pictures.Length == 0) return;
pictures[currentIndex].SetActive(false);
currentIndex++;
if (currentIndex >= pictures.Length)
{
currentIndex = 0;
currentIndex = pictures.Length - 1;
}
pictures[currentIndex].SetActive(true);
if (currentIndex == pictures.Length - 1)
{
if (nextButton != null) nextButton.interactable = false;
if (restartButton != null) restartButton.gameObject.SetActive(true);
}
}
public void RestartGame()
{
SceneManager.LoadScene(SceneManager.GetActiveScene().name);
}
}
\ No newline at end of file
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &-6240883434852827896
MonoBehaviour:
m_ObjectHideFlags: 11
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3}
m_Name:
m_EditorClassIdentifier:
version: 7
--- !u!21 &2100000
Material:
serializedVersion: 8
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name: Dust
m_Shader: {fileID: 211, guid: 0000000000000000f000000000000000, type: 0}
m_Parent: {fileID: 0}
m_ModifiedSerializedProperties: 0
m_ValidKeywords:
- _ALPHAPREMULTIPLY_ON
m_InvalidKeywords: []
m_LightmapFlags: 0
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: 3000
stringTagMap:
RenderType: Transparent
disabledShaderPasses:
- GRABPASS
m_LockedProperties:
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
- _BaseMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _BumpMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailAlbedoMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailMask:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _DetailNormalMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _EmissionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MainTex:
m_Texture: {fileID: 2800000, guid: b6dcbefea125f2c4394972710a5d1348, type: 3}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _MetallicGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _OcclusionMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _ParallaxMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- _SpecGlossMap:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_Lightmaps:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_LightmapsInd:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
- unity_ShadowMasks:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _AlphaClip: 0
- _AlphaToMask: 0
- _Blend: 0
- _BlendModePreserveSpecular: 1
- _BlendOp: 0
- _BumpScale: 1
- _CameraFadingEnabled: 0
- _CameraFarFadeDistance: 2
- _CameraNearFadeDistance: 1
- _ClearCoatMask: 0
- _ClearCoatSmoothness: 0
- _ColorMode: 0
- _Cull: 2
- _Cutoff: 0.5
- _DetailAlbedoMapScale: 1
- _DetailNormalMapScale: 1
- _DistortionBlend: 0.5
- _DistortionEnabled: 0
- _DistortionStrength: 1
- _DistortionStrengthScaled: 0
- _DstBlend: 10
- _DstBlendAlpha: 0
- _EmissionEnabled: 0
- _EnvironmentReflections: 1
- _FlipbookMode: 0
- _GlossMapScale: 0
- _Glossiness: 0
- _GlossyReflections: 0
- _LightingEnabled: 0
- _Metallic: 0
- _Mode: 3
- _OcclusionStrength: 1
- _Parallax: 0.005
- _QueueOffset: 0
- _ReceiveShadows: 1
- _Smoothness: 0.5
- _SmoothnessTextureChannel: 0
- _SoftParticlesEnabled: 0
- _SoftParticlesFarFadeDistance: 1
- _SoftParticlesNearFadeDistance: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _SrcBlendAlpha: 1
- _Surface: 0
- _WorkflowMode: 1
- _ZWrite: 0
m_Colors:
- _BaseColor: {r: 1, g: 1, b: 1, a: 1}
- _CameraFadeParams: {r: 0, g: Infinity, b: 0, a: 0}
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _ColorAddSubDiff: {r: 0, g: 0, b: 0, a: 0}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
- _SoftParticleFadeParams: {r: 0, g: 0, b: 0, a: 0}
- _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1}
m_BuildTextureStacks: []
fileFormatVersion: 2
guid: 08780cab1ffe7c44ca036dc8f6f924d3
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 2100000
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: b6dcbefea125f2c4394972710a5d1348
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 13
mipmaps:
mipMapMode: 0
enableMipMap: 0
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
flipGreenChannel: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
vTOnly: 0
ignoreMipmapLimit: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: 1
aniso: 1
mipBias: 0
wrapU: 1
wrapV: 1
wrapW: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 1
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 1
spriteTessellationDetail: -1
textureType: 8
textureShape: 1
singleChannelComponent: 0
flipbookRows: 1
flipbookColumns: 1
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
ignorePngGamma: 0
applyGammaDecoding: 0
swizzle: 50462976
cookieLightType: 0
platformSettings:
- serializedVersion: 3
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Standalone
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Android
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Windows Store Apps
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID: 5e97eb03825dee720800000000000000
internalID: 0
vertices: []
indices:
edges: []
weights: []
secondaryTextures: []
nameFileIdTable: {}
mipmapLimitGroupName:
pSDRemoveMatte: 0
userData:
assetBundleName:
assetBundleVariant:
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment