diff --git a/BlueWater/Assets/01.Scenes/02.Combat_2D.unity b/BlueWater/Assets/01.Scenes/02.Combat_2D.unity index 16f95d97d..14acad039 100644 --- a/BlueWater/Assets/01.Scenes/02.Combat_2D.unity +++ b/BlueWater/Assets/01.Scenes/02.Combat_2D.unity @@ -245,6 +245,113 @@ PrefabInstance: m_AddedGameObjects: [] m_AddedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: 7ef15b3b75916c044aa8aa197b362208, type: 3} +--- !u!1 &80492221 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 80492222} + - component: {fileID: 80492225} + - component: {fileID: 80492224} + - component: {fileID: 80492223} + m_Layer: 21 + m_Name: Wall (3) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &80492222 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 80492221} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: -5.5} + m_LocalScale: {x: 12, y: 5, z: 2.5} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 1001465160} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!65 &80492223 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 80492221} + m_Material: {fileID: 0} + m_IncludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_ExcludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_LayerOverridePriority: 0 + m_IsTrigger: 0 + m_ProvidesContacts: 0 + m_Enabled: 1 + serializedVersion: 3 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!23 &80492224 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 80492221} + m_Enabled: 0 + 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_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 31321ba15b8f8eb4c954353edc038b1d, 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!33 &80492225 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 80492221} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &104135925 GameObject: m_ObjectHideFlags: 0 @@ -2285,114 +2392,6 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 704479487} m_CullTransparentMesh: 1 ---- !u!1 &746104460 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 746104461} - - component: {fileID: 746104464} - - component: {fileID: 746104463} - - component: {fileID: 746104462} - m_Layer: 3 - m_Name: Plane - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &746104461 -Transform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 746104460} - serializedVersion: 2 - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} - m_LocalScale: {x: 3, y: 3, z: 3} - m_ConstrainProportionsScale: 1 - m_Children: [] - m_Father: {fileID: 1897782244} - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!64 &746104462 -MeshCollider: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 746104460} - m_Material: {fileID: 0} - m_IncludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_ExcludeLayers: - serializedVersion: 2 - m_Bits: 0 - m_LayerOverridePriority: 0 - m_IsTrigger: 0 - m_ProvidesContacts: 0 - m_Enabled: 1 - serializedVersion: 5 - m_Convex: 0 - m_CookingOptions: 30 - m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0} ---- !u!23 &746104463 -MeshRenderer: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 746104460} - 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_RenderingLayerMask: 1 - m_RendererPriority: 0 - m_Materials: - - {fileID: 2100000, guid: 905bd8d138fdc914cb8f14df883586c8, 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!33 &746104464 -MeshFilter: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 746104460} - m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &784283201 GameObject: m_ObjectHideFlags: 0 @@ -3911,6 +3910,41 @@ PrefabInstance: m_AddedGameObjects: [] m_AddedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: b82511a1823faf14f97c60a0e6984872, type: 3} +--- !u!1 &1001465159 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1001465160} + m_Layer: 3 + m_Name: Walls + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1001465160 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1001465159} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 1257574119} + - {fileID: 1057498218} + - {fileID: 1567401482} + - {fileID: 80492222} + m_Father: {fileID: 1658435464} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1033584364 GameObject: m_ObjectHideFlags: 0 @@ -3950,9 +3984,9 @@ MonoBehaviour: k__BackingField: {fileID: 1049575630} k__BackingField: {fileID: 259569763562170414} k__BackingField: {fileID: 1842100125} - k__BackingField: {fileID: 0} - k__BackingField: {fileID: 0} - k__BackingField: {fileID: 0} + k__BackingField: {fileID: 6661296397982603977} + k__BackingField: {fileID: 1906451879} + k__BackingField: {fileID: 5432215145398930728} --- !u!114 &1033584366 MonoBehaviour: m_ObjectHideFlags: 0 @@ -4151,6 +4185,113 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1049575628} m_CullTransparentMesh: 0 +--- !u!1 &1057498217 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1057498218} + - component: {fileID: 1057498221} + - component: {fileID: 1057498220} + - component: {fileID: 1057498219} + m_Layer: 21 + m_Name: Wall (1) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1057498218 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1057498217} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 5.5} + m_LocalScale: {x: 12, y: 5, z: 2.5} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 1001465160} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!65 &1057498219 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1057498217} + m_Material: {fileID: 0} + m_IncludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_ExcludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_LayerOverridePriority: 0 + m_IsTrigger: 0 + m_ProvidesContacts: 0 + m_Enabled: 1 + serializedVersion: 3 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!23 &1057498220 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1057498217} + m_Enabled: 0 + 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_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 31321ba15b8f8eb4c954353edc038b1d, 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!33 &1057498221 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1057498217} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &1068410569 GameObject: m_ObjectHideFlags: 0 @@ -4452,6 +4593,113 @@ MeshCollider: m_Convex: 0 m_CookingOptions: 30 m_Mesh: {fileID: 0} +--- !u!1 &1257574118 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1257574119} + - component: {fileID: 1257574122} + - component: {fileID: 1257574121} + - component: {fileID: 1257574120} + m_Layer: 21 + m_Name: Wall + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1257574119 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1257574118} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -5.5, y: 0, z: 0} + m_LocalScale: {x: 1, y: 5, z: 12} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 1001465160} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!65 &1257574120 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1257574118} + m_Material: {fileID: 0} + m_IncludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_ExcludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_LayerOverridePriority: 0 + m_IsTrigger: 0 + m_ProvidesContacts: 0 + m_Enabled: 1 + serializedVersion: 3 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!23 &1257574121 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1257574118} + m_Enabled: 0 + 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_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 31321ba15b8f8eb4c954353edc038b1d, 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!33 &1257574122 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1257574118} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &1257784068 GameObject: m_ObjectHideFlags: 0 @@ -6519,6 +6767,113 @@ Transform: m_Children: [] m_Father: {fileID: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1567401481 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1567401482} + - component: {fileID: 1567401485} + - component: {fileID: 1567401484} + - component: {fileID: 1567401483} + m_Layer: 21 + m_Name: Wall (2) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1567401482 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1567401481} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 5.5, y: 0, z: 0} + m_LocalScale: {x: 1, y: 5, z: 12} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 1001465160} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!65 &1567401483 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1567401481} + m_Material: {fileID: 0} + m_IncludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_ExcludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_LayerOverridePriority: 0 + m_IsTrigger: 0 + m_ProvidesContacts: 0 + m_Enabled: 1 + serializedVersion: 3 + m_Size: {x: 1, y: 1, z: 1} + m_Center: {x: 0, y: 0, z: 0} +--- !u!23 &1567401484 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1567401481} + m_Enabled: 0 + 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_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 31321ba15b8f8eb4c954353edc038b1d, 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!33 &1567401485 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1567401481} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &1589901698 GameObject: m_ObjectHideFlags: 0 @@ -6669,6 +7024,115 @@ RectTransform: type: 3} m_PrefabInstance: {fileID: 5432215145398930727} m_PrefabAsset: {fileID: 0} +--- !u!1 &1658435463 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1658435464} + - component: {fileID: 1658435467} + - component: {fileID: 1658435466} + - component: {fileID: 1658435465} + m_Layer: 3 + m_Name: Ground + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1658435464 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1658435463} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 2.5, y: 2.5, z: 2.5} + m_ConstrainProportionsScale: 1 + m_Children: + - {fileID: 1001465160} + m_Father: {fileID: 1897782244} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!64 &1658435465 +MeshCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1658435463} + m_Material: {fileID: 0} + m_IncludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_ExcludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_LayerOverridePriority: 0 + m_IsTrigger: 0 + m_ProvidesContacts: 0 + m_Enabled: 1 + serializedVersion: 5 + m_Convex: 0 + m_CookingOptions: 30 + m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0} +--- !u!23 &1658435466 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1658435463} + 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_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: bbf7dcc03516d1645a9ba2cef5d056c4, 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!33 &1658435467 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1658435463} + m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0} --- !u!1 &1715186577 GameObject: m_ObjectHideFlags: 0 @@ -6878,6 +7342,53 @@ PrefabInstance: m_AddedGameObjects: [] m_AddedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: b82511a1823faf14f97c60a0e6984872, type: 3} +--- !u!1 &1765958668 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1765958670} + - component: {fileID: 1765958669} + m_Layer: 0 + m_Name: InputKeyManager + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1765958669 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1765958668} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 56df21ea9c4a2754891388a52bc934ec, type: 3} + m_Name: + m_EditorClassIdentifier: + _persistent: 1 + actionAsset: {fileID: -944628639613478452, guid: 0acb404847404484198cbf94e6929af2, + type: 3} +--- !u!4 &1765958670 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1765958668} + 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_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1816611988 GameObject: m_ObjectHideFlags: 0 @@ -7519,7 +8030,7 @@ Transform: m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: - - {fileID: 746104461} + - {fileID: 1658435464} m_Father: {fileID: 104135926} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1001 &1906451878 @@ -7690,6 +8201,18 @@ PrefabInstance: m_AddedGameObjects: [] m_AddedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: d96bf988529067d4383a3a91281636c7, type: 3} +--- !u!114 &1906451879 stripped +MonoBehaviour: + m_CorrespondingSourceObject: {fileID: 4750452470218991809, guid: d96bf988529067d4383a3a91281636c7, + type: 3} + m_PrefabInstance: {fileID: 1906451878} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: b87a52e3ff43cf147b64090e904d8797, type: 3} + m_Name: + m_EditorClassIdentifier: --- !u!224 &1906451880 stripped RectTransform: m_CorrespondingSourceObject: {fileID: 6057102563371345699, guid: d96bf988529067d4383a3a91281636c7, @@ -7763,37 +8286,6 @@ Transform: - {fileID: 474440006} m_Father: {fileID: 26417292} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1 &2001483464 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 2001483465} - m_Layer: 0 - m_Name: GameObject - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &2001483465 -Transform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 2001483464} - serializedVersion: 2 - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: -0.5541164, y: -2.529393, z: 16.454443} - 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!1001 &2002782310 PrefabInstance: m_ObjectHideFlags: 0 @@ -8167,7 +8659,7 @@ MonoBehaviour: m_EditorClassIdentifier: m_Actions: {fileID: -944628639613478452, guid: 0acb404847404484198cbf94e6929af2, type: 3} - m_NotificationBehavior: 0 + m_NotificationBehavior: 2 m_UIInputModule: {fileID: 0} m_DeviceLostEvent: m_PersistentCalls: @@ -8178,10 +8670,142 @@ MonoBehaviour: m_ControlsChangedEvent: m_PersistentCalls: m_Calls: [] - m_ActionEvents: [] + m_ActionEvents: + - m_PersistentCalls: + m_Calls: [] + m_ActionId: e46165d9-8066-4400-8950-9b7d4bb9ca75 + m_ActionName: 'Player/Move[/Keyboard/w,/Keyboard/s,/Keyboard/a,/Keyboard/d]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: 7d9814fb-48e0-4717-91c3-0c7b7d99972c + m_ActionName: 'Player/AssaultMode[/Keyboard/v]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: 367e7267-d329-439d-9806-5e960b8114b5 + m_ActionName: 'Player/Interaction[/Keyboard/e]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: a28fe5f5-b2a2-4794-8f99-fa2494aedfc3 + m_ActionName: 'Player/InteractionHold[/Keyboard/e]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: 548e1aff-2de9-4dcc-8fe3-6c20ee0e74d4 + m_ActionName: 'Player/Zkey[/Keyboard/z]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: e520b814-2e0b-4d05-853e-ac1a35bb6b51 + m_ActionName: 'Player/TakeAim[/Keyboard/space]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: c8a82170-8a07-4432-b22f-9ec40486ed27 + m_ActionName: 'Player/Cancel[/Keyboard/f]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: bb26b6ad-feae-49d8-a4d8-3633bcabfcab + m_ActionName: 'Player/Targeting[/Keyboard/q]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: c3e552b9-a9be-4d38-8cde-27cc60f7888f + m_ActionName: 'Player/TargetingHold[/Keyboard/q]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: 1558b861-5937-46f7-8887-3f322044049b + m_ActionName: 'Player/SpawnInIsladnPlayer[/Keyboard/t]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: b5508379-f9b3-45f9-ba2e-c16fb67bb36a + m_ActionName: 'Player/CancelHold[/Keyboard/f]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: 5042e547-e870-4479-8263-b143f4d03597 + m_ActionName: 'Player/Attack[/Mouse/leftButton,/Keyboard/k]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: bde6ac11-b3da-4cdd-a8a9-b11db01d47e3 + m_ActionName: 'Player/ActivateMainSkill[/Mouse/rightButton]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: 2d9a2349-b5a2-4926-a6e8-41abf2e24a3a + m_ActionName: 'Player/ToggleLaunchMode[/Mouse/rightButton]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: 36407aa9-c5a9-4654-8452-ac5c52abf32f + m_ActionName: 'Player/LaunchCannon[/Mouse/leftButton]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: 6e363e5e-d384-4b7e-a9df-91159f5523ad + m_ActionName: 'Player/ShiftKey[/Keyboard/shift]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: c66de4c8-5638-4085-9856-105d2d2af71b + m_ActionName: 'Player/BuildMode[/Keyboard/r]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: 1a1c112e-8c2b-47b5-b6ff-e7c113db0b1f + m_ActionName: 'Player/ItemInventory[/Keyboard/i]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: 4984fb85-de31-4918-9a06-61edbd3502e8 + m_ActionName: 'Player/Esc[/Keyboard/escape]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: 26cdda4e-9797-43df-a511-7745f1de2567 + m_ActionName: 'Camera/Zoom[/Mouse/scroll/y]' + - m_PersistentCalls: + m_Calls: [] + m_ActionId: d9db46b6-0228-4e7f-8b51-53cae3ccc330 + m_ActionName: 'Camera/Rotate[/Mouse/rightButton,/Mouse/leftButton]' + - m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 8220628629306241922} + m_TargetAssemblyTypeName: BlueWaterProject.CombatInput, Assembly-CSharp + m_MethodName: OnMove + m_Mode: 0 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + m_ActionId: 4714fdf1-f399-40c7-b623-660c9bfff052 + m_ActionName: 'Combat/Move[/Keyboard/w,/Keyboard/s,/Keyboard/a,/Keyboard/d]' + - m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 8220628629306241922} + m_TargetAssemblyTypeName: BlueWaterProject.CombatInput, Assembly-CSharp + m_MethodName: OnAttack + m_Mode: 0 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + m_ActionId: 5ff50411-308e-490e-acb2-e1001785169d + m_ActionName: 'Combat/Attack[/Mouse/leftButton,/Keyboard/k]' + - m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 8220628629306241922} + m_TargetAssemblyTypeName: BlueWaterProject.CombatInput, Assembly-CSharp + m_MethodName: OnDash + m_Mode: 0 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + m_ActionId: 07c70113-456d-4ae6-a273-92bfa09153c2 + m_ActionName: 'Combat/Dash[/Keyboard/space]' m_NeverAutoSwitchControlSchemes: 0 m_DefaultControlScheme: - m_DefaultActionMap: Player + m_DefaultActionMap: Combat m_SplitScreenIndex: -1 m_Camera: {fileID: 0} --- !u!136 &867655862727142037 @@ -8346,7 +8970,7 @@ Rigidbody: m_ImplicitTensor: 1 m_UseGravity: 0 m_IsKinematic: 0 - m_Interpolate: 1 + m_Interpolate: 0 m_Constraints: 116 m_CollisionDetection: 2 --- !u!199 &4374139373427446774 @@ -13661,6 +14285,18 @@ PrefabInstance: m_AddedGameObjects: [] m_AddedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: 69cc62c186ba8fe44af29df72fb672ce, type: 3} +--- !u!114 &5432215145398930728 stripped +MonoBehaviour: + m_CorrespondingSourceObject: {fileID: 2819079776940216040, guid: 69cc62c186ba8fe44af29df72fb672ce, + type: 3} + m_PrefabInstance: {fileID: 5432215145398930727} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: ff0b44300107a9b4ca017d7805271ac4, type: 3} + m_Name: + m_EditorClassIdentifier: --- !u!1 &5914316972171281344 GameObject: m_ObjectHideFlags: 0 @@ -18620,6 +19256,18 @@ PrefabInstance: m_AddedGameObjects: [] m_AddedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: d96bf988529067d4383a3a91281636c7, type: 3} +--- !u!114 &6661296397982603977 stripped +MonoBehaviour: + m_CorrespondingSourceObject: {fileID: 4750452470218991809, guid: d96bf988529067d4383a3a91281636c7, + type: 3} + m_PrefabInstance: {fileID: 6661296397982603976} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: b87a52e3ff43cf147b64090e904d8797, type: 3} + m_Name: + m_EditorClassIdentifier: --- !u!224 &6661296397982603978 stripped RectTransform: m_CorrespondingSourceObject: {fileID: 6057102563371345699, guid: d96bf988529067d4383a3a91281636c7, @@ -18687,10 +19335,6 @@ MonoBehaviour: dashSpeed: 20 dashTime: 0.2 dashCooldown: 0.5 - groundCheckDistance: 2 - groundLayer: - serializedVersion: 2 - m_Bits: 8 --- !u!114 &8220628629306241922 MonoBehaviour: m_ObjectHideFlags: 0 @@ -18761,12 +19405,12 @@ SceneRoots: - {fileID: 1068410571} - {fileID: 1560091183} - {fileID: 1449861392} + - {fileID: 1765958670} - {fileID: 549059392} - {fileID: 2943282178093281560} - {fileID: 104135926} - {fileID: 1383322271} - {fileID: 1969962454} - - {fileID: 2001483465} - {fileID: 689667138} - {fileID: 2002782310} - {fileID: 1748839488} diff --git a/BlueWater/Assets/02.Scripts/BlueWater.cs b/BlueWater/Assets/02.Scripts/BlueWater.cs index ffddb2b38..51f2b8fd9 100644 --- a/BlueWater/Assets/02.Scripts/BlueWater.cs +++ b/BlueWater/Assets/02.Scripts/BlueWater.cs @@ -135,15 +135,6 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable ""interactions"": """", ""initialStateCheck"": false }, - { - ""name"": ""Dash"", - ""type"": ""Button"", - ""id"": ""c68960a5-036f-4304-8d05-25778470ecfd"", - ""expectedControlType"": ""Button"", - ""processors"": """", - ""interactions"": """", - ""initialStateCheck"": false - }, { ""name"": ""ActivateMainSkill"", ""type"": ""Button"", @@ -396,17 +387,6 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable ""isComposite"": false, ""isPartOfComposite"": false }, - { - ""name"": """", - ""id"": ""5a134753-6868-4dec-9b0e-5839b48f7417"", - ""path"": ""/space"", - ""interactions"": """", - ""processors"": """", - ""groups"": ""Keyboard&Mouse"", - ""action"": ""Dash"", - ""isComposite"": false, - ""isPartOfComposite"": false - }, { ""name"": """", ""id"": ""f1364876-ede7-4831-b23e-532d6995031e"", @@ -546,31 +526,31 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable ] }, { - ""name"": ""Unit"", - ""id"": ""72deb161-83b9-4d14-8bcf-0bd0c122f76f"", + ""name"": ""Combat"", + ""id"": ""fcad259b-ca44-46e3-b008-1297fa7be828"", ""actions"": [ { - ""name"": ""SelectUnit"", + ""name"": ""Move"", + ""type"": ""Value"", + ""id"": ""4714fdf1-f399-40c7-b623-660c9bfff052"", + ""expectedControlType"": ""Vector2"", + ""processors"": """", + ""interactions"": """", + ""initialStateCheck"": true + }, + { + ""name"": ""Attack"", ""type"": ""Button"", - ""id"": ""2c1978d2-b4be-453a-9413-7b54903dbf38"", + ""id"": ""5ff50411-308e-490e-acb2-e1001785169d"", ""expectedControlType"": ""Button"", ""processors"": """", ""interactions"": """", ""initialStateCheck"": false }, { - ""name"": ""CancelSelectedUnit"", + ""name"": ""Dash"", ""type"": ""Button"", - ""id"": ""952be7b5-8952-47b7-a2db-ced6517d161a"", - ""expectedControlType"": ""Button"", - ""processors"": """", - ""interactions"": """", - ""initialStateCheck"": false - }, - { - ""name"": ""MoveUnit"", - ""type"": ""Button"", - ""id"": ""2fe8434e-42e2-4b88-b0b3-0b2b4f8596a8"", + ""id"": ""07c70113-456d-4ae6-a273-92bfa09153c2"", ""expectedControlType"": ""Button"", ""processors"": """", ""interactions"": """", @@ -578,36 +558,91 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable } ], ""bindings"": [ + { + ""name"": ""WASD"", + ""id"": ""362fb18c-8b50-4fcd-9bc9-9fcab5fd2ce5"", + ""path"": ""2DVector"", + ""interactions"": """", + ""processors"": """", + ""groups"": """", + ""action"": ""Move"", + ""isComposite"": true, + ""isPartOfComposite"": false + }, + { + ""name"": ""up"", + ""id"": ""36746c9d-eca6-4ff8-bcec-2d658d907744"", + ""path"": ""/w"", + ""interactions"": """", + ""processors"": """", + ""groups"": ""Keyboard&Mouse"", + ""action"": ""Move"", + ""isComposite"": false, + ""isPartOfComposite"": true + }, + { + ""name"": ""down"", + ""id"": ""8420a87e-ccc1-4940-addd-1516ac2896af"", + ""path"": ""/s"", + ""interactions"": """", + ""processors"": """", + ""groups"": ""Keyboard&Mouse"", + ""action"": ""Move"", + ""isComposite"": false, + ""isPartOfComposite"": true + }, + { + ""name"": ""left"", + ""id"": ""6ac0b570-a29a-40f9-b039-c4085ef669a8"", + ""path"": ""/a"", + ""interactions"": """", + ""processors"": """", + ""groups"": ""Keyboard&Mouse"", + ""action"": ""Move"", + ""isComposite"": false, + ""isPartOfComposite"": true + }, + { + ""name"": ""right"", + ""id"": ""975926ee-895b-4858-b17d-c8ccc3142fb4"", + ""path"": ""/d"", + ""interactions"": """", + ""processors"": """", + ""groups"": ""Keyboard&Mouse"", + ""action"": ""Move"", + ""isComposite"": false, + ""isPartOfComposite"": true + }, { ""name"": """", - ""id"": ""2daa9903-ce4b-4c8d-9347-5f59b09e8674"", + ""id"": ""17f1b73a-900f-477d-b3aa-2cfc0335591f"", ""path"": ""/leftButton"", ""interactions"": """", ""processors"": """", ""groups"": ""Keyboard&Mouse"", - ""action"": ""SelectUnit"", + ""action"": ""Attack"", ""isComposite"": false, ""isPartOfComposite"": false }, { ""name"": """", - ""id"": ""76632044-5edc-4dba-97aa-64d5173c78ec"", - ""path"": ""/rightButton"", + ""id"": ""acdb5d7e-efe0-4c9a-9c7c-c6810fc37c72"", + ""path"": ""/k"", ""interactions"": """", ""processors"": """", ""groups"": ""Keyboard&Mouse"", - ""action"": ""MoveUnit"", + ""action"": ""Attack"", ""isComposite"": false, ""isPartOfComposite"": false }, { ""name"": """", - ""id"": ""e768abd0-e04f-4441-b6b3-09f456041cd8"", - ""path"": ""/escape"", + ""id"": ""4a22ea68-00e5-46bf-b622-b6ceb0351141"", + ""path"": ""/space"", ""interactions"": """", ""processors"": """", ""groups"": ""Keyboard&Mouse"", - ""action"": ""CancelSelectedUnit"", + ""action"": ""Dash"", ""isComposite"": false, ""isPartOfComposite"": false } @@ -658,7 +693,6 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable m_Player_SpawnInIsladnPlayer = m_Player.FindAction("SpawnInIsladnPlayer", throwIfNotFound: true); m_Player_CancelHold = m_Player.FindAction("CancelHold", throwIfNotFound: true); m_Player_Attack = m_Player.FindAction("Attack", throwIfNotFound: true); - m_Player_Dash = m_Player.FindAction("Dash", throwIfNotFound: true); m_Player_ActivateMainSkill = m_Player.FindAction("ActivateMainSkill", throwIfNotFound: true); m_Player_ToggleLaunchMode = m_Player.FindAction("ToggleLaunchMode", throwIfNotFound: true); m_Player_LaunchCannon = m_Player.FindAction("LaunchCannon", throwIfNotFound: true); @@ -670,11 +704,11 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable m_Camera = asset.FindActionMap("Camera", throwIfNotFound: true); m_Camera_Zoom = m_Camera.FindAction("Zoom", throwIfNotFound: true); m_Camera_Rotate = m_Camera.FindAction("Rotate", throwIfNotFound: true); - // Unit - m_Unit = asset.FindActionMap("Unit", throwIfNotFound: true); - m_Unit_SelectUnit = m_Unit.FindAction("SelectUnit", throwIfNotFound: true); - m_Unit_CancelSelectedUnit = m_Unit.FindAction("CancelSelectedUnit", throwIfNotFound: true); - m_Unit_MoveUnit = m_Unit.FindAction("MoveUnit", throwIfNotFound: true); + // Combat + m_Combat = asset.FindActionMap("Combat", throwIfNotFound: true); + m_Combat_Move = m_Combat.FindAction("Move", throwIfNotFound: true); + m_Combat_Attack = m_Combat.FindAction("Attack", throwIfNotFound: true); + m_Combat_Dash = m_Combat.FindAction("Dash", throwIfNotFound: true); } public void Dispose() @@ -748,7 +782,6 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable private readonly InputAction m_Player_SpawnInIsladnPlayer; private readonly InputAction m_Player_CancelHold; private readonly InputAction m_Player_Attack; - private readonly InputAction m_Player_Dash; private readonly InputAction m_Player_ActivateMainSkill; private readonly InputAction m_Player_ToggleLaunchMode; private readonly InputAction m_Player_LaunchCannon; @@ -772,7 +805,6 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable public InputAction @SpawnInIsladnPlayer => m_Wrapper.m_Player_SpawnInIsladnPlayer; public InputAction @CancelHold => m_Wrapper.m_Player_CancelHold; public InputAction @Attack => m_Wrapper.m_Player_Attack; - public InputAction @Dash => m_Wrapper.m_Player_Dash; public InputAction @ActivateMainSkill => m_Wrapper.m_Player_ActivateMainSkill; public InputAction @ToggleLaunchMode => m_Wrapper.m_Player_ToggleLaunchMode; public InputAction @LaunchCannon => m_Wrapper.m_Player_LaunchCannon; @@ -825,9 +857,6 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable @Attack.started += instance.OnAttack; @Attack.performed += instance.OnAttack; @Attack.canceled += instance.OnAttack; - @Dash.started += instance.OnDash; - @Dash.performed += instance.OnDash; - @Dash.canceled += instance.OnDash; @ActivateMainSkill.started += instance.OnActivateMainSkill; @ActivateMainSkill.performed += instance.OnActivateMainSkill; @ActivateMainSkill.canceled += instance.OnActivateMainSkill; @@ -889,9 +918,6 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable @Attack.started -= instance.OnAttack; @Attack.performed -= instance.OnAttack; @Attack.canceled -= instance.OnAttack; - @Dash.started -= instance.OnDash; - @Dash.performed -= instance.OnDash; - @Dash.canceled -= instance.OnDash; @ActivateMainSkill.started -= instance.OnActivateMainSkill; @ActivateMainSkill.performed -= instance.OnActivateMainSkill; @ActivateMainSkill.canceled -= instance.OnActivateMainSkill; @@ -985,67 +1011,67 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable } public CameraActions @Camera => new CameraActions(this); - // Unit - private readonly InputActionMap m_Unit; - private List m_UnitActionsCallbackInterfaces = new List(); - private readonly InputAction m_Unit_SelectUnit; - private readonly InputAction m_Unit_CancelSelectedUnit; - private readonly InputAction m_Unit_MoveUnit; - public struct UnitActions + // Combat + private readonly InputActionMap m_Combat; + private List m_CombatActionsCallbackInterfaces = new List(); + private readonly InputAction m_Combat_Move; + private readonly InputAction m_Combat_Attack; + private readonly InputAction m_Combat_Dash; + public struct CombatActions { private @BlueWater m_Wrapper; - public UnitActions(@BlueWater wrapper) { m_Wrapper = wrapper; } - public InputAction @SelectUnit => m_Wrapper.m_Unit_SelectUnit; - public InputAction @CancelSelectedUnit => m_Wrapper.m_Unit_CancelSelectedUnit; - public InputAction @MoveUnit => m_Wrapper.m_Unit_MoveUnit; - public InputActionMap Get() { return m_Wrapper.m_Unit; } + public CombatActions(@BlueWater wrapper) { m_Wrapper = wrapper; } + public InputAction @Move => m_Wrapper.m_Combat_Move; + public InputAction @Attack => m_Wrapper.m_Combat_Attack; + public InputAction @Dash => m_Wrapper.m_Combat_Dash; + public InputActionMap Get() { return m_Wrapper.m_Combat; } public void Enable() { Get().Enable(); } public void Disable() { Get().Disable(); } public bool enabled => Get().enabled; - public static implicit operator InputActionMap(UnitActions set) { return set.Get(); } - public void AddCallbacks(IUnitActions instance) + public static implicit operator InputActionMap(CombatActions set) { return set.Get(); } + public void AddCallbacks(ICombatActions instance) { - if (instance == null || m_Wrapper.m_UnitActionsCallbackInterfaces.Contains(instance)) return; - m_Wrapper.m_UnitActionsCallbackInterfaces.Add(instance); - @SelectUnit.started += instance.OnSelectUnit; - @SelectUnit.performed += instance.OnSelectUnit; - @SelectUnit.canceled += instance.OnSelectUnit; - @CancelSelectedUnit.started += instance.OnCancelSelectedUnit; - @CancelSelectedUnit.performed += instance.OnCancelSelectedUnit; - @CancelSelectedUnit.canceled += instance.OnCancelSelectedUnit; - @MoveUnit.started += instance.OnMoveUnit; - @MoveUnit.performed += instance.OnMoveUnit; - @MoveUnit.canceled += instance.OnMoveUnit; + if (instance == null || m_Wrapper.m_CombatActionsCallbackInterfaces.Contains(instance)) return; + m_Wrapper.m_CombatActionsCallbackInterfaces.Add(instance); + @Move.started += instance.OnMove; + @Move.performed += instance.OnMove; + @Move.canceled += instance.OnMove; + @Attack.started += instance.OnAttack; + @Attack.performed += instance.OnAttack; + @Attack.canceled += instance.OnAttack; + @Dash.started += instance.OnDash; + @Dash.performed += instance.OnDash; + @Dash.canceled += instance.OnDash; } - private void UnregisterCallbacks(IUnitActions instance) + private void UnregisterCallbacks(ICombatActions instance) { - @SelectUnit.started -= instance.OnSelectUnit; - @SelectUnit.performed -= instance.OnSelectUnit; - @SelectUnit.canceled -= instance.OnSelectUnit; - @CancelSelectedUnit.started -= instance.OnCancelSelectedUnit; - @CancelSelectedUnit.performed -= instance.OnCancelSelectedUnit; - @CancelSelectedUnit.canceled -= instance.OnCancelSelectedUnit; - @MoveUnit.started -= instance.OnMoveUnit; - @MoveUnit.performed -= instance.OnMoveUnit; - @MoveUnit.canceled -= instance.OnMoveUnit; + @Move.started -= instance.OnMove; + @Move.performed -= instance.OnMove; + @Move.canceled -= instance.OnMove; + @Attack.started -= instance.OnAttack; + @Attack.performed -= instance.OnAttack; + @Attack.canceled -= instance.OnAttack; + @Dash.started -= instance.OnDash; + @Dash.performed -= instance.OnDash; + @Dash.canceled -= instance.OnDash; } - public void RemoveCallbacks(IUnitActions instance) + public void RemoveCallbacks(ICombatActions instance) { - if (m_Wrapper.m_UnitActionsCallbackInterfaces.Remove(instance)) + if (m_Wrapper.m_CombatActionsCallbackInterfaces.Remove(instance)) UnregisterCallbacks(instance); } - public void SetCallbacks(IUnitActions instance) + public void SetCallbacks(ICombatActions instance) { - foreach (var item in m_Wrapper.m_UnitActionsCallbackInterfaces) + foreach (var item in m_Wrapper.m_CombatActionsCallbackInterfaces) UnregisterCallbacks(item); - m_Wrapper.m_UnitActionsCallbackInterfaces.Clear(); + m_Wrapper.m_CombatActionsCallbackInterfaces.Clear(); AddCallbacks(instance); } } - public UnitActions @Unit => new UnitActions(this); + public CombatActions @Combat => new CombatActions(this); private int m_KeyboardMouseSchemeIndex = -1; public InputControlScheme KeyboardMouseScheme { @@ -1078,7 +1104,6 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable void OnSpawnInIsladnPlayer(InputAction.CallbackContext context); void OnCancelHold(InputAction.CallbackContext context); void OnAttack(InputAction.CallbackContext context); - void OnDash(InputAction.CallbackContext context); void OnActivateMainSkill(InputAction.CallbackContext context); void OnToggleLaunchMode(InputAction.CallbackContext context); void OnLaunchCannon(InputAction.CallbackContext context); @@ -1092,10 +1117,10 @@ public partial class @BlueWater: IInputActionCollection2, IDisposable void OnZoom(InputAction.CallbackContext context); void OnRotate(InputAction.CallbackContext context); } - public interface IUnitActions + public interface ICombatActions { - void OnSelectUnit(InputAction.CallbackContext context); - void OnCancelSelectedUnit(InputAction.CallbackContext context); - void OnMoveUnit(InputAction.CallbackContext context); + void OnMove(InputAction.CallbackContext context); + void OnAttack(InputAction.CallbackContext context); + void OnDash(InputAction.CallbackContext context); } } diff --git a/BlueWater/Assets/02.Scripts/BlueWater.inputactions b/BlueWater/Assets/02.Scripts/BlueWater.inputactions index f1197bbe0..76605a841 100644 --- a/BlueWater/Assets/02.Scripts/BlueWater.inputactions +++ b/BlueWater/Assets/02.Scripts/BlueWater.inputactions @@ -113,15 +113,6 @@ "interactions": "", "initialStateCheck": false }, - { - "name": "Dash", - "type": "Button", - "id": "c68960a5-036f-4304-8d05-25778470ecfd", - "expectedControlType": "Button", - "processors": "", - "interactions": "", - "initialStateCheck": false - }, { "name": "ActivateMainSkill", "type": "Button", @@ -374,17 +365,6 @@ "isComposite": false, "isPartOfComposite": false }, - { - "name": "", - "id": "5a134753-6868-4dec-9b0e-5839b48f7417", - "path": "/space", - "interactions": "", - "processors": "", - "groups": "Keyboard&Mouse", - "action": "Dash", - "isComposite": false, - "isPartOfComposite": false - }, { "name": "", "id": "f1364876-ede7-4831-b23e-532d6995031e", @@ -524,31 +504,31 @@ ] }, { - "name": "Unit", - "id": "72deb161-83b9-4d14-8bcf-0bd0c122f76f", + "name": "Combat", + "id": "fcad259b-ca44-46e3-b008-1297fa7be828", "actions": [ { - "name": "SelectUnit", + "name": "Move", + "type": "Value", + "id": "4714fdf1-f399-40c7-b623-660c9bfff052", + "expectedControlType": "Vector2", + "processors": "", + "interactions": "", + "initialStateCheck": true + }, + { + "name": "Attack", "type": "Button", - "id": "2c1978d2-b4be-453a-9413-7b54903dbf38", + "id": "5ff50411-308e-490e-acb2-e1001785169d", "expectedControlType": "Button", "processors": "", "interactions": "", "initialStateCheck": false }, { - "name": "CancelSelectedUnit", + "name": "Dash", "type": "Button", - "id": "952be7b5-8952-47b7-a2db-ced6517d161a", - "expectedControlType": "Button", - "processors": "", - "interactions": "", - "initialStateCheck": false - }, - { - "name": "MoveUnit", - "type": "Button", - "id": "2fe8434e-42e2-4b88-b0b3-0b2b4f8596a8", + "id": "07c70113-456d-4ae6-a273-92bfa09153c2", "expectedControlType": "Button", "processors": "", "interactions": "", @@ -556,36 +536,91 @@ } ], "bindings": [ + { + "name": "WASD", + "id": "362fb18c-8b50-4fcd-9bc9-9fcab5fd2ce5", + "path": "2DVector", + "interactions": "", + "processors": "", + "groups": "", + "action": "Move", + "isComposite": true, + "isPartOfComposite": false + }, + { + "name": "up", + "id": "36746c9d-eca6-4ff8-bcec-2d658d907744", + "path": "/w", + "interactions": "", + "processors": "", + "groups": "Keyboard&Mouse", + "action": "Move", + "isComposite": false, + "isPartOfComposite": true + }, + { + "name": "down", + "id": "8420a87e-ccc1-4940-addd-1516ac2896af", + "path": "/s", + "interactions": "", + "processors": "", + "groups": "Keyboard&Mouse", + "action": "Move", + "isComposite": false, + "isPartOfComposite": true + }, + { + "name": "left", + "id": "6ac0b570-a29a-40f9-b039-c4085ef669a8", + "path": "/a", + "interactions": "", + "processors": "", + "groups": "Keyboard&Mouse", + "action": "Move", + "isComposite": false, + "isPartOfComposite": true + }, + { + "name": "right", + "id": "975926ee-895b-4858-b17d-c8ccc3142fb4", + "path": "/d", + "interactions": "", + "processors": "", + "groups": "Keyboard&Mouse", + "action": "Move", + "isComposite": false, + "isPartOfComposite": true + }, { "name": "", - "id": "2daa9903-ce4b-4c8d-9347-5f59b09e8674", + "id": "17f1b73a-900f-477d-b3aa-2cfc0335591f", "path": "/leftButton", "interactions": "", "processors": "", "groups": "Keyboard&Mouse", - "action": "SelectUnit", + "action": "Attack", "isComposite": false, "isPartOfComposite": false }, { "name": "", - "id": "76632044-5edc-4dba-97aa-64d5173c78ec", - "path": "/rightButton", + "id": "acdb5d7e-efe0-4c9a-9c7c-c6810fc37c72", + "path": "/k", "interactions": "", "processors": "", "groups": "Keyboard&Mouse", - "action": "MoveUnit", + "action": "Attack", "isComposite": false, "isPartOfComposite": false }, { "name": "", - "id": "e768abd0-e04f-4441-b6b3-09f456041cd8", - "path": "/escape", + "id": "4a22ea68-00e5-46bf-b622-b6ceb0351141", + "path": "/space", "interactions": "", "processors": "", "groups": "Keyboard&Mouse", - "action": "CancelSelectedUnit", + "action": "Dash", "isComposite": false, "isPartOfComposite": false } diff --git a/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatAttacker.cs b/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatAttacker.cs new file mode 100644 index 000000000..d6ab7674c --- /dev/null +++ b/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatAttacker.cs @@ -0,0 +1,21 @@ +using Sirenix.OdinInspector; +using UnityEngine; + +// ReSharper disable once CheckNamespace +namespace BlueWaterProject +{ + public class CombatAttacker : MonoBehaviour + { + [HideInInspector] public CombatAnimator combatAnimator; + + private bool useMouseAttack; + + public void HandleAttack() + { + // if (!enableDash || isDashing) return; + // + // StartCoroutine(nameof(DashCoroutine)); + } + } +} + diff --git a/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatAttacker.cs.meta b/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatAttacker.cs.meta new file mode 100644 index 000000000..9a771978d --- /dev/null +++ b/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatAttacker.cs.meta @@ -0,0 +1,2 @@ +fileFormatVersion: 2 +guid: db1e3c9d88cdfcc47aa88870aa44851f diff --git a/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatInput.cs b/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatInput.cs index 9423f49f2..fd3ca3769 100644 --- a/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatInput.cs +++ b/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatInput.cs @@ -15,39 +15,50 @@ namespace BlueWaterProject public delegate void DashInput(); public event DashInput OnDashInputReceived; - public delegate void AttackInput(InputAction.CallbackContext context); + public delegate void AttackInput(bool usedMouse); public event AttackInput OnAttackInputReceived; - private void OnEnable() - { - playerInput.actions.FindAction("Attack").performed += OnAttackEvent; - } - - private void OnDisable() - { - playerInput.actions.FindAction("Attack").performed -= OnAttackEvent; - } - [Button("셋팅 초기화")] private void InitSetting() { playerInput = GetComponent(); } - private void OnMove(InputValue value) + public void OnMove(InputAction.CallbackContext context) { - var movementInput = value.Get(); + var movementInput = context.ReadValue(); OnMoveInputReceived?.Invoke(movementInput); } - private void OnDash() + public void OnDash(InputAction.CallbackContext context) { - OnDashInputReceived?.Invoke(); + if (context.started) + { + OnDashInputReceived?.Invoke(); + } } - private void OnAttackEvent(InputAction.CallbackContext context) + public void OnAttack(InputAction.CallbackContext context) { - OnAttackInputReceived?.Invoke(context); + if (context.started) + { + var device = context.control.device; + bool usedMouse; + + switch (device) + { + case Keyboard: + usedMouse = false; + break; + case Mouse: + usedMouse = true; + break; + default: + return; + } + + OnAttackInputReceived?.Invoke(usedMouse); + } } private void OnItemInventory() diff --git a/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatMovement.cs b/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatMovement.cs index d3087c94b..01a9f6609 100644 --- a/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatMovement.cs +++ b/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatMovement.cs @@ -24,14 +24,6 @@ namespace BlueWaterProject [Range(0f, 5f), Tooltip("대쉬 쿨타임")] [SerializeField] private float dashCooldown = 0.5f; - // Ground - [Range(0.1f, 10.0f), Tooltip("지면 감지 거리")] - [SerializeField] private float groundCheckDistance = 2.0f; - - [SerializeField] private LayerMask groundLayer; - - private Animator Animator => combatAnimator.animator; - private Vector3 currentMoveDirection; private Vector3 previousMoveDirection = Vector3.back; private float finalSpeed; @@ -48,12 +40,9 @@ namespace BlueWaterProject private void FixedUpdate() { - //CheckGround(); - if (isDashing) return; - var finalVelocity = rb.position + currentMoveDirection * (moveSpeed * Time.fixedDeltaTime); - rb.MovePosition(finalVelocity); + HandleMove(); } [Button("셋팅 초기화")] @@ -72,51 +61,6 @@ namespace BlueWaterProject } isMoving = currentMoveDirection != Vector3.zero; } - - public void HandleDash() - { - if (!enableDash || isDashing) return; - - StartCoroutine(nameof(DashCoroutine)); - } - - private IEnumerator DashCoroutine() - { - var dashDirection = previousMoveDirection; - isDashing = true; - enableDash = false; - combatAnimator.SetIsDash(true); - - var elapsedTime = 0f; - while (!Animator.GetCurrentAnimatorStateInfo(0).IsName("DashState")) - { - elapsedTime += Time.deltaTime; - - if (elapsedTime >= 1f) - { - yield break; - } - - yield return null; - } - - var animationLength = Animator.GetCurrentAnimatorStateInfo(0).length; - Animator.speed = animationLength / dashTime; - - while (Animator.GetCurrentAnimatorStateInfo(0).IsName("DashState") && - Animator.GetCurrentAnimatorStateInfo(0).normalizedTime < 1f) - { - var finalVelocity = rb.position + dashDirection * (dashSpeed * Time.fixedDeltaTime); - rb.MovePosition(finalVelocity); - yield return new WaitForFixedUpdate(); - } - - Animator.speed = 1f; - isDashing = false; - combatAnimator.SetIsDash(false); - - StartCoroutine(Utils.CoolDown(dashCooldown, () => enableDash = true)); - } private void MoveAnimation() { @@ -139,6 +83,61 @@ namespace BlueWaterProject }; visualLook.localScale = localScale; } + + private void HandleMove() + { + var finalVelocity = currentMoveDirection * moveSpeed; + rb.velocity = finalVelocity; + } + + // Dash + public void HandleDash() + { + if (!enableDash || isDashing) return; + + StartCoroutine(nameof(DashCoroutine)); + } + + private IEnumerator DashCoroutine() + { + var dashDirection = previousMoveDirection; + isDashing = true; + enableDash = false; + combatAnimator.SetIsDash(true); + + var elapsedTime = 0f; + while (!combatAnimator.animator.GetCurrentAnimatorStateInfo(0).IsName("DashState")) + { + elapsedTime += Time.deltaTime; + + if (elapsedTime >= 1f) + { + yield break; + } + + yield return null; + } + + var animationLength = combatAnimator.animator.GetCurrentAnimatorStateInfo(0).length; + combatAnimator.animator.speed = animationLength / dashTime; + + while (combatAnimator.animator.GetCurrentAnimatorStateInfo(0).IsName("DashState") && + combatAnimator.animator.GetCurrentAnimatorStateInfo(0).normalizedTime < 1f) + { + //var finalVelocity = rb.position + dashDirection * (dashSpeed * Time.fixedDeltaTime); + //rb.MovePosition(finalVelocity); + + var finalVelocity = dashDirection * dashSpeed; + rb.velocity = finalVelocity; + yield return new WaitForFixedUpdate(); + } + + combatAnimator.animator.speed = 1f; + isDashing = false; + combatAnimator.SetIsDash(false); + + StartCoroutine(Utils.CoolDown(dashCooldown, () => enableDash = true)); + } } } diff --git a/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatPlayer.cs b/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatPlayer.cs index c919ecd9e..e9ae6d5ee 100644 --- a/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatPlayer.cs +++ b/BlueWater/Assets/02.Scripts/Character/CombatPlayer2D/CombatPlayer.cs @@ -15,18 +15,12 @@ namespace BlueWaterProject movement.combatAnimator = animator; } - private void OnEnable() + private void Start() { input.OnMoveInputReceived += movement.InputMovementValue; input.OnDashInputReceived += movement.HandleDash; } - private void OnDisable() - { - input.OnMoveInputReceived -= movement.InputMovementValue; - input.OnDashInputReceived -= movement.HandleDash; - } - [Button("셋팅 초기화")] private void InitSetting() { diff --git a/BlueWater/Assets/02.Scripts/InputKeyManager.cs b/BlueWater/Assets/02.Scripts/InputKeyManager.cs new file mode 100644 index 000000000..cd043d1d3 --- /dev/null +++ b/BlueWater/Assets/02.Scripts/InputKeyManager.cs @@ -0,0 +1,71 @@ +using System.Collections.Generic; +using Sirenix.OdinInspector; +using UnityEngine; +using UnityEngine.InputSystem; + +// ReSharper disable once CheckNamespace +namespace BlueWaterProject +{ + public class InputKeyManager : Singleton + { + [SerializeField] private InputActionAsset actionAsset; + public Dictionary> CombatKeyBindings { get; set; } = new(); + + private void Start() + { + LoadBindings(); + } + + private void LoadBindings() + { + foreach (var actionMap in actionAsset.actionMaps) + { + switch (actionMap.name) + { + case "Combat": + CombatKeyBindings = LoadActionMapBindings(actionMap); + break; + // 추가 액션 맵에 대해서도 비슷한 패턴으로 처리 가능 + } + } + } + + private Dictionary> LoadActionMapBindings(InputActionMap actionMap) + { + var bindings = new Dictionary>(); + + foreach (var action in actionMap.actions) + { + var bindingList = new List(); + + foreach (var binding in action.bindings) + { + var path = !string.IsNullOrEmpty(binding.overridePath) ? binding.overridePath : binding.path; + bindingList.Add(path); + } + + if (bindingList.Count > 0) + { + bindings[action.name] = bindingList; + } + } + + return bindings; + } + + [Button("Dictionary 출력")] + private void PrintBindings() + { + PrintActionMapBindings("Combat", CombatKeyBindings); + } + + private void PrintActionMapBindings(string actionMapName, Dictionary> bindings) + { + Debug.Log($"Action Map: {actionMapName}"); + foreach (var entry in bindings) + { + Debug.Log($"Action: {entry.Key}, Bindings: {string.Join(", ", entry.Value)}"); + } + } + } +} \ No newline at end of file diff --git a/BlueWater/Assets/02.Scripts/InputKeyManager.cs.meta b/BlueWater/Assets/02.Scripts/InputKeyManager.cs.meta new file mode 100644 index 000000000..191c06af6 --- /dev/null +++ b/BlueWater/Assets/02.Scripts/InputKeyManager.cs.meta @@ -0,0 +1,2 @@ +fileFormatVersion: 2 +guid: 56df21ea9c4a2754891388a52bc934ec \ No newline at end of file diff --git a/BlueWater/Assets/03.Images/Maps/land_combat.png b/BlueWater/Assets/03.Images/Maps/land_combat.png new file mode 100644 index 000000000..f6032fc4c Binary files /dev/null and b/BlueWater/Assets/03.Images/Maps/land_combat.png differ diff --git a/BlueWater/Assets/03.Images/Maps/land_combat.png.meta b/BlueWater/Assets/03.Images/Maps/land_combat.png.meta new file mode 100644 index 000000000..c5db09ddd --- /dev/null +++ b/BlueWater/Assets/03.Images/Maps/land_combat.png.meta @@ -0,0 +1,140 @@ +fileFormatVersion: 2 +guid: a2c0eba9ac9e3b348a20360173d139e1 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 13 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + flipGreenChannel: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMipmapLimit: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 0 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 0 + swizzle: 50462976 + cookieLightType: 0 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + ignorePlatformSupport: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + - serializedVersion: 3 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + ignorePlatformSupport: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + - serializedVersion: 3 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + ignorePlatformSupport: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + - serializedVersion: 3 + buildTarget: Windows Store Apps + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + ignorePlatformSupport: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 5e97eb03825dee720800000000000000 + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + nameFileIdTable: {} + mipmapLimitGroupName: + pSDRemoveMatte: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/BlueWater/Assets/03.Materials/land_combat.mat b/BlueWater/Assets/03.Materials/land_combat.mat new file mode 100644 index 000000000..e5e316d6a --- /dev/null +++ b/BlueWater/Assets/03.Materials/land_combat.mat @@ -0,0 +1,143 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!21 &2100000 +Material: + serializedVersion: 8 + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: land_combat + m_Shader: {fileID: 4800000, guid: 8d2bb70cbf9db8d4da26e15b26e74248, type: 3} + m_Parent: {fileID: 0} + m_ModifiedSerializedProperties: 0 + m_ValidKeywords: + - _ALPHATEST_ON + m_InvalidKeywords: [] + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: 2450 + stringTagMap: + RenderType: TransparentCutout + disabledShaderPasses: + - MOTIONVECTORS + m_LockedProperties: + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BaseMap: + m_Texture: {fileID: 2800000, guid: a2c0eba9ac9e3b348a20360173d139e1, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 2800000, guid: a2c0eba9ac9e3b348a20360173d139e1, type: 3} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MetallicGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _OcclusionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _ParallaxMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _SpecGlossMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - unity_Lightmaps: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - unity_LightmapsInd: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - unity_ShadowMasks: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + m_Ints: [] + m_Floats: + - _AddPrecomputedVelocity: 0 + - _AlphaClip: 1 + - _AlphaToMask: 1 + - _Blend: 0 + - _BlendModePreserveSpecular: 0 + - _BlendOp: 0 + - _BumpScale: 1 + - _ClearCoatMask: 0 + - _ClearCoatSmoothness: 0 + - _Cull: 2 + - _Cutoff: 0.5 + - _DetailAlbedoMapScale: 1 + - _DetailNormalMapScale: 1 + - _DstBlend: 0 + - _DstBlendAlpha: 0 + - _EnvironmentReflections: 1 + - _GlossMapScale: 0 + - _Glossiness: 0 + - _GlossinessSource: 0 + - _GlossyReflections: 0 + - _Metallic: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.005 + - _QueueOffset: 0 + - _ReceiveShadows: 1 + - _SampleGI: 0 + - _Shininess: 0 + - _Smoothness: 0.5 + - _SmoothnessSource: 0 + - _SmoothnessTextureChannel: 0 + - _SpecSource: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _SrcBlendAlpha: 1 + - _Surface: 0 + - _WorkflowMode: 1 + - _ZWrite: 1 + m_Colors: + - _BaseColor: {r: 1, g: 1, b: 1, a: 1} + - _Color: {r: 1, g: 1, b: 1, a: 1} + - _EmissionColor: {r: 0, g: 0, b: 0, a: 1} + - _SpecColor: {r: 0.19999996, g: 0.19999996, b: 0.19999996, a: 1} + m_BuildTextureStacks: [] + m_AllowLocking: 1 +--- !u!114 &1271948002411579340 +MonoBehaviour: + m_ObjectHideFlags: 11 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d0353a89b1f911e48b9e16bdc9f2e058, type: 3} + m_Name: + m_EditorClassIdentifier: + version: 9 diff --git a/BlueWater/Assets/03.Materials/land_combat.mat.meta b/BlueWater/Assets/03.Materials/land_combat.mat.meta new file mode 100644 index 000000000..a351256e3 --- /dev/null +++ b/BlueWater/Assets/03.Materials/land_combat.mat.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bbf7dcc03516d1645a9ba2cef5d056c4 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: