Compare commits

..

No commits in common. "dev" and "SKIN" have entirely different histories.
dev ... SKIN

55 changed files with 3500 additions and 7808 deletions

Binary file not shown.

Binary file not shown.

View File

@ -51,5 +51,5 @@
"temp/": true,
"Temp/": true
},
"dotnet.defaultSolution": "AwesomeRunner-.sln"
"dotnet.defaultSolution": "AwesomeRunner.sln"
}

View File

@ -9,8 +9,6 @@ Material:
m_PrefabAsset: {fileID: 0}
m_Name: m_jammo_metal 1
m_Shader: {fileID: 4800000, guid: 73ef4de7c429719438a73d771100db7c, type: 3}
m_Parent: {fileID: 0}
m_ModifiedSerializedProperties: 0
m_ValidKeywords: []
m_InvalidKeywords:
- _METALLICGLOSSMAP
@ -21,7 +19,6 @@ Material:
m_CustomRenderQueue: -1
stringTagMap: {}
disabledShaderPasses: []
m_LockedProperties:
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
@ -88,4 +85,3 @@ Material:
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
m_BuildTextureStacks: []
m_AllowLocking: 1

View File

@ -2,26 +2,19 @@
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
serializedVersion: 6
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_Name: comuter_wall
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
m_Parent: {fileID: 0}
m_ModifiedSerializedProperties: 0
m_ValidKeywords:
- _EMISSION
- _METALLICGLOSSMAP
m_InvalidKeywords: []
m_LightmapFlags: 1
m_ShaderKeywords: _METALLICGLOSSMAP
m_LightmapFlags: 5
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap: {}
disabledShaderPasses: []
m_LockedProperties:
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
@ -61,26 +54,19 @@ Material:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _BumpScale: 1
- _Cutoff: 0.5
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _GlossMapScale: 1
- _Glossiness: 0.5
- _GlossyReflections: 1
- _Metallic: 0
- _Mode: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _UVSec: 0
- _ZWrite: 1
m_Colors:
- _Color: {r: 0.8, g: 0.8, b: 0.8, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
m_BuildTextureStacks: []
m_AllowLocking: 1

View File

@ -2,25 +2,19 @@
%TAG !u! tag:unity3d.com,2011:
--- !u!21 &2100000
Material:
serializedVersion: 8
serializedVersion: 6
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_PrefabInternal: {fileID: 0}
m_Name: No Name
m_Shader: {fileID: 46, guid: 0000000000000000f000000000000000, type: 0}
m_Parent: {fileID: 0}
m_ModifiedSerializedProperties: 0
m_ValidKeywords:
- _EMISSION
m_InvalidKeywords: []
m_LightmapFlags: 1
m_ShaderKeywords:
m_LightmapFlags: 5
m_EnableInstancingVariants: 0
m_DoubleSidedGI: 0
m_CustomRenderQueue: -1
stringTagMap: {}
disabledShaderPasses: []
m_LockedProperties:
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:
@ -60,26 +54,19 @@ Material:
m_Texture: {fileID: 0}
m_Scale: {x: 1, y: 1}
m_Offset: {x: 0, y: 0}
m_Ints: []
m_Floats:
- _BumpScale: 1
- _Cutoff: 0.5
- _DetailNormalMapScale: 1
- _DstBlend: 0
- _GlossMapScale: 1
- _Glossiness: 0.5
- _GlossyReflections: 1
- _Metallic: 0
- _Mode: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1
- _UVSec: 0
- _ZWrite: 1
m_Colors:
- _Color: {r: 1, g: 1, b: 1, a: 1}
- _EmissionColor: {r: 0, g: 0, b: 0, a: 1}
m_BuildTextureStacks: []
m_AllowLocking: 1

View File

@ -8,8 +8,7 @@ public class laserScript : MonoBehaviour {
// Use this for initialization
void Start () {
laserLine = GetComponentInChildren<LineRenderer> ();
laserLine.startWidth = .2f;
laserLine.endWidth = .2f;
laserLine.SetWidth (.2f, .2f);
}
// Update is called once per frame

View File

@ -1,8 +0,0 @@
fileFormatVersion: 2
guid: aa7ee8fd100668c43a4a6598a35a3ad6
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,163 +0,0 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &9117726010709451998
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2262208576908815080}
- component: {fileID: 3572880127954793139}
- component: {fileID: 6612934893704467973}
- component: {fileID: 2619330802336550126}
- component: {fileID: 6803980266743182291}
- component: {fileID: 6108635676596831665}
- component: {fileID: 1187001800563073841}
m_Layer: 0
m_Name: Coins
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &2262208576908815080
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9117726010709451998}
serializedVersion: 2
m_LocalRotation: {x: 0.7071068, y: 0, z: 0, w: 0.7071068}
m_LocalPosition: {x: 0, y: 2, z: 0}
m_LocalScale: {x: 1, y: 0.05, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0}
--- !u!33 &3572880127954793139
MeshFilter:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9117726010709451998}
m_Mesh: {fileID: 10206, guid: 0000000000000000e000000000000000, type: 0}
--- !u!23 &6612934893704467973
MeshRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9117726010709451998}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_DynamicOccludee: 1
m_StaticShadowCaster: 0
m_MotionVectors: 1
m_LightProbeUsage: 1
m_ReflectionProbeUsage: 1
m_RayTracingMode: 2
m_RayTraceProcedural: 0
m_RayTracingAccelStructBuildFlagsOverride: 0
m_RayTracingAccelStructBuildFlags: 1
m_SmallMeshCulling: 1
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 9fc1d0d62308b2a47839d64bc3a4983d, type: 2}
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: 3
m_MinimumChartSize: 4
m_AutoUVMaxDistance: 0.5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_AdditionalVertexStreams: {fileID: 0}
--- !u!136 &2619330802336550126
CapsuleCollider:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9117726010709451998}
m_Material: {fileID: 0}
m_IncludeLayers:
serializedVersion: 2
m_Bits: 0
m_ExcludeLayers:
serializedVersion: 2
m_Bits: 0
m_LayerOverridePriority: 0
m_IsTrigger: 1
m_ProvidesContacts: 0
m_Enabled: 1
serializedVersion: 2
m_Radius: 0.5000001
m_Height: 2
m_Direction: 1
m_Center: {x: 0.000000059604645, y: 0, z: -0.00000008940697}
--- !u!65 &6803980266743182291
BoxCollider:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9117726010709451998}
m_Material: {fileID: 0}
m_IncludeLayers:
serializedVersion: 2
m_Bits: 0
m_ExcludeLayers:
serializedVersion: 2
m_Bits: 0
m_LayerOverridePriority: 0
m_IsTrigger: 1
m_ProvidesContacts: 0
m_Enabled: 1
serializedVersion: 3
m_Size: {x: 1.0000001, y: 2.0000005, z: 1.0000005}
m_Center: {x: 0.000000059604645, y: 0, z: -0.00000008940699}
--- !u!114 &6108635676596831665
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9117726010709451998}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: ddaf0a1f90e1c46428ba5f029fd32ad0, type: 3}
m_Name:
m_EditorClassIdentifier:
coinValue: 1
--- !u!114 &1187001800563073841
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 9117726010709451998}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: ef8880022572d924bbe4f58655a16a6f, type: 3}
m_Name:
m_EditorClassIdentifier:
amplitude: 0.1
animationVelocity: {x: 0, y: 1, z: 0}

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: b23a39661488b4b4bb909b4285f3f874
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -104,7 +104,7 @@ BoxCollider:
m_Enabled: 1
serializedVersion: 3
m_Size: {x: 2, y: 2, z: 2}
m_Center: {x: 0, y: 0.5, z: 0}
m_Center: {x: 0, y: 0, z: 0}
--- !u!114 &6632165759313513218
MonoBehaviour:
m_ObjectHideFlags: 0
@ -230,8 +230,8 @@ BoxCollider:
m_ProvidesContacts: 0
m_Enabled: 1
serializedVersion: 3
m_Size: {x: 2, y: 1.75, z: 2}
m_Center: {x: 0, y: 2.25, z: 0}
m_Size: {x: 2, y: 2, z: 2}
m_Center: {x: 0, y: 0, z: 0}
--- !u!114 &-5363852902891024896
MonoBehaviour:
m_ObjectHideFlags: 0
@ -245,7 +245,7 @@ MonoBehaviour:
m_Name:
m_EditorClassIdentifier:
<IsOnAllLanes>k__BackingField: 0
<IsInevitable>k__BackingField: 0
<IsInevitable>k__BackingField: 1
--- !u!4 &4156031263124959724 stripped
Transform:
m_CorrespondingSourceObject: {fileID: -4216859302048453862, guid: 02c07866f16913044aea6679ce17cfc5, type: 3}

View File

@ -24,13 +24,13 @@ Transform:
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1385490266177085035}
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: []
m_Father: {fileID: 0}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &3244299530156243158
MonoBehaviour:
@ -44,5 +44,5 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 1290664e863a3d34596917f255587b4c, type: 3}
m_Name:
m_EditorClassIdentifier:
capacity: 10
capacity: 30
prefab: {fileID: 6716018880928220119, guid: aa7da947970bb714fa7924d204fe2bdd, type: 3}

View File

