diff --git a/Assets/InGame/Bonus.meta b/Assets/InGame/Bonus.meta new file mode 100644 index 0000000..c939b6c --- /dev/null +++ b/Assets/InGame/Bonus.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d86eaf29c66425d47ae48f8a670ab059 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/InGame/Bonus/boost.png b/Assets/InGame/Bonus/boost.png new file mode 100644 index 0000000..b98a564 Binary files /dev/null and b/Assets/InGame/Bonus/boost.png differ diff --git a/Assets/InGame/Bonus/boost.png.meta b/Assets/InGame/Bonus/boost.png.meta new file mode 100644 index 0000000..6b7583f --- /dev/null +++ b/Assets/InGame/Bonus/boost.png.meta @@ -0,0 +1,143 @@ +fileFormatVersion: 2 +guid: 33864bce9eacb70409917071a77c9a4d +TextureImporter: + internalIDToNameTable: + - first: + 213: -7343618574588220523 + second: boost_boosting_performance_fast_game-512_0 + 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: 2 + 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: 4 + 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: 4 + 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 + spriteSheet: + serializedVersion: 2 + sprites: + - serializedVersion: 2 + name: boost_boosting_performance_fast_game-512_0 + rect: + serializedVersion: 2 + x: 0 + y: 0 + width: 512 + height: 512 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + customData: + outline: [] + physicsShape: [] + tessellationDetail: -1 + bones: [] + spriteID: 59b65b780d9361a90800000000000000 + internalID: -7343618574588220523 + vertices: [] + indices: + edges: [] + weights: [] + outline: [] + customData: + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spriteCustomMetadata: + entries: [] + nameFileIdTable: + boost_boosting_performance_fast_game-512_0: -7343618574588220523 + mipmapLimitGroupName: + pSDRemoveMatte: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/InGame/Bonus/light-speed.png b/Assets/InGame/Bonus/light-speed.png new file mode 100644 index 0000000..ef2bc88 Binary files /dev/null and b/Assets/InGame/Bonus/light-speed.png differ diff --git a/Assets/InGame/Bonus/light-speed.png.meta b/Assets/InGame/Bonus/light-speed.png.meta new file mode 100644 index 0000000..871b7a9 --- /dev/null +++ b/Assets/InGame/Bonus/light-speed.png.meta @@ -0,0 +1,142 @@ +fileFormatVersion: 2 +guid: ec309b6331938a340a7154aff62f824a +TextureImporter: + internalIDToNameTable: + - first: + 213: -6584411455828649921 + second: light-speed_0 + 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: 2 + 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: 4 + 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: 4 + 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 + spriteSheet: + serializedVersion: 2 + sprites: + - serializedVersion: 2 + name: light-speed_0 + rect: + serializedVersion: 2 + x: 97 + y: 0 + width: 344 + height: 500 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + customData: + outline: [] + physicsShape: [] + tessellationDetail: -1 + bones: [] + spriteID: f381258aaa87f94a0800000000000000 + internalID: -6584411455828649921 + vertices: [] + indices: + edges: [] + weights: [] + outline: [] + customData: + physicsShape: [] + bones: [] + spriteID: + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + spriteCustomMetadata: + entries: [] + nameFileIdTable: {} + mipmapLimitGroupName: + pSDRemoveMatte: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Resources/Prefabs/BonusBoostSpeed.prefab b/Assets/Resources/Prefabs/BonusBoostSpeed.prefab new file mode 100644 index 0000000..9cc0998 --- /dev/null +++ b/Assets/Resources/Prefabs/BonusBoostSpeed.prefab @@ -0,0 +1,136 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &3025146551836412649 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 7134261581051338486} + - component: {fileID: 1952104245617686462} + - component: {fileID: 6981249288018748244} + m_Layer: 0 + m_Name: BonusBoostSpeed + m_TagString: BonusBoostSpeed + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &7134261581051338486 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3025146551836412649} + serializedVersion: 2 + m_LocalRotation: {x: -0, y: -0, z: -0.079757296, w: 0.99681437} + m_LocalPosition: {x: -9.55, y: -2.88, z: 0} + m_LocalScale: {x: 0.2, y: 0.3, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 0} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: -9.149} +--- !u!212 &1952104245617686462 +SpriteRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3025146551836412649} + 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_RayTracingAccelStructBuildFlagsOverride: 0 + m_RayTracingAccelStructBuildFlags: 1 + m_SmallMeshCulling: 1 + 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: -7343618574588220523, guid: 33864bce9eacb70409917071a77c9a4d, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 + m_DrawMode: 0 + m_Size: {x: 5.12, y: 5.12} + m_AdaptiveModeThreshold: 0.5 + m_SpriteTileMode: 0 + m_WasSpriteAssigned: 1 + m_MaskInteraction: 0 + m_SpriteSortPoint: 0 +--- !u!61 &6981249288018748244 +BoxCollider2D: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3025146551836412649} + m_Enabled: 1 + serializedVersion: 3 + 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_CompositeOperation: 0 + m_CompositeOrder: 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: 5.12, y: 5.12} + newSize: {x: 5.12, y: 5.12} + adaptiveTilingThreshold: 0.5 + drawMode: 0 + adaptiveTiling: 0 + m_AutoTiling: 0 + m_Size: {x: 5.12, y: 5.12} + m_EdgeRadius: 0 diff --git a/Assets/Resources/Prefabs/BonusBoostSpeed.prefab.meta b/Assets/Resources/Prefabs/BonusBoostSpeed.prefab.meta new file mode 100644 index 0000000..1bb0c0a --- /dev/null +++ b/Assets/Resources/Prefabs/BonusBoostSpeed.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 5d01d2d55c6c25541b0db90186e76c2b +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Resources/Prefabs/BonusSlowSpeed.prefab b/Assets/Resources/Prefabs/BonusSlowSpeed.prefab new file mode 100644 index 0000000..d1cccfe --- /dev/null +++ b/Assets/Resources/Prefabs/BonusSlowSpeed.prefab @@ -0,0 +1,136 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &1771296619209216840 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 6543394447596783970} + - component: {fileID: 6172525484934886487} + - component: {fileID: 8050669973533160177} + m_Layer: 0 + m_Name: BonusSlowSpeed + m_TagString: BonusSlowSpeed + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &6543394447596783970 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1771296619209216840} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -7.15, y: -2.93, z: 0} + m_LocalScale: {x: 0.2, y: 0.3, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 0} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!212 &6172525484934886487 +SpriteRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1771296619209216840} + 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_RayTracingAccelStructBuildFlagsOverride: 0 + m_RayTracingAccelStructBuildFlags: 1 + m_SmallMeshCulling: 1 + 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: -6584411455828649921, guid: ec309b6331938a340a7154aff62f824a, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 + m_DrawMode: 0 + m_Size: {x: 3.44, y: 5} + m_AdaptiveModeThreshold: 0.5 + m_SpriteTileMode: 0 + m_WasSpriteAssigned: 1 + m_MaskInteraction: 0 + m_SpriteSortPoint: 0 +--- !u!61 &8050669973533160177 +BoxCollider2D: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1771296619209216840} + m_Enabled: 1 + serializedVersion: 3 + 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_CompositeOperation: 0 + m_CompositeOrder: 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: 3.44, y: 5} + newSize: {x: 3.44, y: 5} + adaptiveTilingThreshold: 0.5 + drawMode: 0 + adaptiveTiling: 0 + m_AutoTiling: 0 + m_Size: {x: 3.44, y: 5} + m_EdgeRadius: 0 diff --git a/Assets/Resources/Prefabs/BonusSlowSpeed.prefab.meta b/Assets/Resources/Prefabs/BonusSlowSpeed.prefab.meta new file mode 100644 index 0000000..82d44ea --- /dev/null +++ b/Assets/Resources/Prefabs/BonusSlowSpeed.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: e9dda45aef9258745a40efb48437d584 +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scenes/LevelScene.unity b/Assets/Scenes/LevelScene.unity index ca5e2a5..fc582f1 100644 --- a/Assets/Scenes/LevelScene.unity +++ b/Assets/Scenes/LevelScene.unity @@ -119,6 +119,63 @@ NavMeshSettings: debug: m_Flags: 0 m_NavMeshData: {fileID: 0} +--- !u!1001 &109370708 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + serializedVersion: 3 + m_TransformParent: {fileID: 0} + m_Modifications: + - target: {fileID: 1771296619209216840, guid: e9dda45aef9258745a40efb48437d584, type: 3} + propertyPath: m_Name + value: BonusSlowSpeed + objectReference: {fileID: 0} + - target: {fileID: 6543394447596783970, guid: e9dda45aef9258745a40efb48437d584, type: 3} + propertyPath: m_LocalPosition.x + value: -5.4423084 + objectReference: {fileID: 0} + - target: {fileID: 6543394447596783970, guid: e9dda45aef9258745a40efb48437d584, type: 3} + propertyPath: m_LocalPosition.y + value: -2.783749 + objectReference: {fileID: 0} + - target: {fileID: 6543394447596783970, guid: e9dda45aef9258745a40efb48437d584, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6543394447596783970, guid: e9dda45aef9258745a40efb48437d584, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 6543394447596783970, guid: e9dda45aef9258745a40efb48437d584, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6543394447596783970, guid: e9dda45aef9258745a40efb48437d584, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6543394447596783970, guid: e9dda45aef9258745a40efb48437d584, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6543394447596783970, guid: e9dda45aef9258745a40efb48437d584, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6543394447596783970, guid: e9dda45aef9258745a40efb48437d584, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6543394447596783970, guid: e9dda45aef9258745a40efb48437d584, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_RemovedGameObjects: [] + m_AddedGameObjects: [] + m_AddedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: e9dda45aef9258745a40efb48437d584, type: 3} --- !u!1 &245275147 GameObject: m_ObjectHideFlags: 0 @@ -462,6 +519,93 @@ Transform: m_Children: [] m_Father: {fileID: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &555497621 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 555497623} + - component: {fileID: 555497622} + m_Layer: 0 + m_Name: fast-snail-icon-260nw-362961314_0 + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!212 &555497622 +SpriteRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 555497621} + 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_RayTracingAccelStructBuildFlagsOverride: 0 + m_RayTracingAccelStructBuildFlags: 1 + m_SmallMeshCulling: 1 + 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: 825135493147237694, guid: 0b136728a8cfd9e49a97d46b7c0eac23, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 + m_DrawMode: 0 + m_Size: {x: 4.52, y: 2.8} + m_AdaptiveModeThreshold: 0.5 + m_SpriteTileMode: 0 + m_WasSpriteAssigned: 0 + m_MaskInteraction: 0 + m_SpriteSortPoint: 0 +--- !u!4 &555497623 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 555497621} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -8.23, y: -1.56, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 0} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &613701312 GameObject: m_ObjectHideFlags: 0 @@ -5553,7 +5697,7 @@ Transform: m_GameObject: {fileID: 1011717286} serializedVersion: 2 m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} - m_LocalPosition: {x: 0.04, y: -0.09, z: 100} + m_LocalPosition: {x: 0.04, y: -0.05, z: 100} m_LocalScale: {x: 5.1, y: 5.1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] @@ -6046,6 +6190,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: ebe0bd74200510d4aa75c327a76499c6, type: 3} m_Name: m_EditorClassIdentifier: + SpeedMultiplier: 1 --- !u!61 &1267397460 BoxCollider2D: m_ObjectHideFlags: 0 @@ -7164,3 +7309,5 @@ SceneRoots: - {fileID: 1999482187} - {fileID: 1371294550} - {fileID: 521952202} + - {fileID: 555497623} + - {fileID: 109370708} diff --git a/Assets/Scripts/GameMode/NormalGameMode.cs b/Assets/Scripts/GameMode/NormalGameMode.cs index 9fa63e3..b266e2c 100644 --- a/Assets/Scripts/GameMode/NormalGameMode.cs +++ b/Assets/Scripts/GameMode/NormalGameMode.cs @@ -9,7 +9,7 @@ public class NormalGameMode : IGameMode public void Update(Player player) { - player.RigidBody.linearVelocity = new Vector2(HorizontalSpeed, player.RigidBody.linearVelocity.y); + player.RigidBody.linearVelocity = new Vector2(HorizontalSpeed * player.SpeedMultiplier, player.RigidBody.linearVelocity.y); if (player.HasStarted && player.IsColliding && Input.GetKey(JumpKey) && player.CanJump) { diff --git a/Assets/Scripts/GameMode/ShipGameMode.cs b/Assets/Scripts/GameMode/ShipGameMode.cs index ece7857..5838a61 100644 --- a/Assets/Scripts/GameMode/ShipGameMode.cs +++ b/Assets/Scripts/GameMode/ShipGameMode.cs @@ -12,7 +12,7 @@ public class ShipGameMode : IGameMode public void Update(Player player) { - player.RigidBody.linearVelocity = new Vector2(HorizontalSpeed, player.RigidBody.linearVelocity.y); + player.RigidBody.linearVelocity = new Vector2(HorizontalSpeed * player.SpeedMultiplier, player.RigidBody.linearVelocity.y); bool jumpPressed = Input.GetKey(JumpKey); diff --git a/Assets/Scripts/Player.cs b/Assets/Scripts/Player.cs index 3064cc1..d00cc99 100644 --- a/Assets/Scripts/Player.cs +++ b/Assets/Scripts/Player.cs @@ -13,6 +13,7 @@ public class Player : MonoBehaviour public bool CanJump { get; set; } = true; public IGameMode CurrentGameMode { get; set; } + public float SpeedMultiplier = 1f; public void Awake() { @@ -67,6 +68,16 @@ public class Player : MonoBehaviour SpriteRenderer.sprite = Resources.Load<Sprite>("Shapes/BaseSquare"); ChangeGameMode(new NormalGameMode()); } + else if (collision.CompareTag("BonusBoostSpeed")) + { + SpeedMultiplier *= 1.5f; + Destroy(collision.gameObject); + } + else if (collision.CompareTag("BonusSlowSpeed")) + { + SpeedMultiplier /= 1.5f; + Destroy(collision.gameObject); + } } public void ChangeGameMode(IGameMode newMode) diff --git a/ProjectSettings/TagManager.asset b/ProjectSettings/TagManager.asset index 487363c..6fa217a 100644 --- a/ProjectSettings/TagManager.asset +++ b/ProjectSettings/TagManager.asset @@ -8,6 +8,10 @@ TagManager: - Win - LevelsLoader - LevelLoader + - CubePortal + - ShipPortal + - BonusBoostSpeed + - BonusSlowSpeed layers: - Default - TransparentFX