Commit 79df61ec authored by Max's avatar Max

Added camera shake to transition in level 3

parent a0b0e1d5
......@@ -1984,6 +1984,27 @@ SpriteRenderer:
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
m_SpriteSortPoint: 0
--- !u!1 &53402453 stripped
GameObject:
m_CorrespondingSourceObject: {fileID: 8811539149977030262, guid: 388a7af523fdebaafad4a5d1ae1a896b,
type: 3}
m_PrefabInstance: {fileID: 160780067}
m_PrefabAsset: {fileID: 0}
--- !u!114 &53402454
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 53402453}
m_Enabled: 0
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 06f4b3c3fa5588b4e9006efdbf018d4c, type: 3}
m_Name:
m_EditorClassIdentifier:
shakeDuration: 0
shakeMagnitude: 0.1
dampingSpeed: 1
--- !u!1 &60428865
GameObject:
m_ObjectHideFlags: 0
......@@ -6739,7 +6760,7 @@ PrefabInstance:
type: 3}
propertyPath: m_TargetTexture
value:
objectReference: {fileID: 1347587620}
objectReference: {fileID: 1802061987}
- target: {fileID: 8811539149977030266, guid: 388a7af523fdebaafad4a5d1ae1a896b,
type: 3}
propertyPath: m_LocalPosition.x
......@@ -6815,12 +6836,6 @@ PrefabInstance:
propertyPath: m_LocalPosition.z
value: -54.87268
objectReference: {fileID: 0}
- target: {fileID: 7087328957400987548, guid: 388a7af523fdebaafad4a5d1ae1a896b,
type: 3}
propertyPath: startMusic
value:
objectReference: {fileID: 11400000, guid: e9783148d68ffd945a65ccff65c18f0f,
type: 2}
- target: {fileID: 8811539149977030267, guid: 388a7af523fdebaafad4a5d1ae1a896b,
type: 3}
propertyPath: m_BackGroundColor.r
......@@ -6836,6 +6851,12 @@ PrefabInstance:
propertyPath: m_BackGroundColor.b
value: 0.09411765
objectReference: {fileID: 0}
- target: {fileID: 7087328957400987548, guid: 388a7af523fdebaafad4a5d1ae1a896b,
type: 3}
propertyPath: startMusic
value:
objectReference: {fileID: 11400000, guid: e9783148d68ffd945a65ccff65c18f0f,
type: 2}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 388a7af523fdebaafad4a5d1ae1a896b, type: 3}
--- !u!1 &160911318
......@@ -11253,40 +11274,6 @@ Transform:
type: 3}
m_PrefabInstance: {fileID: 1950253784}
m_PrefabAsset: {fileID: 0}
--- !u!84 &233685161
RenderTexture:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name:
m_ImageContentsHash:
serializedVersion: 2
Hash: 00000000000000000000000000000000
m_ForcedFallbackFormat: 4
m_DownscaleFallback: 0
serializedVersion: 3
m_Width: 1246
m_Height: 579
m_AntiAliasing: 1
m_DepthFormat: 0
m_ColorFormat: 21
m_MipMap: 0
m_GenerateMips: 1
m_SRGB: 0
m_UseDynamicScale: 0
m_BindMS: 0
m_EnableCompatibleFormat: 1
m_TextureSettings:
serializedVersion: 2
m_FilterMode: 1
m_Aniso: 1
m_MipBias: 0
m_WrapU: 1
m_WrapV: 1
m_WrapW: 1
m_Dimension: 2
m_VolumeDepth: 1
--- !u!1 &234978526
GameObject:
m_ObjectHideFlags: 0
......@@ -22084,6 +22071,40 @@ SpriteRenderer:
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
m_SpriteSortPoint: 0
--- !u!84 &457020067
RenderTexture:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name:
m_ImageContentsHash:
serializedVersion: 2
Hash: 00000000000000000000000000000000
m_ForcedFallbackFormat: 4
m_DownscaleFallback: 0
serializedVersion: 3
m_Width: 1575
m_Height: 886
m_AntiAliasing: 1
m_DepthFormat: 0
m_ColorFormat: 21
m_MipMap: 0
m_GenerateMips: 1
m_SRGB: 0
m_UseDynamicScale: 0
m_BindMS: 0
m_EnableCompatibleFormat: 1
m_TextureSettings:
serializedVersion: 2
m_FilterMode: 1
m_Aniso: 1
m_MipBias: 0
m_WrapU: 1
m_WrapV: 1
m_WrapW: 1
m_Dimension: 2
m_VolumeDepth: 1
--- !u!1 &458185292
GameObject:
m_ObjectHideFlags: 0
......@@ -355767,13 +355788,13 @@ Transform:
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 978838716}
m_LocalRotation: {x: -0, y: -0, z: 0.23902455, w: 0.97101355}
m_LocalPosition: {x: -76.4, y: 40.57, z: 0}
m_LocalRotation: {x: 0, y: 0, z: 0.37136775, w: 0.9284859}
m_LocalPosition: {x: -78.47, y: 38.07, z: 0}
m_LocalScale: {x: 0.5, y: 0.5, z: 1}
m_Children: []
m_Father: {fileID: 787591415}
m_RootOrder: 22
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 27.658}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 43.6}
--- !u!212 &978838718
SpriteRenderer:
m_ObjectHideFlags: 0
......@@ -357842,6 +357863,23 @@ MonoBehaviour:
m_EditorClassIdentifier:
light: {fileID: 137365452}
save: {fileID: 11400000, guid: 2b99c830cf6b3ab468f7b160e4625661, type: 2}
camShake: {fileID: 53402454}
cameraShake:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 53402454}
m_MethodName: StartShake
m_Mode: 4
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 3
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
m_TypeName: UnityEngine.Events.UnityEvent, UnityEngine.CoreModule, Version=0.0.0.0,
Culture=neutral, PublicKeyToken=null
--- !u!1 &1021344563
GameObject:
m_ObjectHideFlags: 0
......@@ -375471,40 +375509,6 @@ SpriteRenderer:
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
m_SpriteSortPoint: 0
--- !u!84 &1347587620
RenderTexture:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name:
m_ImageContentsHash:
serializedVersion: 2
Hash: 00000000000000000000000000000000
m_ForcedFallbackFormat: 4
m_DownscaleFallback: 0
serializedVersion: 3
m_Width: 1246
m_Height: 579
m_AntiAliasing: 1
m_DepthFormat: 0
m_ColorFormat: 21
m_MipMap: 0
m_GenerateMips: 1
m_SRGB: 0
m_UseDynamicScale: 0
m_BindMS: 0
m_EnableCompatibleFormat: 1
m_TextureSettings:
serializedVersion: 2
m_FilterMode: 1
m_Aniso: 1
m_MipBias: 0
m_WrapU: 1
m_WrapV: 1
m_WrapW: 1
m_Dimension: 2
m_VolumeDepth: 1
--- !u!1 &1350962890
GameObject:
m_ObjectHideFlags: 0
......@@ -430251,6 +430255,40 @@ SpriteRenderer:
m_WasSpriteAssigned: 1
m_MaskInteraction: 0
m_SpriteSortPoint: 0
--- !u!84 &1802061987
RenderTexture:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_Name:
m_ImageContentsHash:
serializedVersion: 2
Hash: 00000000000000000000000000000000
m_ForcedFallbackFormat: 4
m_DownscaleFallback: 0
serializedVersion: 3
m_Width: 1575
m_Height: 886
m_AntiAliasing: 1
m_DepthFormat: 0
m_ColorFormat: 21
m_MipMap: 0
m_GenerateMips: 1
m_SRGB: 0
m_UseDynamicScale: 0
m_BindMS: 0
m_EnableCompatibleFormat: 1
m_TextureSettings:
serializedVersion: 2
m_FilterMode: 1
m_Aniso: 1
m_MipBias: 0
m_WrapU: 1
m_WrapV: 1
m_WrapW: 1
m_Dimension: 2
m_VolumeDepth: 1
--- !u!1 &1802500467
GameObject:
m_ObjectHideFlags: 0
......@@ -15,9 +15,14 @@ public class Objective2 : MonoBehaviour
private bool done;
private void Awake()
{
done = false;
}
private void OnTriggerEnter2D(Collider2D collision)
{
if(collision.gameObject == stone)
if(collision.gameObject == stone && !done)
{
camShake.enabled = true;
cameraShake.Invoke();
......
......@@ -14,10 +14,15 @@ public class Objective3 : MonoBehaviour
private bool done;
private void Awake()
{
done = false;
}
// Update is called once per frame
void Update()
{
if(!light.activeSelf)
if(!light.activeSelf && !done)
{
camShake.enabled = true;
cameraShake.Invoke();
......
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