@ -24,13 +24,13 @@ Transform:
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4737509690352194895}
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: []
m_Father: {fileID: 0}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &6300939898152622968
MonoBehaviour:
@ -44,5 +44,5 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 1290664e863a3d34596917f255587b4c, type: 3}
m_Name:
m_EditorClassIdentifier:
capacity: 10
capacity: 20
prefab: {fileID: 6716018880928220119, guid: aa7da947970bb714fa7924d204fe2bdd, type: 3}

View File

@ -1,8 +0,0 @@
fileFormatVersion: 2
guid: 723c7ecb1f81a8c47a6c3853e476b507
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,48 +0,0 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &7658440756881775109
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2738643474112209314}
- component: {fileID: 8935043373779239955}
m_Layer: 0
m_Name: CoinPool
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &2738643474112209314
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7658440756881775109}
serializedVersion: 2
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 3.7201803, y: -0.29014507, z: 29.534254}
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!114 &8935043373779239955
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7658440756881775109}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: c4456a434a6301241bcca08c705b96c4, type: 3}
m_Name:
m_EditorClassIdentifier:
capacity: 0
prefab: {fileID: 6108635676596831665, guid: b23a39661488b4b4bb909b4285f3f874, type: 3}

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: 44cf83f237ca73248933ea3c97149a4a
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -132,7 +132,6 @@ GameObject:
- component: {fileID: 28337888}
- component: {fileID: 28337887}
- component: {fileID: 28337891}
- component: {fileID: 28337892}
m_Layer: 5
m_Name: Canvas
m_TagString: Untagged
@ -241,23 +240,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 5827ef60d322c73468e816b5411af65a, type: 3}
m_Name:
m_EditorClassIdentifier:
restartButton: {fileID: 344149856}
--- !u!114 &28337892
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 28337886}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 80d0e44a44be4982a77850a10cbae2f9, type: 3}
m_Name:
m_EditorClassIdentifier:
Joueur1Text: {fileID: 0}
Joueur2Text: {fileID: 0}
CoinsText: {fileID: 142150283}
ScoreText: {fileID: 2089165862}
restartButton: {fileID: 0}
--- !u!1 &117032977
GameObject:
m_ObjectHideFlags: 0
@ -841,6 +824,7 @@ GameObject:
m_Component:
- component: {fileID: 934295242}
- component: {fileID: 934295243}
- component: {fileID: 934295244}
m_Layer: 0
m_Name: GameManager
m_TagString: Untagged
@ -875,6 +859,23 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 90560e670cf9430d920225316b227914, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!114 &934295244
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 934295239}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 2278264f81ffe464da1a99450675b475, type: 3}
m_Name:
m_EditorClassIdentifier:
distanceText: {fileID: 2089165862}
numberCoinsText: {fileID: 142150283}
joueur1Text: {fileID: 0}
joueur2Text: {fileID: 0}
is1v1Mode: 0
--- !u!1 &963194225
GameObject:
m_ObjectHideFlags: 0
@ -1051,10 +1052,7 @@ PrefabInstance:
propertyPath: PlayerHUD
value:
objectReference: {fileID: 0}
m_RemovedComponents:
- {fileID: 7509186232753540492, guid: 01fa89ab9028c864b8560621b7d51f50, type: 3}
- {fileID: 7896966939631641298, guid: 01fa89ab9028c864b8560621b7d51f50, type: 3}
- {fileID: 6456075115708800826, guid: 01fa89ab9028c864b8560621b7d51f50, type: 3}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects: []
m_AddedComponents: []

View File

@ -223,7 +223,6 @@ RectTransform:
- {fileID: 403573104}
- {fileID: 64039522}
- {fileID: 2043114201}
- {fileID: 532731930}
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
@ -245,8 +244,6 @@ MonoBehaviour:
m_EditorClassIdentifier:
Joueur1Text: {fileID: 1628274878}
Joueur2Text: {fileID: 1398225804}
CoinsText: {fileID: 403573105}
ScoreText: {fileID: 393375357}
--- !u!1 &64039521
GameObject:
m_ObjectHideFlags: 0
@ -655,78 +652,6 @@ CanvasRenderer:
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 403573103}
m_CullTransparentMesh: 1
--- !u!1 &532731929
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 532731930}
- component: {fileID: 532731932}
- component: {fileID: 532731931}
m_Layer: 5
m_Name: RawImage (1)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &532731930
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 532731929}
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: []
m_Father: {fileID: 28337890}
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: 261, y: -23.000015}
m_SizeDelta: {x: 215.7859, y: 189.79}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &532731931
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 532731929}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 1344c3c82d62a2a41a3576d8abb8e3ea, 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_Texture: {fileID: 8400000, guid: 41143e46b20d229409d956aa790eeadf, type: 2}
m_UVRect:
serializedVersion: 2
x: 0
y: 0
width: 1
height: 1
--- !u!222 &532731932
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 532731929}
m_CullTransparentMesh: 1
--- !u!1 &533191355
GameObject:
m_ObjectHideFlags: 0
@ -737,6 +662,7 @@ GameObject:
m_Component:
- component: {fileID: 533191358}
- component: {fileID: 533191359}
- component: {fileID: 533191360}
m_Layer: 0
m_Name: GameManager
m_TagString: Untagged
@ -771,6 +697,23 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 90560e670cf9430d920225316b227914, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!114 &533191360
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 533191355}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 2278264f81ffe464da1a99450675b475, type: 3}
m_Name:
m_EditorClassIdentifier:
distanceText: {fileID: 393375357}
numberCoinsText: {fileID: 403573105}
joueur1Text: {fileID: 1628274878}
joueur2Text: {fileID: 1398225804}
is1v1Mode: 1
--- !u!1 &565350509
GameObject:
m_ObjectHideFlags: 0
@ -1754,10 +1697,7 @@ PrefabInstance:
propertyPath: PlayerHUD
value:
objectReference: {fileID: 0}
m_RemovedComponents:
- {fileID: 7509186232753540492, guid: 01fa89ab9028c864b8560621b7d51f50, type: 3}
- {fileID: 7896966939631641298, guid: 01fa89ab9028c864b8560621b7d51f50, type: 3}
- {fileID: 6456075115708800826, guid: 01fa89ab9028c864b8560621b7d51f50, type: 3}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects: []
m_AddedComponents: []
@ -2163,7 +2103,7 @@ RectTransform:
m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: -267, y: -23.000015}
m_SizeDelta: {x: 215.7859, y: 189.79}
m_SizeDelta: {x: 215.7859, y: 191.7685}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &2043114202
MonoBehaviour:

View File

@ -335,7 +335,6 @@ MonoBehaviour:
player2: {fileID: 2249596435903131710}
scoreboard: {fileID: 634835458}
isDuoMode: 1
playerData: {fileID: 11400000, guid: 928d6efd735c3814d955e3f955a0264a, type: 2}
--- !u!4 &70882853
Transform:
m_ObjectHideFlags: 0
@ -407,7 +406,7 @@ GameObject:
- component: {fileID: 100036930}
- component: {fileID: 100036929}
- component: {fileID: 100036928}
m_Layer: 3
m_Layer: 5
m_Name: Back
m_TagString: Untagged
m_Icon: {fileID: 0}
@ -573,7 +572,7 @@ GameObject:
- component: {fileID: 139585262}
- component: {fileID: 139585263}
- component: {fileID: 139585264}
m_Layer: 3
m_Layer: 5
m_Name: Content
m_TagString: Untagged
m_Icon: {fileID: 0}
@ -596,7 +595,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: -0.000050159586, y: -0.0000038146973}
m_AnchoredPosition: {x: -0.000050159586, y: 0.0000019978345}
m_SizeDelta: {x: 0, y: 0}
m_Pivot: {x: 0, y: 1}
--- !u!114 &139585263
@ -648,7 +647,7 @@ GameObject:
serializedVersion: 6
m_Component:
- component: {fileID: 178371325}
m_Layer: 3
m_Layer: 5
m_Name: Sliding Area
m_TagString: Untagged
m_Icon: {fileID: 0}
@ -807,7 +806,7 @@ RectTransform:
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 220002225}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 46.84}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
@ -852,8 +851,8 @@ Transform:
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 1791311983}
- {fileID: 1858832248}
- {fileID: 1791311983}
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &377940177
@ -1008,7 +1007,7 @@ GameObject:
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
m_IsActive: 0
--- !u!224 &552140505
RectTransform:
m_ObjectHideFlags: 0
@ -1236,7 +1235,7 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: 0, y: -262}
m_AnchoredPosition: {x: 11.384, y: 280}
m_SizeDelta: {x: 122.7673, y: 34.7875}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &772101543
@ -1259,9 +1258,7 @@ MonoBehaviour:
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: '
'
m_text: New Text
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
@ -1310,7 +1307,7 @@ MonoBehaviour:
m_linkedTextComponent: {fileID: 0}
parentLinkedComponent: {fileID: 0}
m_enableKerning: 1
m_ActiveFontFeatures: 6e72656b
m_ActiveFontFeatures: 00000000
m_enableExtraPadding: 0
checkPaddingRequired: 0
m_isRichText: 1
@ -1352,7 +1349,7 @@ GameObject:
- component: {fileID: 812835471}
- component: {fileID: 812835470}
- component: {fileID: 812835469}
m_Layer: 3
m_Layer: 5
m_Name: Viewport
m_TagString: Untagged
m_Icon: {fileID: 0}
@ -1441,7 +1438,7 @@ GameObject:
- component: {fileID: 839969255}
- component: {fileID: 839969257}
- component: {fileID: 839969256}
m_Layer: 3
m_Layer: 5
m_Name: BackText
m_TagString: Untagged
m_Icon: {fileID: 0}
@ -1578,7 +1575,7 @@ GameObject:
- component: {fileID: 868437932}
- component: {fileID: 868437931}
- component: {fileID: 868437930}
m_Layer: 3
m_Layer: 5
m_Name: Scrollbar Vertical
m_TagString: Untagged
m_Icon: {fileID: 0}
@ -1648,7 +1645,7 @@ MonoBehaviour:
m_TargetGraphic: {fileID: 1237272502}
m_HandleRect: {fileID: 1237272501}
m_Direction: 2
m_Value: 0
m_Value: 1
m_Size: 1
m_NumberOfSteps: 0
m_OnValueChanged:
@ -2096,7 +2093,7 @@ GameObject:
- component: {fileID: 1055376734}
- component: {fileID: 1055376733}
- component: {fileID: 1055376732}
m_Layer: 3
m_Layer: 5
m_Name: Scroll View
m_TagString: Untagged
m_Icon: {fileID: 0}
@ -2253,7 +2250,6 @@ MonoBehaviour:
m_Name:
m_EditorClassIdentifier:
LaneSystem: {fileID: 106057762}
coinPool: {fileID: 1453004309}
<ObstaclePools>k__BackingField:
- {fileID: 4230759379826572186}
- {fileID: 3994382559241916552}
@ -2268,7 +2264,6 @@ GameObject:
serializedVersion: 6
m_Component:
- component: {fileID: 1176782784}
- component: {fileID: 1176782785}
m_Layer: 0
m_Name: Pools
m_TagString: Untagged
@ -2289,7 +2284,6 @@ Transform:
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 1220413204}
- {fileID: 5750222507749656094}
- {fileID: 3591750642126941782}
- {fileID: 916824467}
@ -2297,82 +2291,6 @@ Transform:
- {fileID: 1119912663875091926}
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &1176782785
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1176782783}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: c4456a434a6301241bcca08c705b96c4, type: 3}
m_Name:
m_EditorClassIdentifier:
capacity: 0
prefab: {fileID: 0}
--- !u!1001 &1220413203
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 1176782784}
m_Modifications:
- target: {fileID: 2738643474112209314, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
propertyPath: m_LocalPosition.x
value: 3.7201803
objectReference: {fileID: 0}
- target: {fileID: 2738643474112209314, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
propertyPath: m_LocalPosition.y
value: -0.29014507
objectReference: {fileID: 0}
- target: {fileID: 2738643474112209314, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
propertyPath: m_LocalPosition.z
value: 29.534254
objectReference: {fileID: 0}
- target: {fileID: 2738643474112209314, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 2738643474112209314, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
propertyPath: m_LocalRotation.x
value: -0
objectReference: {fileID: 0}
- target: {fileID: 2738643474112209314, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
propertyPath: m_LocalRotation.y
value: -0
objectReference: {fileID: 0}
- target: {fileID: 2738643474112209314, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
propertyPath: m_LocalRotation.z
value: -0
objectReference: {fileID: 0}
- target: {fileID: 2738643474112209314, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2738643474112209314, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 2738643474112209314, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7658440756881775109, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
propertyPath: m_Name
value: CoinPool
objectReference: {fileID: 0}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects: []
m_AddedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
--- !u!4 &1220413204 stripped
Transform:
m_CorrespondingSourceObject: {fileID: 2738643474112209314, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
m_PrefabInstance: {fileID: 1220413203}
m_PrefabAsset: {fileID: 0}
--- !u!1 &1237272500
GameObject:
m_ObjectHideFlags: 0
@ -2384,7 +2302,7 @@ GameObject:
- component: {fileID: 1237272501}
- component: {fileID: 1237272503}
- component: {fileID: 1237272502}
m_Layer: 3
m_Layer: 5
m_Name: Handle
m_TagString: Untagged
m_Icon: {fileID: 0}
@ -2705,17 +2623,6 @@ CanvasRenderer:
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1421905533}
m_CullTransparentMesh: 1
--- !u!114 &1453004309 stripped
MonoBehaviour:
m_CorrespondingSourceObject: {fileID: 8935043373779239955, guid: 44cf83f237ca73248933ea3c97149a4a, type: 3}
m_PrefabInstance: {fileID: 1220413203}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: c4456a434a6301241bcca08c705b96c4, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &1480218704
GameObject:
m_ObjectHideFlags: 0
@ -3354,10 +3261,6 @@ PrefabInstance:
propertyPath: m_Layer
value: 7
objectReference: {fileID: 0}
- target: {fileID: 7509186232753540492, guid: 01fa89ab9028c864b8560621b7d51f50, type: 3}
propertyPath: JumpSound
value:
objectReference: {fileID: 1865094442}
- target: {fileID: 7509186232753540492, guid: 01fa89ab9028c864b8560621b7d51f50, type: 3}
propertyPath: isPlayer2
value: 0
@ -3599,156 +3502,6 @@ MonoBehaviour:
- {fileID: 2100000, guid: 52883a1cafd660e448b2cd963dd45cc6, type: 2}
- {fileID: 2100000, guid: 60c2f0e0aaa8f8d4e9d23d7e3768653b, type: 2}
playerId: Player2
--- !u!1 &1733628372
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1733628373}
- component: {fileID: 1733628375}
- component: {fileID: 1733628374}
m_Layer: 5
m_Name: Separator
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &1733628373
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1733628372}
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: []
m_Father: {fileID: 678372250}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 5, y: 598.7}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1733628374
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1733628372}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 0, g: 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: 0}
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 &1733628375
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1733628372}
m_CullTransparentMesh: 1
--- !u!1 &1772075871
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1772075872}
- component: {fileID: 1772075874}
- component: {fileID: 1772075873}
m_Layer: 5
m_Name: Image
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &1772075872
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1772075871}
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: []
m_Father: {fileID: 678372250}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: 0, y: 274.87}
m_SizeDelta: {x: 128.84, y: 30.8}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &1772075873
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1772075871}
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.9056604, g: 0.9056604, b: 0.9056604, a: 0.8980392}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Sprite: {fileID: 10907, guid: 0000000000000000f000000000000000, type: 0}
m_Type: 1
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!222 &1772075874
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1772075871}
m_CullTransparentMesh: 1
--- !u!1 &1791311979
GameObject:
m_ObjectHideFlags: 0
@ -4078,8 +3831,8 @@ RectTransform:
m_LocalScale: {x: 0, y: 0, z: 0}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 678372250}
- {fileID: 220002229}
- {fileID: 678372250}
- {fileID: 552140505}
m_Father: {fileID: 245285643}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
@ -4088,135 +3841,6 @@ RectTransform:
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: 0}
m_Pivot: {x: 0, y: 0}
--- !u!1 &1865094441
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1865094443}
- component: {fileID: 1865094442}
m_Layer: 0
m_Name: JumpSound
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!82 &1865094442
AudioSource:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1865094441}
m_Enabled: 1
serializedVersion: 4
OutputAudioMixerGroup: {fileID: 0}
m_audioClip: {fileID: 8300000, guid: 1349cd948201da94d803d355043b3e6b, type: 3}
m_Resource: {fileID: 8300000, guid: 1349cd948201da94d803d355043b3e6b, type: 3}
m_PlayOnAwake: 0
m_Volume: 1
m_Pitch: 2
Loop: 0
Mute: 0
Spatialize: 0
SpatializePostEffects: 0
Priority: 128
DopplerLevel: 1
MinDistance: 1
MaxDistance: 500
Pan2D: 0
rolloffMode: 0
BypassEffects: 0
BypassListenerEffects: 0
BypassReverbZones: 0
rolloffCustomCurve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 1
inSlope: 0
outSlope: 0
tangentMode: 0
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 1
value: 0
inSlope: 0
outSlope: 0
tangentMode: 0
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
panLevelCustomCurve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 0
inSlope: 0
outSlope: 0
tangentMode: 0
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
spreadCustomCurve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 0
inSlope: 0
outSlope: 0
tangentMode: 0
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
reverbZoneMixCustomCurve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 1
inSlope: 0
outSlope: 0
tangentMode: 0
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
--- !u!4 &1865094443
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1865094441}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 665.951, y: 24.450401, z: 2630.0884}
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 &1872880025
GameObject:
m_ObjectHideFlags: 0
@ -4653,7 +4277,7 @@ RectTransform:
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1856934115903457218}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 28.65}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
@ -4665,8 +4289,8 @@ RectTransform:
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: -5}
m_SizeDelta: {x: -60.000004, y: -110}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: -60.000004, y: -200}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!1 &1856934115903457218
GameObject:
@ -4680,7 +4304,7 @@ GameObject:
- component: {fileID: 1856934115903457221}
- component: {fileID: 1856934115903457222}
- component: {fileID: 4920621562230953387}
m_Layer: 3
m_Layer: 5
m_Name: ScoreboardView
m_TagString: Untagged
m_Icon: {fileID: 0}
@ -4708,7 +4332,7 @@ MonoBehaviour:
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 0.59119487, g: 0.59119487, b: 0.59119487, a: 0.7019608}
m_Color: {r: 1, g: 1, b: 1, a: 0.392}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
@ -4787,7 +4411,7 @@ GameObject:
m_Component:
- component: {fileID: 2749335941631071934}
- component: {fileID: 5068000569768891960}
m_Layer: 3
m_Layer: 5
m_Name: VerticalLayout
m_TagString: Untagged
m_Icon: {fileID: 0}
@ -5304,10 +4928,6 @@ PrefabInstance:
propertyPath: m_Layer
value: 6
objectReference: {fileID: 0}
- target: {fileID: 7509186232753540492, guid: 01fa89ab9028c864b8560621b7d51f50, type: 3}
propertyPath: JumpSound
value:
objectReference: {fileID: 1865094442}
- target: {fileID: 7509186232753540492, guid: 01fa89ab9028c864b8560621b7d51f50, type: 3}
propertyPath: isPlayer2
value: 1
@ -5644,14 +5264,6 @@ PrefabInstance:
serializedVersion: 3
m_TransformParent: {fileID: 1858832248}
m_Modifications:
- target: {fileID: 6634832997822410792, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_AnchorMax.x
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 6634832997822410792, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_AnchorMin.x
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 6634832997822410792, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_SizeDelta.x
value: 129.0279
@ -5660,26 +5272,18 @@ PrefabInstance:
propertyPath: m_SizeDelta.y
value: 32
objectReference: {fileID: 0}
- target: {fileID: 6634832997822410792, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_LocalPosition.z
value: 1
objectReference: {fileID: 0}
- target: {fileID: 6634832997822410792, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_AnchoredPosition.x
value: 0
value: -64.514404
objectReference: {fileID: 0}
- target: {fileID: 6634832997822410792, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_AnchoredPosition.y
value: -25.2
value: -16
objectReference: {fileID: 0}
- target: {fileID: 6634832997822410793, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_Layer
value: 5
objectReference: {fileID: 0}
- target: {fileID: 6634832997822410798, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_CullTransparentMesh
value: 1
objectReference: {fileID: 0}
- target: {fileID: 6634832997822410799, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_fontSize
value: 30.25
@ -5694,19 +5298,7 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: 6634832997822410799, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_margin.z
value: -0.043342564
objectReference: {fileID: 0}
- target: {fileID: 6634832997822410799, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_fontStyle
value: 2
objectReference: {fileID: 0}
- target: {fileID: 6634832997822410799, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_HorizontalAlignment
value: 2
objectReference: {fileID: 0}
- target: {fileID: 6634832997822410799, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: 'm_ActiveFontFeatures.Array.data[0]'
value: 1801810542
value: 8.811302
objectReference: {fileID: 0}
- target: {fileID: 6634832998035864265, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
propertyPath: m_Pivot.x
@ -5814,13 +5406,7 @@ PrefabInstance:
objectReference: {fileID: 0}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects:
- targetCorrespondingSourceObject: {fileID: 6634832998035864265, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
insertIndex: 0
addedObject: {fileID: 1733628373}
- targetCorrespondingSourceObject: {fileID: 6634832998035864265, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
insertIndex: 1
addedObject: {fileID: 1772075872}
m_AddedGameObjects: []
m_AddedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 68d36a24cad029f4a91d5c8e7aa18281, type: 3}
--- !u!1 &6871074651254400895
@ -5865,7 +5451,7 @@ GameObject:
- component: {fileID: 4191864465036188526}
- component: {fileID: 334265878197336758}
- component: {fileID: 3413095558211005055}
m_Layer: 3
m_Layer: 5
m_Name: ScoreboardText
m_TagString: Untagged
m_Icon: {fileID: 0}
@ -5889,4 +5475,3 @@ SceneRoots:
- {fileID: 634835459}
- {fileID: 214096430}
- {fileID: 245285643}
- {fileID: 1865094443}

View File

@ -984,135 +984,6 @@ Transform:
m_Children: []
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &1146222636
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1146222638}
- component: {fileID: 1146222637}
m_Layer: 0
m_Name: SoundManager
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!82 &1146222637
AudioSource:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1146222636}
m_Enabled: 1
serializedVersion: 4
OutputAudioMixerGroup: {fileID: 0}
m_audioClip: {fileID: 8300000, guid: ddf8fb13b61f8474d89b050db1febfc6, type: 3}
m_Resource: {fileID: 8300000, guid: ddf8fb13b61f8474d89b050db1febfc6, type: 3}
m_PlayOnAwake: 1
m_Volume: 1
m_Pitch: 1
Loop: 1
Mute: 0
Spatialize: 0
SpatializePostEffects: 0
Priority: 128
DopplerLevel: 1
MinDistance: 1
MaxDistance: 500
Pan2D: 0
rolloffMode: 0
BypassEffects: 0
BypassListenerEffects: 0
BypassReverbZones: 0
rolloffCustomCurve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 1
inSlope: 0
outSlope: 0
tangentMode: 0
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
- serializedVersion: 3
time: 1
value: 0
inSlope: 0
outSlope: 0
tangentMode: 0
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
panLevelCustomCurve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 0
inSlope: 0
outSlope: 0
tangentMode: 0
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
spreadCustomCurve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 0
inSlope: 0
outSlope: 0
tangentMode: 0
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
reverbZoneMixCustomCurve:
serializedVersion: 2
m_Curve:
- serializedVersion: 3
time: 0
value: 1
inSlope: 0
outSlope: 0
tangentMode: 0
weightedMode: 0
inWeight: 0.33333334
outWeight: 0.33333334
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
--- !u!4 &1146222638
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1146222636}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 665.951, y: 24.450401, z: 2630.0884}
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 &2040053552
GameObject:
m_ObjectHideFlags: 0
@ -1323,4 +1194,3 @@ SceneRoots:
- {fileID: 533191358}
- {fileID: 379991192}
- {fileID: 1911555307}
- {fileID: 1146222638}

File diff suppressed because it is too large Load Diff

View File

@ -7,7 +7,7 @@ MonoBehaviour:
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 0
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 9055f72a604bc3f4ba01bc120f0643d2, type: 3}
m_Name: PlayerData
@ -15,6 +15,6 @@ MonoBehaviour:
<InvincibilityTime>k__BackingField: 600
<JumpHeight>k__BackingField: 6
<LaneSwitchSpeed>k__BackingField: 20
<CurrentSpeed>k__BackingField: 10
<InitialSpeed>k__BackingField: 10
<CurrentSpeed>k__BackingField: 401.62177
<SpeedAcceleration>k__BackingField: 1
<SpeedAcceleration>k__BackingField: 0

View File

@ -1,39 +1,13 @@
using System;
using System.Collections;
using System.Collections;
using UnityEngine;
[CreateAssetMenu(fileName = "PlayerData", menuName = "ScriptableObjects/Player")]
public sealed class PlayerData : ScriptableObject
public class PlayerData : ScriptableObject
{
// Serialize Fields
[field: SerializeField] public int InvincibilityTime { get; private set; }
[field: SerializeField] public int InvincibilityTime { get; private set; }
[field: SerializeField] public float JumpHeight { get; private set; }
[field: SerializeField] public float LaneSwitchSpeed { get; private set; }
[field: SerializeField] public float CurrentSpeed { get; set; }
[field: SerializeField] public float InitialSpeed { get; private set; }
[field: SerializeField] public float CurrentSpeed { get; internal set; }
[field: SerializeField] public float SpeedAcceleration { get; private set; }
// Other attributes
private bool onPause = false;
private void Awake()
{
CurrentSpeed = InitialSpeed;
}
public void Reset()
{
CurrentSpeed = InitialSpeed;
}
public void Update()
{
if (!onPause)
CurrentSpeed += SpeedAcceleration / 1000;
}
public void isPaused(bool isPaused)
{
onPause = isPaused;
}
}

View File

@ -5,7 +5,6 @@ using UnityEngine;
public class Coin : PoolingObject<Coin>, ICollectable,IResettable
{
[SerializeField] private int coinValue;
public int CoinValue => coinValue;
private SinAnimator sinAnimator;
public Renderer Renderer { get; private set; }
@ -24,9 +23,7 @@ public class Coin : PoolingObject<Coin>, ICollectable,IResettable
gameObject.SetActive(false);
OnCoinCollected?.Invoke(coinValue);
OnCoinDissapeared?.Invoke(this);
ReturnToPool();
}
public void UpdateStartPositionForSinAnimator()
{
sinAnimator.UpdateStartPosition();

View File

@ -1,9 +0,0 @@
namespace Assets.Scripts.GameSession
{
public class GameResult
{
public static string MatchResult { get; set; }
public static int score { get; set; }
public static int coinsEarned { get; set; }
}
}

View File

@ -1,3 +0,0 @@
fileFormatVersion: 2
guid: 2ccf940b8a6f4771951a3760a7865928
timeCreated: 1739468701

View File

@ -12,12 +12,13 @@ public class GameSession : MonoBehaviour,IResettable
[SerializeField] private Player player1;
[SerializeField] [CanBeNull] private Player player2;
[SerializeField] private Scoreboard scoreboard;
[SerializeField] private bool isDuoMode;
[SerializeField] private PlayerData playerData;
[SerializeField] private Boolean isDuoMode;
public static GameSession Instance { get; private set; }
private WorldCurver Curver { get; set; }
public WorldCurver Curver { get; private set; }
private IInputTranslator _player1InputTranslator;
private IInputTranslator _player2InputTranslator;
public static string MatchResult { get; private set; }
private bool _isSessionPaused = false;
private bool _isInputAlreadyRestricted = false;
private float _speedAtPause;
@ -38,7 +39,6 @@ public class GameSession : MonoBehaviour,IResettable
}
private void Update()
{
playerData.Update();
_player1InputTranslator.Tick();
if (isDuoMode)
{
@ -46,8 +46,8 @@ public class GameSession : MonoBehaviour,IResettable
}
Curver.Tick();
// curver.SinCurveX();
// Curver.SinCurveY();
// curver.SinCurveX();
// Curver.SinCurveY();
//Curver.TurnWorldToLeft();
}
@ -56,28 +56,36 @@ public class GameSession : MonoBehaviour,IResettable
var player1Holder = new KeyBindingHolder();
player1Holder.Init(false);
_player1InputTranslator = new InputTranslator<KeyBinding>(player1Holder, false);
var player2Holder = new KeyBindingHolder();
player2Holder.Init(true);
_player2InputTranslator = new InputTranslator<KeyBinding>(player2Holder, true);
playerData.Reset();
if (isDuoMode)
{
var player2Holder = new KeyBindingHolder();
player2Holder.Init(true);
_player2InputTranslator = new InputTranslator<KeyBinding>(player2Holder, true);
}
}
public void AddCommandTranslator(ICommandTranslator translator, bool isPlayer2)
{
if (isPlayer2)
{
_player2InputTranslator.AddCommandTranslator(translator);
}else
{
_player1InputTranslator.AddCommandTranslator(translator);
}
if (isPlayer2)
{
_player2InputTranslator.AddCommandTranslator(translator);
}else
{
_player1InputTranslator.AddCommandTranslator(translator);
}
}
public void PauseSession(bool isPaused)
{
playerData.isPaused(isPaused);
if (isPaused)
_speedAtPause = player1.playerData.CurrentSpeed;
else
{
player1.playerData.CurrentSpeed = _speedAtPause;
}
Time.timeScale = isPaused ? 0 : 1;
if (!_isSessionPaused && _player1InputTranslator.IsTranslationResticted(InputConstants.InGameCommands) && _player2InputTranslator.IsTranslationResticted(InputConstants.InGameCommands) )
{
@ -125,8 +133,6 @@ public class GameSession : MonoBehaviour,IResettable
}
else
{
GameResult.score = player1.PlayerStatictics.Score;
GameResult.coinsEarned = player1.PlayerStatictics.coinCount;
SceneManager.LoadScene("DeathScreen");
}
}
@ -137,26 +143,23 @@ public class GameSession : MonoBehaviour,IResettable
if (player1.isDead && player2.isDead)
{
SendResultToDeathScreen1VS1("DRAW");
SendResultToDeathScreen("DRAW");
}
else if (player1.isDead)
{
SendResultToDeathScreen1VS1("PLAYER2");
SendResultToDeathScreen("PLAYER2");
}
else if (player2.isDead)
{
SendResultToDeathScreen1VS1("PLAYER1");
SendResultToDeathScreen("PLAYER1");
}
isCheckingEquality = false;
}
private void SendResultToDeathScreen1VS1(string result)
private void SendResultToDeathScreen(string result)
{
//MatchResult = result;
GameResult.score = player1.PlayerStatictics.Score;
GameResult.coinsEarned = player1.PlayerStatictics.coinCount;
GameResult.MatchResult = result;
MatchResult = result;
SceneManager.LoadScene("DeathScreen1VS1");
}
@ -181,7 +184,6 @@ public class GameSession : MonoBehaviour,IResettable
public void ResetToDefault()
{
PauseSession(false);
playerData.Reset();
if(player1 !=null)
player1.ResetToDefault();
if (isDuoMode && player2 != null)
@ -189,9 +191,4 @@ public class GameSession : MonoBehaviour,IResettable
player2.ResetToDefault();
}
}
public PlayerData GetPlayerData()
{
return this.playerData;
}
}

View File

@ -1,36 +1,33 @@
using Pools;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace Obstacles
[RequireComponent(typeof(BoxCollider))]
public class Obstacle : PoolingObject<Obstacle>, IObstacle,IDamageDealer,IResettable
{
[RequireComponent(typeof(BoxCollider))]
public class Obstacle : PoolingObject<Obstacle>, IObstacle,IDamageDealer,IResettable
[field: SerializeField] public bool IsOnAllLanes { get; private set; }
[field: SerializeField] public bool IsInevitable { get; private set; }
public BoxCollider Collider { get; private set; }
private void Awake()
{
[field: SerializeField] public bool IsOnAllLanes { get; private set; }
[field: SerializeField] public bool IsInevitable { get; private set; }
public BoxCollider Collider { get; private set; }
Collider = GetComponent<BoxCollider>();
}
public void ResetToDefault()
{
transform.localPosition = Vector3.zero;
transform.position = Vector3.zero;
transform.rotation = Quaternion.identity;
gameObject.transform.SetParent(OwningPool.transform);
ReturnToPool();
}
public void Impact()
{
ResetToDefault();
}
private void Awake()
{
Collider = GetComponent<BoxCollider>();
OwningPool = FindFirstObjectByType<ObstaclePool>();
}
public void ResetToDefault()
{
transform.localPosition = Vector3.zero;
transform.position = Vector3.zero;
transform.rotation = Quaternion.identity;
gameObject.transform.SetParent(OwningPool.transform);
ReturnToPool();
}
public void Impact()
{
ResetToDefault();
}
public void DealDamage(IDamageable target, int amount)
{
target.TakeDamage(amount);
}
public void DealDamage(IDamageable target, int amount)
{
target.TakeDamage(amount);
}
}

View File

@ -38,6 +38,8 @@ public class Player : MonoBehaviour, IResettable, ICommandTranslator
public IDamageable PlayerHealth { get; private set; }
public Statistics PlayerStatictics { get; private set; }
public PlayerData PlayerData { get { return playerData; } }
#endregion
#region MovementControl
@ -62,10 +64,6 @@ public class Player : MonoBehaviour, IResettable, ICommandTranslator
#endregion
#region Sounds
public AudioSource JumpSound;
#endregion
public bool IsInvincible { get; private set; }
public float InvincibilityTime { get; private set; } //PLAYER DATA ScriptableObject
[SerializeField] private Boolean isPlayer2;
@ -74,7 +72,6 @@ public class Player : MonoBehaviour, IResettable, ICommandTranslator
private void Awake()
{
playerData = GameSession.Instance.GetPlayerData();
Debug.Log("Player Awake : " + this);
GameSession.Instance.AddCommandTranslator(this, isPlayer2);
animator = GetComponent<Animator>();
@ -97,7 +94,6 @@ public class Player : MonoBehaviour, IResettable, ICommandTranslator
private void Start()
{
PlayerStateMachine.SetState(PlayerStateMachine.PlayerStartingIdleState);
JumpSound.GetComponent<AudioSource>();
}
@ -137,12 +133,6 @@ public class Player : MonoBehaviour, IResettable, ICommandTranslator
else if (other.TryGetComponent(out ICollectable collectable))
{
collectable.Collect();
if (other.TryGetComponent(out Coin coin))
{
PlayerStatictics.AddScore(coin.CoinValue);
coin.gameObject.SetActive(false);
}
}
}
@ -152,6 +142,20 @@ public class Player : MonoBehaviour, IResettable, ICommandTranslator
PlayerStateMachine.SetState(PlayerStateMachine.PlayerDeadState);
GameSession.Instance.UpdateScoreboard(new ScoreboardEntry(name, PlayerStatictics.Score));
GameSession.Instance.HandlePlayerDeath(this); // Informe GameSession qu'un joueur est mort
// PlayerStateMachine.SetState(PlayerStateMachine.PlayerDeadState);
// GameSession.Instance.UpdateScoreboard(new ScoreboardEntry(name, PlayerStatictics.Score));
// if (isPlaying1VS1)
// {
// // SceneManager.LoadScene("DeathScreen1v1");
// SceneManager.LoadScene("Death1VS1");
//
// }
// else
// {
// SceneManager.LoadScene("Death1VS1");
// }
//
}
public IEnumerator GrantInvincibility()
@ -186,7 +190,6 @@ public class Player : MonoBehaviour, IResettable, ICommandTranslator
case ECommand.RIGHT:
case ECommand.RIGHT2:
PlayerStateMachine.IncreaseTargetLane();
JumpSound.Play();
break;
case ECommand.LEFT:
case ECommand.LEFT2:

View File

@ -1,38 +1,39 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class PlayerAnimator
{
private readonly Animator _animator;
private readonly int _runningHash = Animator.StringToHash("Run");
private readonly int _deadHash = Animator.StringToHash("Dead");
private readonly int _jumpHash = Animator.StringToHash("Jump");
private readonly int _slideHash = Animator.StringToHash("Slide");
private readonly int _idleHash = Animator.StringToHash("Idle");
private Animator animator;
private int runningHash = Animator.StringToHash("Run");
private int deadHash = Animator.StringToHash("Dead");
private int jumpHash = Animator.StringToHash("Jump");
private int slideHash = Animator.StringToHash("Slide");
private int idleHash = Animator.StringToHash("Idle");
public PlayerAnimator(Animator animator)
{
if (animator)
this._animator = animator;
this.animator = animator;
}
public void SetRunState(bool isRunning)
{
_animator?.SetBool(_runningHash, isRunning);
animator?.SetBool(runningHash, isRunning);
}
public void SetJumpState(bool isJumping)
{
_animator?.SetBool(_jumpHash, isJumping);
animator?.SetBool(jumpHash, isJumping);
}
public void SetDeadState(bool isDead)
{
_animator?.SetBool(_deadHash, isDead);
animator?.SetBool(deadHash, isDead);
}
public void SetSlideState(bool isSliding)
{
_animator?.SetBool(_slideHash, isSliding);
animator?.SetBool(slideHash, isSliding);
}
public void SetIdleState(bool isIdle)
{
if(_animator){}
_animator?.SetBool(_idleHash, isIdle);
animator?.SetBool(idleHash, isIdle);
}
}

View File

@ -8,7 +8,7 @@ public abstract class MovingState : PlayerState
private float speed; //SO
private float laneSwitchSpeed; //SO
protected const float gravity = -9.8f;
private float invincibilityTime => playerSM.playerData.InvincibilityTime;
private float invincibilityTime => playerSM.PlayerData.InvincibilityTime;
public MovingState(PlayerStateMachine playerStateMachine) : base(playerStateMachine)
{
this.playerSM = playerStateMachine;
@ -22,6 +22,7 @@ public abstract class MovingState : PlayerState
public override void Tick()
{
speed = playerData.CurrentSpeed;
//HandleDirection();
playerSM.HorizontalDeltaPosition = playerSM.PlayerTransform.forward * speed * Time.deltaTime ;
playerSM.HorizontalDeltaPosition += playerSM.PlayerTransform.forward * speed * Time.deltaTime;
playerSM.UpdateDistance(playerSM.HorizontalDeltaPosition.z); //вынести в контроллер
@ -37,6 +38,28 @@ public abstract class MovingState : PlayerState
playerSM.VerticalDeltaPosition += gravity * Time.deltaTime;
}
//private void HandleDirection()
//{
// switch (playerSM.InputDirection)
// {
// case EInputDirection.RIGHT:
// playerSM.IncreaseTargetLane();
// break;
// case EInputDirection.LEFT:
// playerSM.DecreaseTargetLane();
// break;
// case EInputDirection.UP:
// playerSM.SetState(playerSM.PlayerJumpState);
// break;
// case EInputDirection.DOWN:
// playerSM.SetState(playerSM.PlayerSlideState);
// break;
// default:
// break;
// }
//}
public void SwitchLane()
{
float sidewaysPos = playerTransform.localPosition.x;
@ -60,6 +83,9 @@ public abstract class MovingState : PlayerState
playerSM.HorizontalDeltaPosition += playerSM.PlayerTransform.right * diffX.x;
}
}
}

View File

@ -11,7 +11,7 @@ public abstract class PlayerState : State<Player>
public PlayerState(PlayerStateMachine playerStateMachine)
{
playerSM = playerStateMachine;
playerData = playerStateMachine.playerData;
playerData = playerStateMachine.PlayerData;
playerTransform = playerStateMachine.PlayerTransform;
}
public override void Tick()

View File

@ -4,13 +4,14 @@ using UnityEngine.Animations.Rigging;
public class PlayerStateMachine : StateMachine<Player>
{
private Player player;
public PlayerData playerData;
private PlayerData playerData;
private Transform playerTransform;
public Transform PlayerTransform { get { return playerTransform; } }
public PlayerData PlayerData { get { return playerData; } }
public PlayerStateMachine(Player player)
{
this.player = player;
playerData = GameSession.Instance.GetPlayerData();
playerData = player.PlayerData;
playerTransform = player.transform;
InitStates();
}

View File

@ -2,18 +2,17 @@ using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.Serialization;
public class Statistics : MonoBehaviour,IResettable
{
private float distance;
public int coinCount;
private int coinCount;
private int coinMultiplier;
public int Score { get; private set; }
public event Action<int> OnCoinCountChanged = delegate { };
public event Action<float> OnDistanceChanged = delegate { };
public event Action<int> OnScoreCalculated = delegate { };
[FormerlySerializedAs("PlayerHUD")] [SerializeField] private PlayerHUDView playerHUD;
[SerializeField] private PlayerHUDView PlayerHUD;
private void Awake()
{
ResetToDefault();
@ -44,7 +43,7 @@ public class Statistics : MonoBehaviour,IResettable
{
Score = Mathf.FloorToInt(coinCount * coinMultiplier + distance);
OnScoreCalculated?.Invoke(Score);
playerHUD.UpdateScore(Score.ToString());
PlayerHUD.UpdateScore(Score.ToString());
}
public void ResetToDefault()
@ -55,12 +54,4 @@ public class Statistics : MonoBehaviour,IResettable
coinMultiplier = 1;
//gameOverPopUp.gameObject.SetActive(false);
}
public void AddScore(int amount)
{
Score += amount;
OnScoreCalculated?.Invoke(Score);
playerHUD.UpdateScore(Score.ToString());
}
}

View File

@ -1,9 +1,5 @@
using System;
using System.Collections;
using UnityEngine;
namespace Pools
{
public sealed class CoinPool : BasePool<Coin>
{}
}
public class CoinPool : BasePool<Coin>
{}

View File

@ -8,8 +8,6 @@
// </auto-generated>
//------------------------------------------------------------------------------
using Obstacles;
namespace Pools
{

View File

@ -1,13 +1,13 @@
using Pools;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class ChunkGenerator : MonoBehaviour
{
[SerializeField] private LaneSystem LaneSystem;
[SerializeField] private CoinPool coinPool;
public CoinPool CoinPool { get; private set; }
[field: SerializeField] public List<ObstaclePool> ObstaclePools { get; private set; }
private bool _isFirstChunk = true;
public Chunk Generate(Chunk chunkToFill)
{
@ -16,56 +16,21 @@ public class ChunkGenerator : MonoBehaviour
_isFirstChunk = false;
return chunkToFill;
}
if (!ObstaclePools.IsEmpty())
if (ObstaclePools.IsEmpty())
return chunkToFill;
var obstaclePool = ObstaclePools.GetRandomElement();
var obstacle = obstaclePool.Spawn();
chunkToFill.Obstacles.Add(obstacle);
obstacle.transform.SetParent(chunkToFill.transform, true);
obstacle.transform.localPosition = chunkToFill.Grid.GetRandomPosition();
if (obstacle.IsOnAllLanes)
{
var obstaclePool = ObstaclePools.GetRandomElement();
var obstacle = obstaclePool.Spawn();
chunkToFill.Obstacles.Add(obstacle);
obstacle.transform.SetParent(chunkToFill.transform, true);
obstacle.transform.localPosition = chunkToFill.Grid.GetRandomPosition();
if (obstacle.IsOnAllLanes)
{
obstacle.transform.localPosition = new Vector3(
LaneSystem.CenterLane * LaneSystem.LaneWidth,
transform.localPosition.y,
transform.localPosition.z
);
}
obstacle.transform.localPosition = new Vector3(
LaneSystem.CenterLane * LaneSystem.LaneWidth,
transform.localPosition.y,
transform.localPosition.z
);
}
Coin coin = coinPool.Spawn();
chunkToFill.Coins.Add(coin);
coin.transform.SetParent(chunkToFill.transform, true);
Vector3 randomPosition;
bool isPositionValid = false;
int laneIndex = Random.Range(0, LaneSystem.LaneCount);
randomPosition = new Vector3(
laneIndex * LaneSystem.LaneWidth,
chunkToFill.Grid.GetRandomPosition().y + 1.0f,
chunkToFill.Grid.GetRandomPosition().z
);
while (!isPositionValid)
{
isPositionValid = true;
foreach (var obstacle in chunkToFill.Obstacles)
{
if (Vector3.Distance(randomPosition, obstacle.transform.localPosition) < 1.0f)
{
isPositionValid = false;
break;
}
}
if (!isPositionValid)
{
randomPosition = new Vector3(
laneIndex * LaneSystem.LaneWidth,
chunkToFill.Grid.GetRandomPosition().y + 1.0f,
chunkToFill.Grid.GetRandomPosition().z
);
}
}
coin.transform.localPosition = randomPosition;
coin.UpdateStartPositionForSinAnimator();
return chunkToFill;
}
}

View File

@ -1,7 +1,6 @@
using System;
using System.Collections;
using System.Collections.Generic;
using Obstacles;
using UnityEngine;
[RequireComponent(typeof(BoxCollider))]
@ -38,7 +37,6 @@ public abstract class Chunk : PoolingObject<Chunk>, IResettable
transform.localPosition = Vector3.zero;
transform.position = Vector3.zero;
transform.rotation = Quaternion.identity;
Coins.Clear();
}
private void OnTriggerExit(Collider other)
{

View File

@ -8,7 +8,6 @@ public class LaneSystem : MonoBehaviour,IResettable
[field: SerializeField] public float LaneWidth { get; private set; }
[SerializeField] private int laneCount;
public int LaneCount => laneCount;
public List<int> Lanes { get; private set; }
public float CurrentPosition { get; private set; }
public float TargetPosition { get; set; }

View File

@ -1,24 +1,20 @@
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.Networking;
using System;
[Serializable]
public class ScoreboardEntriesTable
{
public List<ScoreboardEntry> listeScore;
public ScoreboardEntriesTable()
public ScoreboardEntriesTable(List<ScoreboardEntry> entries)
{
listeScore = new List<ScoreboardEntry>();
this.entries = entries;
}
public List<ScoreboardEntry> entries = new List<ScoreboardEntry>();
}
public class Scoreboard : MonoBehaviour
public class Scoreboard : MonoBehaviour, ICommandTranslator
{
private string apiUrl = "https://awesomerunner.lagaudiere.uk/score";
public List<ScoreboardEntry> entries = new List<ScoreboardEntry>();
[SerializeField] private int maxEntries;
private List<ScoreboardEntry> entries = new List<ScoreboardEntry>();
public event Action<ScoreboardEntry> OnEntryAdded;
@ -26,111 +22,72 @@ public class Scoreboard : MonoBehaviour
private void Start()
{
StartCoroutine(GetScoreboard());
}
private IEnumerator GetScoreboard()
{
Debug.Log("Fetching scoreboard...");
using (UnityWebRequest request = UnityWebRequest.Get(apiUrl))
GameSession.Instance.AddCommandTranslator(this, false);
string jsonScoreboardEntries = PlayerPrefs.GetString("ScoreboardEntriesTableTest"); //Binary file
ScoreboardEntriesTable entriesTable = JsonUtility.FromJson<ScoreboardEntriesTable>(jsonScoreboardEntries);
if (entriesTable == null)
return;
if (entriesTable.entries == null)
return;
List<PlayerScoreboardCardData> scoreboardCardDatas = new List<PlayerScoreboardCardData>();
for (int i = 0; i < entriesTable.entries.Count; i++)
{
yield return request.SendWebRequest();
if (request.result == UnityWebRequest.Result.Success)
{
string json = request.downloadHandler.text;
Debug.Log("Received JSON: " + json);
// Désérialiser directement en un tableau
ScoreboardEntry[] scoreboardEntriesArray = JsonHelper.FromJson<ScoreboardEntry>(json);
if (scoreboardEntriesArray != null)
{
entries = new List<ScoreboardEntry>(scoreboardEntriesArray);
SortScoreboardEntriesByHighscore(entries);
UpdateScoreboardView();
}
}
else
{
Debug.LogError("Erreur lors de la récupération du scoreboard : " + request.error);
}
entries.Add(entriesTable.entries[i]);
OnEntryAdded?.Invoke(entriesTable.entries[i]);
PlayerScoreboardCardData cardData = new PlayerScoreboardCardData(entriesTable.entries[i].Name, entriesTable.entries[i].Score.ToString());
scoreboardCardDatas.Add(cardData);
}
SortScoreboardEntriesByHighscore(entries);
SortScoreboardCardsDatasByHighscore(scoreboardCardDatas);
scoreboardView.AddPlayerCards(scoreboardCardDatas);
}
public void AddScoreboardEntry(string entryName, int entryScore)
{
ScoreboardEntry entry = new ScoreboardEntry(entryName, entryScore);
entries.Add(entry);
OnEntryAdded?.Invoke(entry);
}
public void SortScoreboardEntriesByHighscore(List<ScoreboardEntry> entries)
{
entries.Sort((x,y) => y.Score.CompareTo(x.Score));
}
public void SortScoreboardCardsDatasByHighscore(List<PlayerScoreboardCardData> scoreboardCardDatas)
{
scoreboardCardDatas.Sort((x, y) => y.playerScore.CompareTo(x.playerScore));
}
public void AddScoreboardEntry(ScoreboardEntry entry)
{
entries.Add(entry);
OnEntryAdded?.Invoke(entry);
SaveScoreboardEntriesTable();
}
public void SaveScoreboardEntriesTable()
{
SortScoreboardEntriesByHighscore(entries);
UpdateScoreboardView();
StartCoroutine(PostScoreboardEntry(entry));
ScoreboardEntriesTable scoreboardEntriesTable = new ScoreboardEntriesTable(entries);
string jsonScoreboardEntries = JsonUtility.ToJson(scoreboardEntriesTable);
PlayerPrefs.SetString("ScoreboardEntriesTableTest", jsonScoreboardEntries);
PlayerPrefs.Save();
}
private IEnumerator PostScoreboardEntry(ScoreboardEntry entry)
public void TranslateCommand(ECommand command, PressedState state)
{
string json = JsonUtility.ToJson(entry);
using (UnityWebRequest request = new UnityWebRequest(apiUrl, "POST"))
switch (command)
{
byte[] bodyRaw = System.Text.Encoding.UTF8.GetBytes(json);
request.uploadHandler = new UploadHandlerRaw(bodyRaw);
request.downloadHandler = new DownloadHandlerBuffer();
request.SetRequestHeader("Content-Type", "application/json");
yield return request.SendWebRequest();
if (request.result == UnityWebRequest.Result.Success)
{
Debug.Log("Score ajouté avec succès !");
OnEntryAdded?.Invoke(entry);
}
else
{
Debug.LogError("Erreur lors de l'ajout du score : " + request.error);
}
case ECommand.OPEN_SCOREBOARD:
if (state.IsPressed == true)
scoreboardView.Show(true);
if (state.IsReleased == true)
scoreboardView.Show(false);
break;
default:
scoreboardView.Show(false);
break;
}
}
private void SortScoreboardEntriesByHighscore(List<ScoreboardEntry> entries)
{
entries.Sort((x, y) => y.score.CompareTo(x.score));
}
private void UpdateScoreboardView()
{
Debug.Log("Updating scoreboard view...");
List<PlayerScoreboardCardData> scoreboardCardDatas = new List<PlayerScoreboardCardData>();
foreach (var entry in entries)
{
OnEntryAdded?.Invoke(entry);
scoreboardCardDatas.Add(new PlayerScoreboardCardData(entry.pseudo, entry.score.ToString()));
}
scoreboardView.AddPlayerCards(scoreboardCardDatas);
}
}
public static class JsonHelper
{
public static T[] FromJson<T>(string json)
{
string wrappedJson = "{\"items\":" + json + "}";
Wrapper<T> wrapper = JsonUtility.FromJson<Wrapper<T>>(wrappedJson);
return wrapper.items;
}
[System.Serializable]
private class Wrapper<T>
{
public T[] items;
}
}
[Serializable]
public class ScoreboardEntriesWrapper
{
public ScoreboardEntry[] listeScore;
}

View File

@ -1,4 +1,3 @@
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
@ -6,13 +5,13 @@ using UnityEngine;
[System.Serializable]
public class ScoreboardEntry
{
public string pseudo;
public int score;
public ScoreboardEntry(string pseudo, int score)
[SerializeField] private float score;
[SerializeField] private string name;
public float Score { get { return score; } private set { score = value; } }
public string Name { get { return name; } private set { name = value; } }
public ScoreboardEntry(string name,float score)
{
this.pseudo = pseudo;
this.name = name;
this.score = score;
}
}

View File

@ -0,0 +1,64 @@
using System.Globalization;
using UnityEngine;
using TMPro; // Nécessaire pour TextMeshPro
public class UIManager : MonoBehaviour
{
// Références pour la distance et les pièces (mode normal)
public TextMeshProUGUI distanceText;
public TextMeshProUGUI numberCoinsText;
// Références pour le mode 1v1
public TextMeshProUGUI joueur1Text;
public TextMeshProUGUI joueur2Text;
// Variables pour distance et pièces
private float distance = 0f;
private int coins = 0;
// Variables pour le mode 1v1
private int joueur1Score = 1;
private int joueur2Score = 0;
// Mode de jeu
public bool is1v1Mode = false;
void Update()
{
if (!is1v1Mode)
{
distanceText.text = distance.ToString("F1", CultureInfo.InvariantCulture) + "M";
numberCoinsText.text = coins.ToString();
}
else if (is1v1Mode)
{
distanceText.text = distance.ToString("F1", CultureInfo.InvariantCulture) + "M";
numberCoinsText.text = coins.ToString();
DisplayResult();
}
}
public void DisplayResult()
{
if (is1v1Mode)
{
if (joueur1Score > joueur2Score)
{
joueur1Text.text ="Winner";
joueur2Text.text ="Loser";
}
else if (joueur1Score < joueur2Score)
{
joueur1Text.text = "Loser";
joueur2Text.text = "Winner";
}
else
{
joueur1Text.text = "Égalité";
joueur2Text.text = "Égalité";
}
}
}
}

View File

@ -0,0 +1,2 @@
fileFormatVersion: 2
guid: 2278264f81ffe464da1a99450675b475

View File

@ -1,5 +1,4 @@
using Assets.Scripts.GameSession;
using TMPro;
using TMPro;
using UnityEngine;
using UnityEngine.SceneManagement;
using UnityEngine.UI;
@ -10,42 +9,32 @@ namespace UI.Views
{
public TMP_Text Joueur1Text;
public TMP_Text Joueur2Text;
public TMP_Text CoinsText;
public TMP_Text ScoreText;
private void Start()
{
if (!string.IsNullOrEmpty(GameResult.MatchResult))
if (!string.IsNullOrEmpty(GameSession.MatchResult))
{
switch (GameResult.MatchResult)
switch (GameSession.MatchResult)
{
case "PLAYER1":
if(Joueur2Text != null)
Joueur1Text.text = "WINNER !";
if(Joueur2Text != null)
Joueur2Text.text = "LOSER !";
Joueur1Text.text = "WINNER !";
Joueur2Text.text = "LOSER !";
break;
case "PLAYER2":
if(Joueur2Text != null )
Joueur2Text.text = "WINNER !";
if(Joueur2Text != null)
Joueur1Text.text = "LOSER !";
Joueur2Text.text = "WINNER !";
Joueur1Text.text = "LOSER !";
break;
case "DRAW":
if(Joueur1Text != null)
Joueur1Text.text = "Draw";
if(Joueur2Text != null)
Joueur2Text.text = "Draw";
Joueur1Text.text = "Draw";
Joueur2Text.text = "Draw";
break;
}
}
else
{
}
CoinsText.text = GameResult.coinsEarned.ToString();
ScoreText.text = GameResult.score.ToString() + "M";
}
public void RestartGame()

View File

@ -21,37 +21,22 @@ public class ScoreboardView : BaseView
}
public void AddPlayerCards(List<PlayerScoreboardCardData> cardsData)
{
Debug.Log("Adding " + cardsData.Count + " player cards.");
foreach (var cardData in cardsData)
{
Debug.Log("Card Data: " + cardData.playerName + " - " + cardData.playerScore);
AddPlayerCard(cardData);
}
}
private void AddPlayerCard(PlayerScoreboardCardData cardData)
{
if (layoutGroup == null)
{
Debug.LogError("layoutGroup is not assigned!");
return;
}
//if (playerCards.ContainsKey(cardData.playerName))
// return;
PlayerScoreboardCard playerScoreboardCard = Instantiate(cardPrefab);
playerScoreboardCard.transform.SetParent(layoutGroup.transform, false);
playerScoreboardCard.UpdateCard(cardData);
Debug.Log("Player card created for: " + cardData.playerName);
playerCards.Add(playerScoreboardCard);
}
public void RemovePlayerCard(string cardTag)
{
//if (playerCards.ContainsKey(cardTag))

View File

@ -0,0 +1,140 @@

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEditor;
using System.Linq;
using System.IO;
public class CubemapTextureBuilder : EditorWindow
{
[MenuItem("Tools/Cubemap Builder")]
public static void OpenWindow()
{
GetWindow<CubemapTextureBuilder>();
}
Texture2D[] textures = new Texture2D[6];
string[] labels = new string[] {
"Right", "Left",
"Top", "Bottom",
"Front", "Back"
};
TextureFormat[] HDRFormats = new TextureFormat[] {
TextureFormat.ASTC_HDR_10x10 ,
TextureFormat.ASTC_HDR_12x12 ,
TextureFormat.ASTC_HDR_4x4 ,
TextureFormat.ASTC_HDR_5x5 ,
TextureFormat.ASTC_HDR_6x6 ,
TextureFormat.ASTC_HDR_8x8 ,
TextureFormat.BC6H ,
TextureFormat.RGBAFloat ,
TextureFormat.RGBAHalf
};
Vector2Int[] placementRects = new Vector2Int[]
{
new Vector2Int(2, 1),
new Vector2Int(0, 1),
new Vector2Int(1, 2),
new Vector2Int(1, 0),
new Vector2Int(1, 1),
new Vector2Int(3, 1),
};
private void OnGUI()
{
for (int i = 0; i < 6; i++)
{
textures[i] = EditorGUILayout.ObjectField(labels[i], textures[i], typeof(Texture2D), false) as Texture2D;
}
if (GUILayout.Button("Build Cubemap"))
{
// Missing Texture
if (textures.Any(t => t == null))
{
EditorUtility.DisplayDialog("Cubemap Builder Error", "One or more texture is missing.", "Ok");
return;
}
// Get size
var size = textures[0].width;
// Not all of the same size or square
if (textures.Any(t => (t.width != size) || (t.height != size)))
{
EditorUtility.DisplayDialog("Cubemap Builder Error", "All the textures need to be the same size and square.", "Ok");
return;
}
var isHDR = HDRFormats.Any(f => f == textures[0].format);
var texturePaths = textures.Select(t => AssetDatabase.GetAssetPath(t)).ToArray();
// Should be ok, ask for the file path.
var path = EditorUtility.SaveFilePanel("Save Cubemap", Path.GetDirectoryName(texturePaths[0]), "Cubemap", isHDR ? "exr" : "png");
if (string.IsNullOrEmpty(path)) return;
// Save the readable flag to restore it afterwards
var readableFlags = textures.Select(t => t.isReadable).ToArray();
// Get the importer and mark the textures as readable
var importers = texturePaths.Select(p => TextureImporter.GetAtPath(p) as TextureImporter).ToArray();
foreach (var importer in importers)
{
importer.isReadable = true;
}
AssetDatabase.Refresh();
foreach (var p in texturePaths)
{
AssetDatabase.ImportAsset(p);
}
// Build the cubemap texture
var cubeTexture = new Texture2D(size * 4, size * 3, isHDR ? TextureFormat.RGBAFloat : TextureFormat.RGBA32, false);
for (int i = 0; i < 6; i++)
{
cubeTexture.SetPixels(placementRects[i].x * size, placementRects[i].y * size, size, size, textures[i].GetPixels(0));
}
cubeTexture.Apply(false);
// Save the texture to the specified path, and destroy the temporary object
var bytes = isHDR ? cubeTexture.EncodeToEXR() : cubeTexture.EncodeToPNG();
File.WriteAllBytes(path, bytes);
DestroyImmediate(cubeTexture);
// Reset the read flags, and reimport everything
for (var i = 0; i < 6; i++)
{
importers[i].isReadable = readableFlags[i];
}
path = path.Remove(0, Application.dataPath.Length - 6);
AssetDatabase.ImportAsset(path);
var cubeImporter = AssetImporter.GetAtPath(path) as TextureImporter;
cubeImporter.textureShape = TextureImporterShape.TextureCube;
cubeImporter.sRGBTexture = false;
cubeImporter.generateCubemap = TextureImporterGenerateCubemap.FullCubemap;
foreach (var p in texturePaths)
{
AssetDatabase.ImportAsset(p);
}
AssetDatabase.ImportAsset(path);
AssetDatabase.Refresh();
}
}
}

View File

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: f7b00d918e7b13c4c8823278d24d708a
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,4 +1,3 @@
using Assets.Scripts.GameSession;
using UnityEngine;
using UnityEngine.SceneManagement;
using UnityEngine.UI;
@ -21,6 +20,6 @@ public class RestartButton : MonoBehaviour
public void RestartGame()
{
GoToScene.GoToSoloMode();
SceneManager.LoadScene("GameScene");
}
}

View File

@ -1,8 +0,0 @@
fileFormatVersion: 2
guid: 7a6cd05b162829143bc4b5dad38146f6
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,23 +0,0 @@
fileFormatVersion: 2
guid: ddf8fb13b61f8474d89b050db1febfc6
AudioImporter:
externalObjects: {}
serializedVersion: 8
defaultSettings:
serializedVersion: 2
loadType: 0
sampleRateSetting: 0
sampleRateOverride: 44100
compressionFormat: 1
quality: 1
conversionMode: 0
preloadAudioData: 0
platformSettingOverrides: {}
forceToMono: 0
normalize: 1
loadInBackground: 0
ambisonic: 0
3D: 1
userData:
assetBundleName:
assetBundleVariant:

BIN
Assets/Sounds/jumping_1-6452.mp3 (Stored with Git LFS)

Binary file not shown.

View File

@ -1,23 +0,0 @@
fileFormatVersion: 2
guid: 1349cd948201da94d803d355043b3e6b
AudioImporter:
externalObjects: {}
serializedVersion: 8
defaultSettings:
serializedVersion: 2
loadType: 0
sampleRateSetting: 0
sampleRateOverride: 44100
compressionFormat: 1
quality: 1
conversionMode: 0
preloadAudioData: 0
platformSettingOverrides: {}
forceToMono: 0
normalize: 1
loadInBackground: 0
ambisonic: 0
3D: 1
userData:
assetBundleName:
assetBundleVariant:

View File

@ -12,13 +12,13 @@ PlayerSettings:
targetDevice: 2
useOnDemandResources: 0
accelerometerFrequency: 60
companyName: ElPoyo
companyName: VladimirPirozhenko
productName: AwesomeRunner
defaultCursor: {fileID: 0}
cursorHotspot: {x: 0, y: 0}
m_SplashScreenBackgroundColor: {r: 0.13725491, g: 0.12156863, b: 0.1254902, a: 1}
m_ShowUnitySplashScreen: 1
m_ShowUnitySplashLogo: 0
m_ShowUnitySplashLogo: 1
m_SplashScreenOverlayOpacity: 1
m_SplashScreenAnimation: 1
m_SplashScreenLogoStyle: 1
@ -94,7 +94,7 @@ PlayerSettings:
bakeCollisionMeshes: 1
forceSingleInstance: 0
useFlipModelSwapchain: 1
resizableWindow: 1
resizableWindow: 0
useMacAppStoreValidation: 0
macAppStoreCategory: public.app-category.games
gpuSkinning: 1
@ -164,7 +164,6 @@ PlayerSettings:
androidMinAspectRatio: 1
applicationIdentifier:
Android: com.VladimirPirozhenko.AwesomeRunner
Standalone: com.ElPoyo.AwesomeRunner
buildNumber:
Standalone: 0
VisionOS: 0