From 9fd4e13d34af61be59b1b6dd129c0496b26adfd8 Mon Sep 17 00:00:00 2001 From: Alexandre Coirier Date: Tue, 3 Nov 2026 22:58:10 +0100 Subject: [PATCH] feat: Event & Teleporter --- Assets/_Content/Materials.meta | 8 + Assets/_Content/Materials/M_Heal.mat | 141 + Assets/_Content/Materials/M_Heal.mat.meta | 8 + Assets/_Content/Materials/M_WorldGrid.mat | 43 + .../_Content/Materials/M_WorldGrid.mat.meta | 8 + Assets/_Content/Models/Gun.fbx.meta | 2 +- Assets/_Content/Models/Projectile.fbx.meta | 2 +- Assets/_Content/Prefabs/Heal.prefab | 294 ++ Assets/_Content/Prefabs/Heal.prefab.meta | 7 + Assets/_Content/Scenes/SampleScene.unity | 4 +- Assets/_Content/Scripts/Characters/Player.cs | 52 +- .../Scripts/Characters/PlayerEvent.cs | 89 +- Assets/_Content/Scripts/Combat/Health.cs | 16 +- Assets/_Content/Scripts/Combat/Projectile.cs | 68 + .../Scripts/Combat/Projectile.cs.meta | 2 + .../Scripts/Combat/ProjectileLauncher.cs | 16 + .../Scripts/Combat/ProjectileLauncher.cs.meta | 2 + Assets/_Content/Scripts/Interactions.meta | 8 + .../Scripts/Interactions/HealEffect.cs | 34 + .../Scripts/Interactions/HealEffect.cs.meta | 2 + .../Settings/DefaultVolumeProfile.asset | 8 +- Assets/_Content/Shaders.meta | 8 + Assets/_Content/Shaders/Blur.shadergraph | 538 +++ Assets/_Content/Shaders/Blur.shadergraph.meta | 18 + Assets/_Content/Shaders/Include.meta | 8 + Assets/_Content/Shaders/Include/Blur.hlsl | 82 + .../_Content/Shaders/Include/Blur.hlsl.meta | 7 + Assets/_Content/Shaders/SubGraphes.meta | 8 + .../SubGraphes/SceneBlur.shadersubgraph | 576 +++ .../SubGraphes/SceneBlur.shadersubgraph.meta | 11 + .../_Content/Shaders/Teleporter.shadergraph | 3483 +++++++++++++++++ .../Shaders/Teleporter.shadergraph.meta | 18 + Assets/_Content/Shaders/WorldGrid.shader | 322 ++ Assets/_Content/Shaders/WorldGrid.shader.meta | 9 + 34 files changed, 5877 insertions(+), 25 deletions(-) create mode 100644 Assets/_Content/Materials.meta create mode 100644 Assets/_Content/Materials/M_Heal.mat create mode 100644 Assets/_Content/Materials/M_Heal.mat.meta create mode 100644 Assets/_Content/Materials/M_WorldGrid.mat create mode 100644 Assets/_Content/Materials/M_WorldGrid.mat.meta create mode 100644 Assets/_Content/Prefabs/Heal.prefab create mode 100644 Assets/_Content/Prefabs/Heal.prefab.meta create mode 100644 Assets/_Content/Scripts/Combat/Projectile.cs create mode 100644 Assets/_Content/Scripts/Combat/Projectile.cs.meta create mode 100644 Assets/_Content/Scripts/Combat/ProjectileLauncher.cs create mode 100644 Assets/_Content/Scripts/Combat/ProjectileLauncher.cs.meta create mode 100644 Assets/_Content/Scripts/Interactions.meta create mode 100644 Assets/_Content/Scripts/Interactions/HealEffect.cs create mode 100644 Assets/_Content/Scripts/Interactions/HealEffect.cs.meta create mode 100644 Assets/_Content/Shaders.meta create mode 100644 Assets/_Content/Shaders/Blur.shadergraph create mode 100644 Assets/_Content/Shaders/Blur.shadergraph.meta create mode 100644 Assets/_Content/Shaders/Include.meta create mode 100644 Assets/_Content/Shaders/Include/Blur.hlsl create mode 100644 Assets/_Content/Shaders/Include/Blur.hlsl.meta create mode 100644 Assets/_Content/Shaders/SubGraphes.meta create mode 100644 Assets/_Content/Shaders/SubGraphes/SceneBlur.shadersubgraph create mode 100644 Assets/_Content/Shaders/SubGraphes/SceneBlur.shadersubgraph.meta create mode 100644 Assets/_Content/Shaders/Teleporter.shadergraph create mode 100644 Assets/_Content/Shaders/Teleporter.shadergraph.meta create mode 100644 Assets/_Content/Shaders/WorldGrid.shader create mode 100644 Assets/_Content/Shaders/WorldGrid.shader.meta diff --git a/Assets/_Content/Materials.meta b/Assets/_Content/Materials.meta new file mode 100644 index 0000000..13534da --- /dev/null +++ b/Assets/_Content/Materials.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 54d29031413d75547b6e910cbc90f63f +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_Content/Materials/M_Heal.mat b/Assets/_Content/Materials/M_Heal.mat new file mode 100644 index 0000000..1c52a3a --- /dev/null +++ b/Assets/_Content/Materials/M_Heal.mat @@ -0,0 +1,141 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &-1820602765338096021 +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: Unity.RenderPipelines.Universal.Editor::UnityEditor.Rendering.Universal.AssetVersion + version: 10 +--- !u!21 &2100000 +Material: + serializedVersion: 8 + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: M_Heal + m_Shader: {fileID: 4800000, guid: 933532a4fcc9baf4fa0491de14d08ed7, type: 3} + m_Parent: {fileID: 0} + m_ModifiedSerializedProperties: 0 + m_ValidKeywords: + - _ALPHAPREMULTIPLY_ON + - _SURFACE_TYPE_TRANSPARENT + m_InvalidKeywords: [] + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: 3000 + stringTagMap: + RenderType: Transparent + disabledShaderPasses: + - MOTIONVECTORS + - DepthOnly + - SHADOWCASTER + m_LockedProperties: + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: + - _BaseMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _BumpMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailAlbedoMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailMask: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _DetailNormalMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _EmissionMap: + m_Texture: {fileID: 0} + m_Scale: {x: 1, y: 1} + m_Offset: {x: 0, y: 0} + - _MainTex: + m_Texture: {fileID: 0} + 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: 0 + - _AlphaToMask: 0 + - _Blend: 2 + - _BlendModePreserveSpecular: 1 + - _BumpScale: 1 + - _ClearCoatMask: 0 + - _ClearCoatSmoothness: 0 + - _Cull: 2 + - _Cutoff: 0.5 + - _DetailAlbedoMapScale: 1 + - _DetailNormalMapScale: 1 + - _DstBlend: 1 + - _DstBlendAlpha: 1 + - _EnvironmentReflections: 1 + - _GlossMapScale: 0 + - _Glossiness: 0 + - _GlossyReflections: 0 + - _Metallic: 0 + - _OcclusionStrength: 1 + - _Parallax: 0.005 + - _QueueOffset: 0 + - _ReceiveShadows: 1 + - _Smoothness: 0.5 + - _SmoothnessTextureChannel: 0 + - _SpecularHighlights: 1 + - _SrcBlend: 1 + - _SrcBlendAlpha: 1 + - _Surface: 1 + - _WorkflowMode: 1 + - _XRMotionVectorsPass: 1 + - _ZWrite: 0 + m_Colors: + - _BaseColor: {r: 0.10849059, g: 1, b: 0.26741007, a: 1} + - _Color: {r: 0.108490564, g: 1, b: 0.26741004, 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 diff --git a/Assets/_Content/Materials/M_Heal.mat.meta b/Assets/_Content/Materials/M_Heal.mat.meta new file mode 100644 index 0000000..43f3061 --- /dev/null +++ b/Assets/_Content/Materials/M_Heal.mat.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 65d8dad5bb4bf714db3e64463937c982 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_Content/Materials/M_WorldGrid.mat b/Assets/_Content/Materials/M_WorldGrid.mat new file mode 100644 index 0000000..8f87050 --- /dev/null +++ b/Assets/_Content/Materials/M_WorldGrid.mat @@ -0,0 +1,43 @@ +%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: M_WorldGrid + m_Shader: {fileID: 4800000, guid: 0b6b65e03c0cbc6458620f24738fd6c6, type: 3} + m_Parent: {fileID: 0} + m_ModifiedSerializedProperties: 0 + m_ValidKeywords: [] + m_InvalidKeywords: [] + m_LightmapFlags: 4 + m_EnableInstancingVariants: 0 + m_DoubleSidedGI: 0 + m_CustomRenderQueue: -1 + stringTagMap: {} + disabledShaderPasses: [] + m_LockedProperties: + m_SavedProperties: + serializedVersion: 3 + m_TexEnvs: [] + m_Ints: [] + m_Floats: + - _CrossOpacity: 1 + - _CrossSize: 0.13 + - _CrossWidth: 0.02 + - _DotDiameter: 0.009 + - _DotOpacity: 0.22 + - _GridOpacity: 0.28 + - _GridWidth: 0.001 + - _Metallic: 0 + - _Smoothness: 0.3 + - _TriplanarSharpness: 16 + m_Colors: + - _BaseColor: {r: 0.21493416, g: 0.26285714, b: 0.2830189, a: 1} + - _DarkColor: {r: 0.035, g: 0.054999977, b: 0.06999998, a: 1} + - _LineColor: {r: 1, g: 1, b: 1, a: 1} + m_BuildTextureStacks: [] + m_AllowLocking: 1 diff --git a/Assets/_Content/Materials/M_WorldGrid.mat.meta b/Assets/_Content/Materials/M_WorldGrid.mat.meta new file mode 100644 index 0000000..761704d --- /dev/null +++ b/Assets/_Content/Materials/M_WorldGrid.mat.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e0ddabcd6e8573c4a8e4e0d1378495ac +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 2100000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_Content/Models/Gun.fbx.meta b/Assets/_Content/Models/Gun.fbx.meta index d60cb3f..1556c18 100644 --- a/Assets/_Content/Models/Gun.fbx.meta +++ b/Assets/_Content/Models/Gun.fbx.meta @@ -33,7 +33,7 @@ ModelImporter: isReadable: 0 meshes: lODScreenPercentages: [] - globalScale: 1 + globalScale: 100 meshCompression: 0 addColliders: 0 useSRGBMaterialColor: 1 diff --git a/Assets/_Content/Models/Projectile.fbx.meta b/Assets/_Content/Models/Projectile.fbx.meta index 0f064ec..34b61ec 100644 --- a/Assets/_Content/Models/Projectile.fbx.meta +++ b/Assets/_Content/Models/Projectile.fbx.meta @@ -33,7 +33,7 @@ ModelImporter: isReadable: 0 meshes: lODScreenPercentages: [] - globalScale: 1 + globalScale: 100 meshCompression: 0 addColliders: 0 useSRGBMaterialColor: 1 diff --git a/Assets/_Content/Prefabs/Heal.prefab b/Assets/_Content/Prefabs/Heal.prefab new file mode 100644 index 0000000..d0e6e4d --- /dev/null +++ b/Assets/_Content/Prefabs/Heal.prefab @@ -0,0 +1,294 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &1147726563735334551 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 7556724015060411566} + - component: {fileID: 3783306422223445236} + - component: {fileID: 8275237195305215234} + m_Layer: 0 + m_Name: Cube + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &7556724015060411566 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1147726563735334551} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 9.3132e-10, y: 0.000000059605, z: 0} + m_LocalScale: {x: 0.52297795, y: 0.16915, z: 0.16915} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 2066137184867944858} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!33 &3783306422223445236 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1147726563735334551} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!23 &8275237195305215234 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1147726563735334551} + 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_ForceMeshLod: -1 + m_MeshLodSelectionBias: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 65d8dad5bb4bf714db3e64463937c982, 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_GlobalIlluminationMeshLod: 0 + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_MaskInteraction: 0 + m_AdditionalVertexStreams: {fileID: 0} +--- !u!1 &3212408836776066074 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2066137184867944858} + - component: {fileID: 3170361717976852070} + - component: {fileID: 1618082476748621181} + - component: {fileID: 6580930266284447471} + m_Layer: 0 + m_Name: Heal + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &2066137184867944858 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3212408836776066074} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0.008, y: 0.742, z: -3.21385} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 7556724015060411566} + - {fileID: 2719514837664179606} + m_Father: {fileID: 0} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!135 &3170361717976852070 +SphereCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3212408836776066074} + 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_Radius: 0.5 + m_Center: {x: 0, y: 0, z: 0} +--- !u!114 &1618082476748621181 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3212408836776066074} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d3c874cb9bc4c364d87e100aada2b434, type: 3} + m_Name: + m_EditorClassIdentifier: Assembly-CSharp::Arena.Characters.PlayerEvent + _settings: + Trigger: 0 + _onPlayer: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 6580930266284447471} + m_TargetAssemblyTypeName: Arena.Interactions.HealEffect, Assembly-CSharp + m_MethodName: Apply + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + - m_Target: {fileID: 3212408836776066074} + m_TargetAssemblyTypeName: UnityEngine.GameObject, UnityEngine + m_MethodName: SetActive + m_Mode: 6 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &6580930266284447471 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3212408836776066074} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5e30510fdd4a8b64da1115732d8ee972, type: 3} + m_Name: + m_EditorClassIdentifier: Assembly-CSharp::Arena.Interactions.HealEffect + _settings: + Amount: 25 +--- !u!1 &3382438918099537360 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2719514837664179606} + - component: {fileID: 4326274491252777190} + - component: {fileID: 2540956898591381309} + m_Layer: 0 + m_Name: Cube (1) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &2719514837664179606 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3382438918099537360} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0.7071068, w: 0.7071068} + m_LocalPosition: {x: 9.3132e-10, y: 0.000000059605, z: 0} + m_LocalScale: {x: 0.52297795, y: 0.16915, z: 0.16915} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 2066137184867944858} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 90} +--- !u!33 &4326274491252777190 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3382438918099537360} + m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0} +--- !u!23 &2540956898591381309 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3382438918099537360} + 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_ForceMeshLod: -1 + m_MeshLodSelectionBias: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 65d8dad5bb4bf714db3e64463937c982, 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_GlobalIlluminationMeshLod: 0 + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_MaskInteraction: 0 + m_AdditionalVertexStreams: {fileID: 0} diff --git a/Assets/_Content/Prefabs/Heal.prefab.meta b/Assets/_Content/Prefabs/Heal.prefab.meta new file mode 100644 index 0000000..6df8058 --- /dev/null +++ b/Assets/_Content/Prefabs/Heal.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 3d06280fd07b03740829c858344b95e9 +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_Content/Scenes/SampleScene.unity b/Assets/_Content/Scenes/SampleScene.unity index be7633e..7a98829 100644 --- a/Assets/_Content/Scenes/SampleScene.unity +++ b/Assets/_Content/Scenes/SampleScene.unity @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0c2e903027e23f2dd1493fa5a1501abafc8de635728a7b86bfca5c4f0a34911f -size 26740 +oid sha256:010e1414ebdd9ba7f2d7cde797c80c72c45e1c65b54a5859685b730926897cab +size 72879 diff --git a/Assets/_Content/Scripts/Characters/Player.cs b/Assets/_Content/Scripts/Characters/Player.cs index ee1649a..359a024 100644 --- a/Assets/_Content/Scripts/Characters/Player.cs +++ b/Assets/_Content/Scripts/Characters/Player.cs @@ -1,4 +1,5 @@ using Arena.Combat; +using System; using UnityEngine; using UnityEngine.InputSystem; @@ -18,6 +19,7 @@ namespace Arena.Characters { public CharacterController Controller; public InputActionReference MoveAction; + public InputActionReference InteractAction; } [System.Serializable] @@ -37,8 +39,12 @@ namespace Arena.Characters [SerializeField] private StateContainer _state; [SerializeField] private Health _health; - public StateContainer State => _state; + public Action OnInteract; + public StateContainer State => _state; + public Health Health => _health; + + private bool _isInteracting; private Vector2 _moveInput; private Camera _camera; @@ -65,12 +71,16 @@ namespace Arena.Characters void OnEnable() { _references.MoveAction.action.Enable(); + _references.InteractAction.action.Enable(); } void OnDisable() { if (Instance == this) + { _references.MoveAction.action.Disable(); + _references.InteractAction.action.Disable(); + } } void OnDestroy() @@ -88,20 +98,47 @@ namespace Arena.Characters GetInputs(); Move(t); + Interact(); } #endregion - #region Public Methods + #region PUBLIC METHODS public void TakeDamage(int amount) { _health.TakeDamage(amount); } + // + /// Teleports the player. + /// + /// x, y, z: position. w: angle around the vertical axis, in degrees. + public void Teleport(Vector4 pose) + { + // An enabled CharacterController would overwrite the new position + _references.Controller.enabled = false; + + Vector3 position = new Vector3(pose.x, pose.y, pose.z); + Quaternion rotation = Quaternion.Euler(0f, pose.w, 0f); + transform.SetPositionAndRotation(position, rotation); + + _references.Controller.enabled = true; + } + + /// + /// Teleports the player to the position and heading of a target, such as a spawn point. + /// + public void Teleport(Transform target) + { + Vector3 position = target.position; + Vector4 pose = new Vector4(position.x, position.y, position.z, target.eulerAngles.y); + Teleport(pose); + } + #endregion - #region Private Methods + #region PRIVATE METHODS #if UNITY_EDITOR [ContextMenu("Debug/Take 25 Damage")] @@ -114,6 +151,7 @@ namespace Arena.Characters private void GetInputs() { _moveInput = _references.MoveAction.action.ReadValue(); + _isInteracting = _references.InteractAction.action.WasPressedThisFrame(); } private void Move(float t) @@ -126,6 +164,14 @@ namespace Arena.Characters _references.Controller.Move(velocity * t); } + private void Interact() + { + if (_isInteracting) + { + OnInteract?.Invoke(); + } + } + private Vector3 ToWorldDirection(Vector2 input) { // Only the camera rotation around the vertical axis is kept diff --git a/Assets/_Content/Scripts/Characters/PlayerEvent.cs b/Assets/_Content/Scripts/Characters/PlayerEvent.cs index 7b30cb5..885f3d6 100644 --- a/Assets/_Content/Scripts/Characters/PlayerEvent.cs +++ b/Assets/_Content/Scripts/Characters/PlayerEvent.cs @@ -1,16 +1,89 @@ using UnityEngine; +using UnityEngine.Events; -public class PlayerEvent : MonoBehaviour +namespace Arena.Characters { - // Start is called once before the first execution of Update after the MonoBehaviour is created - void Start() + public class PlayerEvent : MonoBehaviour { + public enum Trigger + { + OnPlayerEnter, + OnPlayerInteract + } - } + [System.Serializable] + public class Settings + { + [Tooltip("OnPlayerEnter: as soon as the player enters. OnPlayerInteract: when the player interacts inside the zone.")] + public Trigger Trigger; + } - // Update is called once per frame - void Update() - { - + [SerializeField] private Settings _settings; + [SerializeField] private UnityEvent _onPlayer; + + private bool _isListening; + + #region UNITY LIFECYCLES + + private void OnDisable() + { + // The object can be hidden while the player is inside + StopListening(); + } + + void OnTriggerEnter(Collider other) + { + if (!IsPlayer(other)) + return; + + if (_settings.Trigger == Trigger.OnPlayerEnter) + _onPlayer.Invoke(); + else + StartListening(); + } + + void OnTriggerExit(Collider other) + { + if (IsPlayer(other)) + StopListening(); + } + + #endregion + + private bool IsPlayer(Collider other) + { + return Player.Instance != null && other.gameObject == Player.Instance.gameObject; + } + + private void StartListening() + { + Player.Instance.OnInteract += HandleInteract; + _isListening = true; + } + + private void StopListening() + { + if (!_isListening) + return; + + if (Player.Instance != null) + Player.Instance.OnInteract -= HandleInteract; + + _isListening = false; + } + + private void HandleInteract() + { + _onPlayer.Invoke(); + } + + public void Teleport(Transform target) + { + if (!Player.Instance) + return; + + StopListening(); + Player.Instance.Teleport(target); + } } } diff --git a/Assets/_Content/Scripts/Combat/Health.cs b/Assets/_Content/Scripts/Combat/Health.cs index 98be4ad..0354738 100644 --- a/Assets/_Content/Scripts/Combat/Health.cs +++ b/Assets/_Content/Scripts/Combat/Health.cs @@ -4,7 +4,7 @@ using UnityEngine; namespace Arena.Combat { /// - /// Hit points of an entity. Serialized inside the component that owns it (Player, Enemy), + /// Health points of an entity. Serialized inside the component that owns it (Player, Enemy), /// which calls Initialize in its Awake. /// [System.Serializable] @@ -12,19 +12,19 @@ namespace Arena.Combat { #region Fields - [Tooltip("Hit points when full.")] + [Tooltip("Health points when full.")] [Min(1)] public int Max = 100; - [Tooltip("Current hit points, visible for debugging.")] + [Tooltip("Current health points, visible for debugging.")] [SerializeField] private int _current; /// - /// Raised with the current and max hit points each time they change. + /// Raised with the current and max health points each time they change. /// public event Action OnChange; /// - /// Raised once, when the hit points reach zero. + /// Raised once, when the health points reach zero. /// public event Action OnDied; @@ -36,7 +36,7 @@ namespace Arena.Combat #region Public Methods /// - /// Fills the hit points. Called by the owner in its Awake. + /// Fills the health points. Called by the owner in its Awake. /// public void Initialize() { @@ -44,7 +44,7 @@ namespace Arena.Combat } /// - /// Removes hit points and raises OnDied the first time they reach zero. + /// Removes health points and raises OnDied the first time they reach zero. /// public void TakeDamage(int amount) { @@ -58,7 +58,7 @@ namespace Arena.Combat } /// - /// Gives hit points back without exceeding Max. Has no effect once dead. + /// Gives health points back without exceeding Max. Has no effect once dead. /// public void Heal(int amount) { diff --git a/Assets/_Content/Scripts/Combat/Projectile.cs b/Assets/_Content/Scripts/Combat/Projectile.cs new file mode 100644 index 0000000..c446d68 --- /dev/null +++ b/Assets/_Content/Scripts/Combat/Projectile.cs @@ -0,0 +1,68 @@ +using UnityEngine; + +namespace Arena.Combat +{ + /// + /// Moves straight ahead and damages the first IDamageable it touches. + /// Needs a trigger collider and a kinematic Rigidbody. + /// + [RequireComponent(typeof(Rigidbody))] + public class Projectile : MonoBehaviour + { + [System.Serializable] + public class Settings + { + [Tooltip("Speed, in meters per second.")] + [Min(0f)] public float Speed = 20f; + + [Tooltip("Time before an unused projectile is destroyed, in seconds.")] + [Min(0.1f)] public float Lifetime = 2f; + } + + #region Fields + + [SerializeField] private Settings _settings; + + private int _damage; + private GameObject _owner; + + #endregion + + #region Unity Lifecycle + + private void Update() + { + transform.position += transform.forward * _settings.Speed * Time.deltaTime; + } + + private void OnTriggerEnter(Collider other) + { + // Ignore the shooter and the other trigger zones + if (other.isTrigger || other.gameObject == _owner) + return; + + if (other.TryGetComponent(out IDamageable target)) + target.TakeDamage(_damage); + + Destroy(gameObject); + } + + #endregion + + #region Public Methods + + /// + /// Starts the projectile. Called right after Instantiate by whoever fires it. + /// + /// Damage dealt to the IDamageable it touches. + /// Shooter, ignored by the projectile. + public void Launch(int damage, GameObject owner) + { + _damage = damage; + _owner = owner; + Destroy(gameObject, _settings.Lifetime); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/_Content/Scripts/Combat/Projectile.cs.meta b/Assets/_Content/Scripts/Combat/Projectile.cs.meta new file mode 100644 index 0000000..62e75ca --- /dev/null +++ b/Assets/_Content/Scripts/Combat/Projectile.cs.meta @@ -0,0 +1,2 @@ +fileFormatVersion: 2 +guid: 875f6e6257f7027489dceee7bdfec3cb \ No newline at end of file diff --git a/Assets/_Content/Scripts/Combat/ProjectileLauncher.cs b/Assets/_Content/Scripts/Combat/ProjectileLauncher.cs new file mode 100644 index 0000000..38547f3 --- /dev/null +++ b/Assets/_Content/Scripts/Combat/ProjectileLauncher.cs @@ -0,0 +1,16 @@ +using UnityEngine; + +public class ProjectileLauncher : MonoBehaviour +{ + // Start is called once before the first execution of Update after the MonoBehaviour is created + void Start() + { + + } + + // Update is called once per frame + void Update() + { + + } +} diff --git a/Assets/_Content/Scripts/Combat/ProjectileLauncher.cs.meta b/Assets/_Content/Scripts/Combat/ProjectileLauncher.cs.meta new file mode 100644 index 0000000..ac0af42 --- /dev/null +++ b/Assets/_Content/Scripts/Combat/ProjectileLauncher.cs.meta @@ -0,0 +1,2 @@ +fileFormatVersion: 2 +guid: 4bb53e2fd0884a746883755fca366194 \ No newline at end of file diff --git a/Assets/_Content/Scripts/Interactions.meta b/Assets/_Content/Scripts/Interactions.meta new file mode 100644 index 0000000..4c5c29c --- /dev/null +++ b/Assets/_Content/Scripts/Interactions.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 88dab0d441585ab4cbae1aa9191deffe +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_Content/Scripts/Interactions/HealEffect.cs b/Assets/_Content/Scripts/Interactions/HealEffect.cs new file mode 100644 index 0000000..ddcb5fd --- /dev/null +++ b/Assets/_Content/Scripts/Interactions/HealEffect.cs @@ -0,0 +1,34 @@ +using UnityEngine; +using Arena.Characters; + +namespace Arena.Interactions +{ + /// + /// Heals the player. Apply is meant to be linked to a PlayerEvent. + /// + public class HealEffect : MonoBehaviour + { + [System.Serializable] + public class Settings + { + [Tooltip("Hit points given to the player.")] + [Min(1)] public int Amount = 25; + } + + #region Fields + + [SerializeField] private Settings _settings; + + #endregion + + #region Public Methods + + public void Apply() + { + if (Player.Instance != null) + Player.Instance.Health.Heal(_settings.Amount); + } + + #endregion + } +} \ No newline at end of file diff --git a/Assets/_Content/Scripts/Interactions/HealEffect.cs.meta b/Assets/_Content/Scripts/Interactions/HealEffect.cs.meta new file mode 100644 index 0000000..ee77487 --- /dev/null +++ b/Assets/_Content/Scripts/Interactions/HealEffect.cs.meta @@ -0,0 +1,2 @@ +fileFormatVersion: 2 +guid: 5e30510fdd4a8b64da1115732d8ee972 \ No newline at end of file diff --git a/Assets/_Content/Settings/DefaultVolumeProfile.asset b/Assets/_Content/Settings/DefaultVolumeProfile.asset index 6fb1822..66d98de 100644 --- a/Assets/_Content/Settings/DefaultVolumeProfile.asset +++ b/Assets/_Content/Settings/DefaultVolumeProfile.asset @@ -342,6 +342,9 @@ MonoBehaviour: skyOcclusionIntensityMultiplier: m_OverrideState: 1 m_Value: 1 + worldOffset: + m_OverrideState: 1 + m_Value: {x: 0, y: 0, z: 0} --- !u!114 &-1216621516061285780 MonoBehaviour: m_ObjectHideFlags: 3 @@ -376,6 +379,9 @@ MonoBehaviour: highQualityFiltering: m_OverrideState: 1 m_Value: 0 + filter: + m_OverrideState: 1 + m_Value: 0 downscale: m_OverrideState: 1 m_Value: 0 @@ -462,8 +468,6 @@ MonoBehaviour: - {fileID: -6288072647309666549} - {fileID: 7518938298396184218} - {fileID: -1410297666881709256} - - {fileID: -7750755424749557576} - - {fileID: -5139089513906902183} --- !u!114 &853819529557874667 MonoBehaviour: m_ObjectHideFlags: 3 diff --git a/Assets/_Content/Shaders.meta b/Assets/_Content/Shaders.meta new file mode 100644 index 0000000..f90980d --- /dev/null +++ b/Assets/_Content/Shaders.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: dff28469fb7612b41a8703d24a43a914 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_Content/Shaders/Blur.shadergraph b/Assets/_Content/Shaders/Blur.shadergraph new file mode 100644 index 0000000..4d8b341 --- /dev/null +++ b/Assets/_Content/Shaders/Blur.shadergraph @@ -0,0 +1,538 @@ +{ + "m_SGVersion": 3, + "m_Type": "UnityEditor.ShaderGraph.GraphData", + "m_ObjectId": "8504e9bdabaf4858997e0f525ace7671", + "m_Properties": [], + "m_Keywords": [], + "m_Dropdowns": [], + "m_CategoryData": [ + { + "m_Id": "4e543fd3878a42db99418edc6edf0ba7" + } + ], + "m_Nodes": [ + { + "m_Id": "19d5cde9bfd8498a98dfc456a2a085b1" + }, + { + "m_Id": "e46b92cb9c79432ca46eefa55eea0043" + }, + { + "m_Id": "c51d56e4e95d417c832024b0e3582d74" + }, + { + "m_Id": "95bb1e764bc14e08b5f94efbfc1a97b5" + }, + { + "m_Id": "148e107b4a514638a85d1f65db6aebac" + }, + { + "m_Id": "ea01fc94eed749579737ce9b4803b1c3" + } + ], + "m_GroupDatas": [], + "m_StickyNoteDatas": [], + "m_Edges": [ + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "ea01fc94eed749579737ce9b4803b1c3" + }, + "m_SlotId": 2 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "95bb1e764bc14e08b5f94efbfc1a97b5" + }, + "m_SlotId": 0 + } + } + ], + "m_VertexContext": { + "m_Position": { + "x": 0.0, + "y": 0.0 + }, + "m_Blocks": [ + { + "m_Id": "19d5cde9bfd8498a98dfc456a2a085b1" + }, + { + "m_Id": "e46b92cb9c79432ca46eefa55eea0043" + }, + { + "m_Id": "c51d56e4e95d417c832024b0e3582d74" + } + ] + }, + "m_FragmentContext": { + "m_Position": { + "x": 0.0, + "y": 200.0 + }, + "m_Blocks": [ + { + "m_Id": "95bb1e764bc14e08b5f94efbfc1a97b5" + }, + { + "m_Id": "148e107b4a514638a85d1f65db6aebac" + } + ] + }, + "m_PreviewData": { + "serializedMesh": { + "m_SerializedMesh": "{\"mesh\":{\"instanceID\":0}}", + "m_Guid": "" + }, + "preventRotation": false + }, + "m_Path": "Shader Graphs", + "m_GraphPrecision": 1, + "m_PreviewMode": 2, + "m_OutputNode": { + "m_Id": "" + }, + "m_SubDatas": [], + "m_ActiveTargets": [ + { + "m_Id": "7fb196b850694ad892148a99a6dffeec" + } + ] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.BlockNode", + "m_ObjectId": "148e107b4a514638a85d1f65db6aebac", + "m_Group": { + "m_Id": "" + }, + "m_Name": "SurfaceDescription.Alpha", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 0.0, + "y": 0.0, + "width": 0.0, + "height": 0.0 + } + }, + "m_Slots": [ + { + "m_Id": "4de0a3d4e4ca4fbf85285f307e5e2ff2" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_SerializedDescriptor": "SurfaceDescription.Alpha" +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.BlockNode", + "m_ObjectId": "19d5cde9bfd8498a98dfc456a2a085b1", + "m_Group": { + "m_Id": "" + }, + "m_Name": "VertexDescription.Position", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 0.0, + "y": 0.0, + "width": 0.0, + "height": 0.0 + } + }, + "m_Slots": [ + { + "m_Id": "35ff8e602c8d46b891f390ae4294bbcf" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_SerializedDescriptor": "VertexDescription.Position" +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.ColorRGBMaterialSlot", + "m_ObjectId": "297cd0d2b1ef498a83391eaa84d8b072", + "m_Id": 0, + "m_DisplayName": "Base Color", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "BaseColor", + "m_StageCapability": 2, + "m_Value": { + "x": 0.5, + "y": 0.5, + "z": 0.5 + }, + "m_DefaultValue": { + "x": 0.5, + "y": 0.5, + "z": 0.5 + }, + "m_Labels": [], + "m_ColorMode": 0, + "m_DefaultColor": { + "r": 0.5, + "g": 0.5, + "b": 0.5, + "a": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.PositionMaterialSlot", + "m_ObjectId": "35ff8e602c8d46b891f390ae4294bbcf", + "m_Id": 0, + "m_DisplayName": "Position", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Position", + "m_StageCapability": 1, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_Labels": [], + "m_Space": 0 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot", + "m_ObjectId": "4a8625d5d941403f92438a453b958880", + "m_Id": 2, + "m_DisplayName": "Out_Vector3", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "OutVector3", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_Labels": [] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "4de0a3d4e4ca4fbf85285f307e5e2ff2", + "m_Id": 0, + "m_DisplayName": "Alpha", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Alpha", + "m_StageCapability": 2, + "m_Value": 1.0, + "m_DefaultValue": 1.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.CategoryData", + "m_ObjectId": "4e543fd3878a42db99418edc6edf0ba7", + "m_Name": "", + "m_ChildObjectList": [] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "5c1c7786040548c594595692ea8eabc7", + "m_Id": 1165641570, + "m_DisplayName": "Quality", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "_Quality", + "m_StageCapability": 3, + "m_Value": 1.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "7fa4a7becdef4ac590742fb8b6061f0d", + "m_Id": 1495779657, + "m_DisplayName": "Blur", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "_Blur", + "m_StageCapability": 3, + "m_Value": 0.5, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 1, + "m_Type": "UnityEditor.Rendering.Universal.ShaderGraph.UniversalTarget", + "m_ObjectId": "7fb196b850694ad892148a99a6dffeec", + "m_Datas": [], + "m_ActiveSubTarget": { + "m_Id": "f0490127bd8c4166bbfde748a359a2a1" + }, + "m_AllowMaterialOverride": false, + "m_SurfaceType": 1, + "m_ZTestMode": 4, + "m_ZWriteControl": 0, + "m_AlphaMode": 0, + "m_RenderFace": 2, + "m_AlphaClip": false, + "m_CastShadows": true, + "m_ReceiveShadows": true, + "m_DisableTint": false, + "m_Sort3DAs2DCompatible": false, + "m_AdditionalMotionVectorMode": 0, + "m_AlembicMotionVectors": false, + "m_SupportsLODCrossFade": false, + "m_CustomEditorGUI": "", + "m_SupportVFX": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.BlockNode", + "m_ObjectId": "95bb1e764bc14e08b5f94efbfc1a97b5", + "m_Group": { + "m_Id": "" + }, + "m_Name": "SurfaceDescription.BaseColor", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 0.0, + "y": 0.0, + "width": 0.0, + "height": 0.0 + } + }, + "m_Slots": [ + { + "m_Id": "297cd0d2b1ef498a83391eaa84d8b072" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_SerializedDescriptor": "SurfaceDescription.BaseColor" +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.BlockNode", + "m_ObjectId": "c51d56e4e95d417c832024b0e3582d74", + "m_Group": { + "m_Id": "" + }, + "m_Name": "VertexDescription.Tangent", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 0.0, + "y": 0.0, + "width": 0.0, + "height": 0.0 + } + }, + "m_Slots": [ + { + "m_Id": "e715a6d1d83442d8a88ec92f40f1a4f7" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_SerializedDescriptor": "VertexDescription.Tangent" +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.NormalMaterialSlot", + "m_ObjectId": "d57890460fbb4bcca92d64b60520129c", + "m_Id": 0, + "m_DisplayName": "Normal", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Normal", + "m_StageCapability": 1, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_Labels": [], + "m_Space": 0 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.BlockNode", + "m_ObjectId": "e46b92cb9c79432ca46eefa55eea0043", + "m_Group": { + "m_Id": "" + }, + "m_Name": "VertexDescription.Normal", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 0.0, + "y": 0.0, + "width": 0.0, + "height": 0.0 + } + }, + "m_Slots": [ + { + "m_Id": "d57890460fbb4bcca92d64b60520129c" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_SerializedDescriptor": "VertexDescription.Normal" +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.TangentMaterialSlot", + "m_ObjectId": "e715a6d1d83442d8a88ec92f40f1a4f7", + "m_Id": 0, + "m_DisplayName": "Tangent", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Tangent", + "m_StageCapability": 1, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_Labels": [], + "m_Space": 0 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.SubGraphNode", + "m_ObjectId": "ea01fc94eed749579737ce9b4803b1c3", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Scene Blur", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -448.0, + "y": 179.0, + "width": 208.0, + "height": 303.0 + } + }, + "m_Slots": [ + { + "m_Id": "7fa4a7becdef4ac590742fb8b6061f0d" + }, + { + "m_Id": "5c1c7786040548c594595692ea8eabc7" + }, + { + "m_Id": "4a8625d5d941403f92438a453b958880" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_SerializedSubGraph": "{\n \"subGraph\": {\n \"fileID\": -5475051401550479605,\n \"guid\": \"26f47ae7ba9ee5943993a305e6779681\",\n \"type\": 3\n }\n}", + "m_PropertyGuids": [ + "8063cb26-80fc-4286-8ad3-84a319514638", + "f6d871c3-eb20-4419-80ff-cb790122708e" + ], + "m_PropertyIds": [ + 1495779657, + 1165641570 + ], + "m_Dropdowns": [], + "m_DropdownSelectedEntries": [] +} + +{ + "m_SGVersion": 2, + "m_Type": "UnityEditor.Rendering.Universal.ShaderGraph.UniversalUnlitSubTarget", + "m_ObjectId": "f0490127bd8c4166bbfde748a359a2a1", + "m_KeepLightingVariants": false, + "m_DefaultDecalBlending": true, + "m_DefaultSSAO": true +} + diff --git a/Assets/_Content/Shaders/Blur.shadergraph.meta b/Assets/_Content/Shaders/Blur.shadergraph.meta new file mode 100644 index 0000000..1f91fa0 --- /dev/null +++ b/Assets/_Content/Shaders/Blur.shadergraph.meta @@ -0,0 +1,18 @@ +fileFormatVersion: 2 +guid: abd46789b404b1b4c92524cc6a1766ae +ScriptedImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 2 + userData: + assetBundleName: + assetBundleVariant: + script: {fileID: 11500000, guid: 625f186215c104763be7675aa2d941aa, type: 3} + useAsTemplate: 0 + exposeTemplateAsShader: 0 + template: + name: + category: + description: + icon: {instanceID: 0} + thumbnail: {instanceID: 0} diff --git a/Assets/_Content/Shaders/Include.meta b/Assets/_Content/Shaders/Include.meta new file mode 100644 index 0000000..f948652 --- /dev/null +++ b/Assets/_Content/Shaders/Include.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 30baac90d43f1264998935abb5bb0a80 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_Content/Shaders/Include/Blur.hlsl b/Assets/_Content/Shaders/Include/Blur.hlsl new file mode 100644 index 0000000..700372e --- /dev/null +++ b/Assets/_Content/Shaders/Include/Blur.hlsl @@ -0,0 +1,82 @@ + +#ifndef BLUR_INCLUDED +#define BLUR_INCLUDED + +// Declare the texture only when the required macros exist. +#if defined(TEXTURE2D_X) && defined(SAMPLE_TEXTURE2D_X) +#define BLUR_TEXTURE_AVAILABLE 1 + TEXTURE2D_X(_CameraOpaqueTexture); + SAMPLER(sampler_CameraOpaqueTexture); +#else +#define BLUR_TEXTURE_AVAILABLE 0 +#endif + +void Gaussian_float(float2 UV, float Blur, float Quality, out float3 Color) +{ +#if defined(SHADERGRAPH_PREVIEW) || !BLUR_TEXTURE_AVAILABLE + Color = float3(0.5, 0.5, 0.5); +#else + float2 screenUV = saturate(UV); + float radius = saturate(Blur) * 0.04; + float2 stepUV = radius * float2( + _ScreenParams.y / _ScreenParams.x, + 1.0 + ); + + // LOW: 9 samples + // MEDIUM: 25 samples + // HIGH: 49 samples + int extent = (int)clamp(floor(Quality + 0.5), 0.0, 2.0) + 1; + + float sigma = max(0.8, extent * 0.65); + float invTwoSigmaSq = 0.5 / (sigma * sigma); + + float3 sum = 0.0; + float totalWeight = 0.0; + + [loop] + for (int y = -extent; y <= extent; ++y) + { + [loop] + for (int x = -extent; x <= extent; ++x) + { + float2 offset = float2(x, y); + + float weight = exp2( + -dot(offset, offset) + * invTwoSigmaSq + * 1.44269504089 + ); + + float2 sampleUV = saturate( + screenUV + offset * stepUV / extent + ); + + float3 sampleColor = SAMPLE_TEXTURE2D_X( + _CameraOpaqueTexture, + sampler_CameraOpaqueTexture, + sampleUV + ).rgb; + + sum += sampleColor * weight; + totalWeight += weight; + } + } + + Color = sum / max(totalWeight, 1e-5); +#endif +} + +void Gaussian_half(half2 UV, half Blur, half Quality, out half3 Color) +{ + float3 result; + Gaussian_float( + (float2) UV, + (float) Blur, + (float) Quality, + result + ); + Color = (half3) result; +} + +#endif diff --git a/Assets/_Content/Shaders/Include/Blur.hlsl.meta b/Assets/_Content/Shaders/Include/Blur.hlsl.meta new file mode 100644 index 0000000..7273cc4 --- /dev/null +++ b/Assets/_Content/Shaders/Include/Blur.hlsl.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 90c8bd5f68510954a8e1367627d7b9fd +ShaderIncludeImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_Content/Shaders/SubGraphes.meta b/Assets/_Content/Shaders/SubGraphes.meta new file mode 100644 index 0000000..cb094cb --- /dev/null +++ b/Assets/_Content/Shaders/SubGraphes.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a1924b6ba000d9f42ba27efe060c928a +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_Content/Shaders/SubGraphes/SceneBlur.shadersubgraph b/Assets/_Content/Shaders/SubGraphes/SceneBlur.shadersubgraph new file mode 100644 index 0000000..f1043dc --- /dev/null +++ b/Assets/_Content/Shaders/SubGraphes/SceneBlur.shadersubgraph @@ -0,0 +1,576 @@ +{ + "m_SGVersion": 3, + "m_Type": "UnityEditor.ShaderGraph.GraphData", + "m_ObjectId": "9d1e9ebe2d9747ffa894412dfba72a33", + "m_Properties": [ + { + "m_Id": "a4404a0972384ad1b4438a72f39e7991" + }, + { + "m_Id": "62c93e885ac547e4bba6e1c78f616037" + } + ], + "m_Keywords": [], + "m_Dropdowns": [], + "m_CategoryData": [ + { + "m_Id": "bf2f39d82e934286ae4a5374c1fd2c11" + } + ], + "m_Nodes": [ + { + "m_Id": "cf35d42ff38940b281c6ce2c8551a1cb" + }, + { + "m_Id": "49fc354b55884d1abb7603ae085af83b" + }, + { + "m_Id": "984a27fbc926447f87cd710107f68787" + }, + { + "m_Id": "cb1666b04adb496dab93487a150fe810" + }, + { + "m_Id": "8df27a4c7fda4aad9ef4fb2ddfc7d4b2" + } + ], + "m_GroupDatas": [], + "m_StickyNoteDatas": [], + "m_Edges": [ + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "49fc354b55884d1abb7603ae085af83b" + }, + "m_SlotId": 0 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "984a27fbc926447f87cd710107f68787" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "8df27a4c7fda4aad9ef4fb2ddfc7d4b2" + }, + "m_SlotId": 0 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "984a27fbc926447f87cd710107f68787" + }, + "m_SlotId": 3 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "984a27fbc926447f87cd710107f68787" + }, + "m_SlotId": 2 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "cf35d42ff38940b281c6ce2c8551a1cb" + }, + "m_SlotId": 2 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "cb1666b04adb496dab93487a150fe810" + }, + "m_SlotId": 0 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "984a27fbc926447f87cd710107f68787" + }, + "m_SlotId": 1 + } + } + ], + "m_VertexContext": { + "m_Position": { + "x": 0.0, + "y": 0.0 + }, + "m_Blocks": [] + }, + "m_FragmentContext": { + "m_Position": { + "x": 0.0, + "y": 0.0 + }, + "m_Blocks": [] + }, + "m_PreviewData": { + "serializedMesh": { + "m_SerializedMesh": "{\"mesh\":{\"instanceID\":0}}", + "m_Guid": "" + }, + "preventRotation": false + }, + "m_Path": "Sub Graphs", + "m_GraphPrecision": 1, + "m_PreviewMode": 2, + "m_OutputNode": { + "m_Id": "cf35d42ff38940b281c6ce2c8551a1cb" + }, + "m_SubDatas": [], + "m_ActiveTargets": [] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector4MaterialSlot", + "m_ObjectId": "29f51427a77b4ebd8b35573100ab1e06", + "m_Id": 0, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_Labels": [] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.ScreenPositionNode", + "m_ObjectId": "49fc354b55884d1abb7603ae085af83b", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Screen Position", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -361.0, + "y": 39.0, + "width": 208.0, + "height": 312.0 + } + }, + "m_Slots": [ + { + "m_Id": "29f51427a77b4ebd8b35573100ab1e06" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_ScreenSpaceType": 0 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot", + "m_ObjectId": "62100b5c2cdb420ea029c63cee7e388a", + "m_Id": 2, + "m_DisplayName": "Out_Vector3", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "OutVector3", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_Labels": [] +} + +{ + "m_SGVersion": 1, + "m_Type": "UnityEditor.ShaderGraph.Internal.Vector1ShaderProperty", + "m_ObjectId": "62c93e885ac547e4bba6e1c78f616037", + "m_Guid": { + "m_GuidSerialized": "f6d871c3-eb20-4419-80ff-cb790122708e" + }, + "promotedFromAssetID": "", + "promotedFromCategoryName": "", + "promotedOrdering": -1, + "m_Name": "Quality", + "m_DefaultRefNameVersion": 1, + "m_RefNameGeneratedByDisplayName": "Quality", + "m_DefaultReferenceName": "_Quality", + "m_OverrideReferenceName": "", + "m_GeneratePropertyBlock": true, + "m_UseCustomSlotLabel": false, + "m_CustomSlotLabel": "", + "m_DismissedVersion": 0, + "m_Precision": 0, + "overrideHLSLDeclaration": false, + "hlslDeclarationOverride": 0, + "m_Hidden": false, + "m_PerRendererData": false, + "m_customAttributes": [], + "m_Value": 1.0, + "m_FloatType": 0, + "m_LiteralFloatMode": false, + "m_RangeValues": { + "x": 0.0, + "y": 1.0 + }, + "m_SliderType": 0, + "m_SliderPower": 3.0, + "m_EnumType": 0, + "m_CSharpEnumString": "", + "m_EnumNames": [ + "Default" + ], + "m_EnumValues": [ + 0 + ] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "8ac0d8698d6f4355b69979a51fc1b149", + "m_Id": 0, + "m_DisplayName": "Quality", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.PropertyNode", + "m_ObjectId": "8df27a4c7fda4aad9ef4fb2ddfc7d4b2", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Property", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -153.0, + "y": 204.0, + "width": 112.0, + "height": 34.0 + } + }, + "m_Slots": [ + { + "m_Id": "8ac0d8698d6f4355b69979a51fc1b149" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_Property": { + "m_Id": "62c93e885ac547e4bba6e1c78f616037" + } +} + +{ + "m_SGVersion": 1, + "m_Type": "UnityEditor.ShaderGraph.CustomFunctionNode", + "m_ObjectId": "984a27fbc926447f87cd710107f68787", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Gaussian (Custom Function)", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -11.999992370605469, + "y": 84.00000762939453, + "width": 206.00003051757813, + "height": 142.0 + } + }, + "m_Slots": [ + { + "m_Id": "c436f3daf0a148b684e2c91bdf25e93f" + }, + { + "m_Id": "bb16fada7c80423abd415edd1ce3a4b6" + }, + { + "m_Id": "c43f8eede482495c9425f224477cc565" + }, + { + "m_Id": "9cb83bc7c5c046d2b3abca081e990cbc" + } + ], + "synonyms": [ + "code", + "HLSL" + ], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_SourceType": 0, + "m_FunctionName": "Gaussian", + "m_FunctionSource": "90c8bd5f68510954a8e1367627d7b9fd", + "m_FunctionSourceUsePragmas": true, + "m_FunctionBody": "Enter function body here..." +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "9cb83bc7c5c046d2b3abca081e990cbc", + "m_Id": 3, + "m_DisplayName": "Quality", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Quality", + "m_StageCapability": 3, + "m_Value": 2.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 1, + "m_Type": "UnityEditor.ShaderGraph.Internal.Vector1ShaderProperty", + "m_ObjectId": "a4404a0972384ad1b4438a72f39e7991", + "m_Guid": { + "m_GuidSerialized": "8063cb26-80fc-4286-8ad3-84a319514638" + }, + "promotedFromAssetID": "", + "promotedFromCategoryName": "", + "promotedOrdering": -1, + "m_Name": "Blur", + "m_DefaultRefNameVersion": 1, + "m_RefNameGeneratedByDisplayName": "Blur", + "m_DefaultReferenceName": "_Blur", + "m_OverrideReferenceName": "", + "m_GeneratePropertyBlock": true, + "m_UseCustomSlotLabel": false, + "m_CustomSlotLabel": "", + "m_DismissedVersion": 0, + "m_Precision": 0, + "overrideHLSLDeclaration": false, + "hlslDeclarationOverride": 0, + "m_Hidden": false, + "m_PerRendererData": false, + "m_customAttributes": [], + "m_Value": 0.5, + "m_FloatType": 0, + "m_LiteralFloatMode": false, + "m_RangeValues": { + "x": 0.0, + "y": 1.0 + }, + "m_SliderType": 0, + "m_SliderPower": 3.0, + "m_EnumType": 0, + "m_CSharpEnumString": "", + "m_EnumNames": [ + "Default" + ], + "m_EnumValues": [ + 0 + ] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector2MaterialSlot", + "m_ObjectId": "bb16fada7c80423abd415edd1ce3a4b6", + "m_Id": 0, + "m_DisplayName": "UV", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "UV", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0 + }, + "m_Labels": [] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.CategoryData", + "m_ObjectId": "bf2f39d82e934286ae4a5374c1fd2c11", + "m_Name": "", + "m_ChildObjectList": [ + { + "m_Id": "a4404a0972384ad1b4438a72f39e7991" + }, + { + "m_Id": "62c93e885ac547e4bba6e1c78f616037" + } + ] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot", + "m_ObjectId": "c436f3daf0a148b684e2c91bdf25e93f", + "m_Id": 2, + "m_DisplayName": "Color", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Color", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_Labels": [] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "c43f8eede482495c9425f224477cc565", + "m_Id": 1, + "m_DisplayName": "Blur", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Blur", + "m_StageCapability": 3, + "m_Value": 1.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.PropertyNode", + "m_ObjectId": "cb1666b04adb496dab93487a150fe810", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Property", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -137.0, + "y": 161.0, + "width": 96.0, + "height": 34.0 + } + }, + "m_Slots": [ + { + "m_Id": "d8c308401ebb4d45aabcb025efd14753" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_Property": { + "m_Id": "a4404a0972384ad1b4438a72f39e7991" + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.SubGraphOutputNode", + "m_ObjectId": "cf35d42ff38940b281c6ce2c8551a1cb", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Output", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 252.0000457763672, + "y": 83.9999771118164, + "width": 119.00001525878906, + "height": 77.0000228881836 + } + }, + "m_Slots": [ + { + "m_Id": "62100b5c2cdb420ea029c63cee7e388a" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "IsFirstSlotValid": true +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "d8c308401ebb4d45aabcb025efd14753", + "m_Id": 0, + "m_DisplayName": "Blur", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + diff --git a/Assets/_Content/Shaders/SubGraphes/SceneBlur.shadersubgraph.meta b/Assets/_Content/Shaders/SubGraphes/SceneBlur.shadersubgraph.meta new file mode 100644 index 0000000..3be2aa7 --- /dev/null +++ b/Assets/_Content/Shaders/SubGraphes/SceneBlur.shadersubgraph.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 26f47ae7ba9ee5943993a305e6779681 +ScriptedImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 2 + userData: + assetBundleName: + assetBundleVariant: + script: {fileID: 11500000, guid: 60072b568d64c40a485e0fc55012dc9f, type: 3} + documentationPath: diff --git a/Assets/_Content/Shaders/Teleporter.shadergraph b/Assets/_Content/Shaders/Teleporter.shadergraph new file mode 100644 index 0000000..68759c2 --- /dev/null +++ b/Assets/_Content/Shaders/Teleporter.shadergraph @@ -0,0 +1,3483 @@ +{ + "m_SGVersion": 3, + "m_Type": "UnityEditor.ShaderGraph.GraphData", + "m_ObjectId": "3c24a371673e488988ed189e533a4a96", + "m_Properties": [ + { + "m_Id": "da65b8b11bfb420cb97f88208998d143" + } + ], + "m_Keywords": [], + "m_Dropdowns": [], + "m_CategoryData": [ + { + "m_Id": "185120d504c540b0b5230c785e49bf9b" + } + ], + "m_Nodes": [ + { + "m_Id": "45e564f1c83345d799d70fe2f5fdea41" + }, + { + "m_Id": "618e3e9b8bb5465db9b9a7e824d9cd49" + }, + { + "m_Id": "a177ff71757643f684a36ec971504d5b" + }, + { + "m_Id": "92bf5e1fad884287b73b8ef3cae0d870" + }, + { + "m_Id": "bfc527b4b4384e42b7776b85d42b5978" + }, + { + "m_Id": "22ac2a3522fa4ef995cb0c529df26576" + }, + { + "m_Id": "eddc3f7fd15c4e1eaf7247cfe0283f5e" + }, + { + "m_Id": "0927aa57719642d9945d0a125c2951a6" + }, + { + "m_Id": "18a68cd5accb409a85266653a47e9205" + }, + { + "m_Id": "a2af9f5f8ee146a0a13701b0568b5f03" + }, + { + "m_Id": "c27b9444ac2f45e2a3beef05492b9f10" + }, + { + "m_Id": "ee3fef83043544f4947b85d3a38ff304" + }, + { + "m_Id": "936c01c30bd9428599ae33e9f08b899f" + }, + { + "m_Id": "d426b0eb14db4592b8c71f3bb39f1390" + }, + { + "m_Id": "d673de0ede754c98a7928d091eb9fa7b" + }, + { + "m_Id": "053827f5de914e29b8909f25a88fc125" + }, + { + "m_Id": "4642c7db08074ad0b197799d9afd2516" + }, + { + "m_Id": "2a73bd27cfa24f34a1408c670458502d" + }, + { + "m_Id": "5690d187a7c344b58416cb3f47c67f33" + }, + { + "m_Id": "6e0ec246d08d41c98908e649c6dca714" + }, + { + "m_Id": "b66805a9038a4994925860da1903973e" + }, + { + "m_Id": "bae315548e3b416b9ce12247a0b3c62c" + }, + { + "m_Id": "f2b988ff800c474485a6b32eb7ae23b0" + }, + { + "m_Id": "e3782c4f80804db1b72292a41e70d31e" + }, + { + "m_Id": "af21a13214434730a9db4a99ebbed271" + }, + { + "m_Id": "09c83250c8544336a3db79227e4551f1" + } + ], + "m_GroupDatas": [], + "m_StickyNoteDatas": [], + "m_Edges": [ + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "053827f5de914e29b8909f25a88fc125" + }, + "m_SlotId": 0 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "2a73bd27cfa24f34a1408c670458502d" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "0927aa57719642d9945d0a125c2951a6" + }, + "m_SlotId": 2 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "c27b9444ac2f45e2a3beef05492b9f10" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "18a68cd5accb409a85266653a47e9205" + }, + "m_SlotId": 3 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "5690d187a7c344b58416cb3f47c67f33" + }, + "m_SlotId": 1 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "22ac2a3522fa4ef995cb0c529df26576" + }, + "m_SlotId": 2 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "936c01c30bd9428599ae33e9f08b899f" + }, + "m_SlotId": 1 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "2a73bd27cfa24f34a1408c670458502d" + }, + "m_SlotId": 2 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "d673de0ede754c98a7928d091eb9fa7b" + }, + "m_SlotId": 1 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "4642c7db08074ad0b197799d9afd2516" + }, + "m_SlotId": 2 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "936c01c30bd9428599ae33e9f08b899f" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "5690d187a7c344b58416cb3f47c67f33" + }, + "m_SlotId": 2 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "a2af9f5f8ee146a0a13701b0568b5f03" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "6e0ec246d08d41c98908e649c6dca714" + }, + "m_SlotId": 3 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "5690d187a7c344b58416cb3f47c67f33" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "936c01c30bd9428599ae33e9f08b899f" + }, + "m_SlotId": 2 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "18a68cd5accb409a85266653a47e9205" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "936c01c30bd9428599ae33e9f08b899f" + }, + "m_SlotId": 2 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "6e0ec246d08d41c98908e649c6dca714" + }, + "m_SlotId": 2 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "a2af9f5f8ee146a0a13701b0568b5f03" + }, + "m_SlotId": 2 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "ee3fef83043544f4947b85d3a38ff304" + }, + "m_SlotId": 2 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "af21a13214434730a9db4a99ebbed271" + }, + "m_SlotId": 2 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "09c83250c8544336a3db79227e4551f1" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "b66805a9038a4994925860da1903973e" + }, + "m_SlotId": 0 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "bae315548e3b416b9ce12247a0b3c62c" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "bae315548e3b416b9ce12247a0b3c62c" + }, + "m_SlotId": 4 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "e3782c4f80804db1b72292a41e70d31e" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "bfc527b4b4384e42b7776b85d42b5978" + }, + "m_SlotId": 0 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "22ac2a3522fa4ef995cb0c529df26576" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "d426b0eb14db4592b8c71f3bb39f1390" + }, + "m_SlotId": 1 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "0927aa57719642d9945d0a125c2951a6" + }, + "m_SlotId": 1 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "d426b0eb14db4592b8c71f3bb39f1390" + }, + "m_SlotId": 1 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "09c83250c8544336a3db79227e4551f1" + }, + "m_SlotId": 1 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "d673de0ede754c98a7928d091eb9fa7b" + }, + "m_SlotId": 3 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "4642c7db08074ad0b197799d9afd2516" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "e3782c4f80804db1b72292a41e70d31e" + }, + "m_SlotId": 2 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "af21a13214434730a9db4a99ebbed271" + }, + "m_SlotId": 1 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "eddc3f7fd15c4e1eaf7247cfe0283f5e" + }, + "m_SlotId": 0 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "0927aa57719642d9945d0a125c2951a6" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "eddc3f7fd15c4e1eaf7247cfe0283f5e" + }, + "m_SlotId": 0 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "92bf5e1fad884287b73b8ef3cae0d870" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "ee3fef83043544f4947b85d3a38ff304" + }, + "m_SlotId": 3 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "d426b0eb14db4592b8c71f3bb39f1390" + }, + "m_SlotId": 0 + } + }, + { + "m_OutputSlot": { + "m_Node": { + "m_Id": "f2b988ff800c474485a6b32eb7ae23b0" + }, + "m_SlotId": 1 + }, + "m_InputSlot": { + "m_Node": { + "m_Id": "af21a13214434730a9db4a99ebbed271" + }, + "m_SlotId": 0 + } + } + ], + "m_VertexContext": { + "m_Position": { + "x": 397.0, + "y": 96.0000228881836 + }, + "m_Blocks": [ + { + "m_Id": "45e564f1c83345d799d70fe2f5fdea41" + }, + { + "m_Id": "618e3e9b8bb5465db9b9a7e824d9cd49" + }, + { + "m_Id": "a177ff71757643f684a36ec971504d5b" + } + ] + }, + "m_FragmentContext": { + "m_Position": { + "x": 397.0, + "y": 296.0000305175781 + }, + "m_Blocks": [ + { + "m_Id": "92bf5e1fad884287b73b8ef3cae0d870" + }, + { + "m_Id": "c27b9444ac2f45e2a3beef05492b9f10" + } + ] + }, + "m_PreviewData": { + "serializedMesh": { + "m_SerializedMesh": "{\"mesh\":{\"instanceID\":0}}", + "m_Guid": "" + }, + "preventRotation": false + }, + "m_Path": "Shader Graphs", + "m_GraphPrecision": 1, + "m_PreviewMode": 2, + "m_OutputNode": { + "m_Id": "" + }, + "m_SubDatas": [], + "m_ActiveTargets": [ + { + "m_Id": "e0a3715738cc48178697041e70786ab3" + } + ] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "0219f89e71a54372bd38f2ef8cc2a9ef", + "m_Id": 2, + "m_DisplayName": "Cosine Time", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Cosine Time", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.ColorRGBMaterialSlot", + "m_ObjectId": "02a90578e34d4035aeb945162a93362a", + "m_Id": 0, + "m_DisplayName": "Base Color", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "BaseColor", + "m_StageCapability": 2, + "m_Value": { + "x": 0.5, + "y": 0.5, + "z": 0.5 + }, + "m_DefaultValue": { + "x": 0.5, + "y": 0.5, + "z": 0.5 + }, + "m_Labels": [], + "m_ColorMode": 0, + "m_DefaultColor": { + "r": 0.5, + "g": 0.5, + "b": 0.5, + "a": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.TimeNode", + "m_ObjectId": "053827f5de914e29b8909f25a88fc125", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Time", + "m_DrawState": { + "m_Expanded": false, + "m_Position": { + "serializedVersion": "2", + "x": -2103.0, + "y": -134.0, + "width": 79.0, + "height": 77.0 + } + }, + "m_Slots": [ + { + "m_Id": "a199173fd45e4711bd4769275240e9b1" + }, + { + "m_Id": "f26995af12d64cd4997950504008f467" + }, + { + "m_Id": "0219f89e71a54372bd38f2ef8cc2a9ef" + }, + { + "m_Id": "90a206d80b9248138b698d9f5056453b" + }, + { + "m_Id": "6837c0cb4cc54376a2bedb6a6e3896fb" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.ScreenPositionMaterialSlot", + "m_ObjectId": "0642693c2c0c433aa02d537933fa3eb7", + "m_Id": 0, + "m_DisplayName": "UV", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "UV", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_Labels": [], + "m_ScreenSpaceType": 0 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicValueMaterialSlot", + "m_ObjectId": "06b3e9c29abe4acaa6c4a00e0a6271c7", + "m_Id": 0, + "m_DisplayName": "A", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "A", + "m_StageCapability": 3, + "m_Value": { + "e00": 0.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 0.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 0.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 0.0 + }, + "m_DefaultValue": { + "e00": 1.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 1.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 1.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "08d2e7ca24d7473e91d7f9af92739a4d", + "m_Id": 3, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicValueMaterialSlot", + "m_ObjectId": "08e20b88bb08440bbf8f42d5f3011877", + "m_Id": 1, + "m_DisplayName": "B", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "B", + "m_StageCapability": 3, + "m_Value": { + "e00": 2.0, + "e01": 2.0, + "e02": 2.0, + "e03": 2.0, + "e10": 2.0, + "e11": 2.0, + "e12": 2.0, + "e13": 2.0, + "e20": 2.0, + "e21": 2.0, + "e22": 2.0, + "e23": 2.0, + "e30": 2.0, + "e31": 2.0, + "e32": 2.0, + "e33": 2.0 + }, + "m_DefaultValue": { + "e00": 1.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 1.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 1.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.MultiplyNode", + "m_ObjectId": "0927aa57719642d9945d0a125c2951a6", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Multiply", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 210.99996948242188, + "y": 371.0000305175781, + "width": 130.00009155273438, + "height": 117.99996948242188 + } + }, + "m_Slots": [ + { + "m_Id": "c55c0ae6f1764ac4b2273d735bfd5346" + }, + { + "m_Id": "08e20b88bb08440bbf8f42d5f3011877" + }, + { + "m_Id": "8919e125912d44b193bc9fc72ab4ae24" + } + ], + "synonyms": [ + "multiplication", + "times", + "x" + ], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.MultiplyNode", + "m_ObjectId": "09c83250c8544336a3db79227e4551f1", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Multiply", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -172.0000457763672, + "y": 386.0000305175781, + "width": 126.00005340576172, + "height": 118.0 + } + }, + "m_Slots": [ + { + "m_Id": "744fde082c0f477a9fb7ca1610023fd9" + }, + { + "m_Id": "3c73f9d5e25944ecbbd3b35fc967ab01" + }, + { + "m_Id": "47dfe99d80714b818c95ea7e46b74ba7" + } + ], + "synonyms": [ + "multiplication", + "times", + "x" + ], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "0a4b5f51ca4b4aaa8698cf645348cd56", + "m_Id": 0, + "m_DisplayName": "Alpha", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Alpha", + "m_StageCapability": 2, + "m_Value": 1.0, + "m_DefaultValue": 1.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "0aff3ea969634c97bde7f5a1cfabd90d", + "m_Id": 0, + "m_DisplayName": "Edge1", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Edge1", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.CategoryData", + "m_ObjectId": "185120d504c540b0b5230c785e49bf9b", + "m_Name": "", + "m_ChildObjectList": [ + { + "m_Id": "da65b8b11bfb420cb97f88208998d143" + } + ] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicValueMaterialSlot", + "m_ObjectId": "18760894c7644846a2e011090d076977", + "m_Id": 2, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "e00": 0.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 0.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 0.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 0.0 + }, + "m_DefaultValue": { + "e00": 1.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 1.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 1.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.RemapNode", + "m_ObjectId": "18a68cd5accb409a85266653a47e9205", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Remap", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -1205.0, + "y": 444.9999694824219, + "width": 186.0, + "height": 142.00003051757813 + } + }, + "m_Slots": [ + { + "m_Id": "d481dd03f6844811a6fb1ab00a31668c" + }, + { + "m_Id": "6ed2938837e54a48884feee4b5021a3c" + }, + { + "m_Id": "69cdbef01806486a90e43b7aa912e32f" + }, + { + "m_Id": "f0e0496e488440239cd5acd60ec7d780" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.SplitNode", + "m_ObjectId": "22ac2a3522fa4ef995cb0c529df26576", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Split", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -1592.0, + "y": 201.0, + "width": 120.0, + "height": 148.99996948242188 + } + }, + "m_Slots": [ + { + "m_Id": "24d0753d3d4d460d8310223541ca51a6" + }, + { + "m_Id": "c58ea536b5fa483285ea400e2d874f46" + }, + { + "m_Id": "c088c8b62a2046509886a1751fd2d26f" + }, + { + "m_Id": "387e08ad874c439e9d63e63332dd593c" + }, + { + "m_Id": "37f77b82f493445ca38516d87b951f87" + } + ], + "synonyms": [ + "separate" + ], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "24d0753d3d4d460d8310223541ca51a6", + "m_Id": 0, + "m_DisplayName": "In", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "In", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.MultiplyNode", + "m_ObjectId": "2a73bd27cfa24f34a1408c670458502d", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Multiply", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -1986.0, + "y": -91.0, + "width": 126.0, + "height": 118.0 + } + }, + "m_Slots": [ + { + "m_Id": "5ca99df249624eb1b635524bf19fafc8" + }, + { + "m_Id": "eb5189e72a4e4b049dfafc08418bb549" + }, + { + "m_Id": "18760894c7644846a2e011090d076977" + } + ], + "synonyms": [ + "multiplication", + "times", + "x" + ], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "2af71e0c3db4458b87d914dfb6a90937", + "m_Id": 1, + "m_DisplayName": "AngleOffset", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "AngleOffset", + "m_StageCapability": 3, + "m_Value": 2.0, + "m_DefaultValue": 2.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 2, + "m_Type": "UnityEditor.Rendering.Universal.ShaderGraph.UniversalUnlitSubTarget", + "m_ObjectId": "2c1a9cd6984643faa679b7afa7183a7c", + "m_KeepLightingVariants": false, + "m_DefaultDecalBlending": true, + "m_DefaultSSAO": true +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "2f38489de0734441a7f979daf50d66d2", + "m_Id": 2, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicValueMaterialSlot", + "m_ObjectId": "34d4cef247854949aff879ae161ccf97", + "m_Id": 2, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "e00": 0.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 0.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 0.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 0.0 + }, + "m_DefaultValue": { + "e00": 1.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 1.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 1.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.PositionMaterialSlot", + "m_ObjectId": "35c0afa5505941f6b7ab8b59e8d62d07", + "m_Id": 0, + "m_DisplayName": "Position", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Position", + "m_StageCapability": 1, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_Labels": [], + "m_Space": 0 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "37f77b82f493445ca38516d87b951f87", + "m_Id": 4, + "m_DisplayName": "A", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "A", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "387e08ad874c439e9d63e63332dd593c", + "m_Id": 3, + "m_DisplayName": "B", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "B", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicValueMaterialSlot", + "m_ObjectId": "3c73f9d5e25944ecbbd3b35fc967ab01", + "m_Id": 1, + "m_DisplayName": "B", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "B", + "m_StageCapability": 3, + "m_Value": { + "e00": 2.0, + "e01": 2.0, + "e02": 2.0, + "e03": 2.0, + "e10": 2.0, + "e11": 2.0, + "e12": 2.0, + "e13": 2.0, + "e20": 2.0, + "e21": 2.0, + "e22": 2.0, + "e23": 2.0, + "e30": 2.0, + "e31": 2.0, + "e32": 2.0, + "e33": 2.0 + }, + "m_DefaultValue": { + "e00": 1.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 1.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 1.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "3ee7be3644e949b8ba43db66661003df", + "m_Id": 0, + "m_DisplayName": "In", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "In", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "421cf3fdab494634821df4850c5ae86f", + "m_Id": 1, + "m_DisplayName": "R", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "R", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "44fb3bdc10524937b05c5d4d587a40dc", + "m_Id": 2, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.BlockNode", + "m_ObjectId": "45e564f1c83345d799d70fe2f5fdea41", + "m_Group": { + "m_Id": "" + }, + "m_Name": "VertexDescription.Position", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 0.0, + "y": 0.0, + "width": 0.0, + "height": 0.0 + } + }, + "m_Slots": [ + { + "m_Id": "35c0afa5505941f6b7ab8b59e8d62d07" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_SerializedDescriptor": "VertexDescription.Position" +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.MultiplyNode", + "m_ObjectId": "4642c7db08074ad0b197799d9afd2516", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Multiply", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -1592.0, + "y": 57.999996185302737, + "width": 126.0, + "height": 117.99998474121094 + } + }, + "m_Slots": [ + { + "m_Id": "06b3e9c29abe4acaa6c4a00e0a6271c7" + }, + { + "m_Id": "811ffc4881b040679f603530a78773ef" + }, + { + "m_Id": "34d4cef247854949aff879ae161ccf97" + } + ], + "synonyms": [ + "multiplication", + "times", + "x" + ], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicValueMaterialSlot", + "m_ObjectId": "47dfe99d80714b818c95ea7e46b74ba7", + "m_Id": 2, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "e00": 0.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 0.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 0.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 0.0 + }, + "m_DefaultValue": { + "e00": 1.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 1.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 1.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "486cb619e74641e69559fbcc730c587c", + "m_Id": 0, + "m_DisplayName": "A", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "A", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "4a04270a33614d7eb453f8354d6ef64a", + "m_Id": 1, + "m_DisplayName": "Edge2", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Edge2", + "m_StageCapability": 3, + "m_Value": { + "x": 1.0, + "y": 1.0, + "z": 1.0, + "w": 1.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.NormalMaterialSlot", + "m_ObjectId": "4f888822ad9149408bd55c9fed9602e9", + "m_Id": 0, + "m_DisplayName": "Normal", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Normal", + "m_StageCapability": 1, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_Labels": [], + "m_Space": 0 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.AddNode", + "m_ObjectId": "5690d187a7c344b58416cb3f47c67f33", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Add", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -958.0, + "y": 386.0, + "width": 126.0, + "height": 117.99996948242188 + } + }, + "m_Slots": [ + { + "m_Id": "486cb619e74641e69559fbcc730c587c" + }, + { + "m_Id": "b665c254ce934e7d906bbe6fbd355fe8" + }, + { + "m_Id": "f608d4aedd054c6ab08953df9a50507e" + } + ], + "synonyms": [ + "addition", + "sum", + "plus" + ], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicValueMaterialSlot", + "m_ObjectId": "5ca99df249624eb1b635524bf19fafc8", + "m_Id": 0, + "m_DisplayName": "A", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "A", + "m_StageCapability": 3, + "m_Value": { + "e00": 0.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 0.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 0.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 0.0 + }, + "m_DefaultValue": { + "e00": 1.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 1.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 1.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "5d48be6f504a4cafb225460054134b71", + "m_Id": 4, + "m_DisplayName": "A", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "A", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.BlockNode", + "m_ObjectId": "618e3e9b8bb5465db9b9a7e824d9cd49", + "m_Group": { + "m_Id": "" + }, + "m_Name": "VertexDescription.Normal", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 0.0, + "y": 0.0, + "width": 0.0, + "height": 0.0 + } + }, + "m_Slots": [ + { + "m_Id": "4f888822ad9149408bd55c9fed9602e9" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_SerializedDescriptor": "VertexDescription.Normal" +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "642d460700f04ccca296bea826db184f", + "m_Id": 1, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 2, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "66910c0ae19b413c85a7cb4fabfabd47", + "m_Id": 3, + "m_DisplayName": "B", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "B", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "6837c0cb4cc54376a2bedb6a6e3896fb", + "m_Id": 4, + "m_DisplayName": "Smooth Delta", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Smooth Delta", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "6953c373995c484a86f44f60865c045e", + "m_Id": 2, + "m_DisplayName": "In", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "In", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector2MaterialSlot", + "m_ObjectId": "69cdbef01806486a90e43b7aa912e32f", + "m_Id": 2, + "m_DisplayName": "Out Min Max", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "OutMinMax", + "m_StageCapability": 3, + "m_Value": { + "x": 1.0, + "y": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 1.0 + }, + "m_Labels": [] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.SmoothstepNode", + "m_ObjectId": "6e0ec246d08d41c98908e649c6dca714", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Smoothstep", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -1124.9998779296875, + "y": 181.0, + "width": 151.99993896484376, + "height": 142.0 + } + }, + "m_Slots": [ + { + "m_Id": "f5b16ceffb2e4aaaaf83e8ca4505d0d9" + }, + { + "m_Id": "de2671aed46f47a584a5e956f79dccc7" + }, + { + "m_Id": "6953c373995c484a86f44f60865c045e" + }, + { + "m_Id": "94adffa6872c4a759c77d59db6fa23ff" + } + ], + "synonyms": [ + "curve" + ], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector3MaterialSlot", + "m_ObjectId": "6ea0f5695dcd4ea1838baf2a4da1be4b", + "m_Id": 0, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_Labels": [] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector2MaterialSlot", + "m_ObjectId": "6ed2938837e54a48884feee4b5021a3c", + "m_Id": 1, + "m_DisplayName": "In Min Max", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "InMinMax", + "m_StageCapability": 3, + "m_Value": { + "x": -1.0, + "y": 1.0 + }, + "m_DefaultValue": { + "x": -1.0, + "y": 1.0 + }, + "m_Labels": [] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector4MaterialSlot", + "m_ObjectId": "70a872716d7f4ae09ed905505d77ab5b", + "m_Id": 0, + "m_DisplayName": "Color", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_Labels": [] +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "72f85bf9a81343c69524949c56033d25", + "m_Id": 3, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicValueMaterialSlot", + "m_ObjectId": "744fde082c0f477a9fb7ca1610023fd9", + "m_Id": 0, + "m_DisplayName": "A", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "A", + "m_StageCapability": 3, + "m_Value": { + "e00": 0.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 0.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 0.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 0.0 + }, + "m_DefaultValue": { + "e00": 1.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 1.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 1.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "7939d3c129a34d0ea8fd322114020da4", + "m_Id": 4, + "m_DisplayName": "Cells", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Cells", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "7bc3c75528574e21ba3230106e37e374", + "m_Id": 0, + "m_DisplayName": "A", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "A", + "m_StageCapability": 3, + "m_Value": { + "x": 1.0, + "y": 1.0, + "z": 1.0, + "w": 1.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicValueMaterialSlot", + "m_ObjectId": "811ffc4881b040679f603530a78773ef", + "m_Id": 1, + "m_DisplayName": "B", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "B", + "m_StageCapability": 3, + "m_Value": { + "e00": 0.10000000149011612, + "e01": 2.0, + "e02": 2.0, + "e03": 2.0, + "e10": 2.0, + "e11": 2.0, + "e12": 2.0, + "e13": 2.0, + "e20": 2.0, + "e21": 2.0, + "e22": 2.0, + "e23": 2.0, + "e30": 2.0, + "e31": 2.0, + "e32": 2.0, + "e33": 2.0 + }, + "m_DefaultValue": { + "e00": 1.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 1.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 1.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "85f41857a8284a219e88b0e784ead967", + "m_Id": 1, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "8616485e2b28424ca29737ef3e4e91bc", + "m_Id": 2, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicValueMaterialSlot", + "m_ObjectId": "8919e125912d44b193bc9fc72ab4ae24", + "m_Id": 2, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "e00": 0.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 0.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 0.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 0.0 + }, + "m_DefaultValue": { + "e00": 1.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 1.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 1.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "90a206d80b9248138b698d9f5056453b", + "m_Id": 3, + "m_DisplayName": "Delta Time", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Delta Time", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.BlockNode", + "m_ObjectId": "92bf5e1fad884287b73b8ef3cae0d870", + "m_Group": { + "m_Id": "" + }, + "m_Name": "SurfaceDescription.BaseColor", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 0.0, + "y": 0.0, + "width": 0.0, + "height": 0.0 + } + }, + "m_Slots": [ + { + "m_Id": "02a90578e34d4035aeb945162a93362a" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_SerializedDescriptor": "SurfaceDescription.BaseColor" +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.AddNode", + "m_ObjectId": "936c01c30bd9428599ae33e9f08b899f", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Add", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -1440.0, + "y": 198.0, + "width": 208.0, + "height": 302.0 + } + }, + "m_Slots": [ + { + "m_Id": "d5f288fc63394bc8bf3da5d8b2abd34b" + }, + { + "m_Id": "9727bea394b7491d81f3d9212caa6ce5" + }, + { + "m_Id": "2f38489de0734441a7f979daf50d66d2" + } + ], + "synonyms": [ + "addition", + "sum", + "plus" + ], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "9428e9fc61df411ebe46ae9558401e52", + "m_Id": 0, + "m_DisplayName": "A", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "A", + "m_StageCapability": 3, + "m_Value": { + "x": 1.0, + "y": 1.0, + "z": 1.0, + "w": 1.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "94adffa6872c4a759c77d59db6fa23ff", + "m_Id": 3, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "9727bea394b7491d81f3d9212caa6ce5", + "m_Id": 1, + "m_DisplayName": "B", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "B", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "9d581fc9901b4f70be0f810515ced281", + "m_Id": 1, + "m_DisplayName": "B", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "B", + "m_StageCapability": 3, + "m_Value": { + "x": 0.30000001192092898, + "y": 1.0, + "z": 1.0, + "w": 1.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.BlockNode", + "m_ObjectId": "a177ff71757643f684a36ec971504d5b", + "m_Group": { + "m_Id": "" + }, + "m_Name": "VertexDescription.Tangent", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 0.0, + "y": 0.0, + "width": 0.0, + "height": 0.0 + } + }, + "m_Slots": [ + { + "m_Id": "e61729ae71f04caba99931743fe28526" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_SerializedDescriptor": "VertexDescription.Tangent" +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "a199173fd45e4711bd4769275240e9b1", + "m_Id": 0, + "m_DisplayName": "Time", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Time", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.PowerNode", + "m_ObjectId": "a2af9f5f8ee146a0a13701b0568b5f03", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Power", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -756.0, + "y": 516.0000610351563, + "width": 125.99993896484375, + "height": 118.0 + } + }, + "m_Slots": [ + { + "m_Id": "b1e45ac805f945e086297ec97343f390" + }, + { + "m_Id": "ea736d7c1a004ff9bdd050fc8d749427" + }, + { + "m_Id": "44fb3bdc10524937b05c5d4d587a40dc" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.SubtractNode", + "m_ObjectId": "af21a13214434730a9db4a99ebbed271", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Subtract", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -373.0000305175781, + "y": 96.0, + "width": 126.0, + "height": 118.00003051757813 + } + }, + "m_Slots": [ + { + "m_Id": "7bc3c75528574e21ba3230106e37e374" + }, + { + "m_Id": "9d581fc9901b4f70be0f810515ced281" + }, + { + "m_Id": "8616485e2b28424ca29737ef3e4e91bc" + } + ], + "synonyms": [ + "subtraction", + "remove", + "minus", + "take away" + ], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "b1e45ac805f945e086297ec97343f390", + "m_Id": 0, + "m_DisplayName": "A", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "A", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "b554d8bfbb804eb0b36178bf2905a2e2", + "m_Id": 2, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "b665c254ce934e7d906bbe6fbd355fe8", + "m_Id": 1, + "m_DisplayName": "B", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "B", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.ScreenPositionNode", + "m_ObjectId": "b66805a9038a4994925860da1903973e", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Screen Position", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -868.0, + "y": 108.99999237060547, + "width": 144.99993896484376, + "height": 128.0 + } + }, + "m_Slots": [ + { + "m_Id": "f987169396bb47d3a8d871cb17fd7e29" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_ScreenSpaceType": 1 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.SplitNode", + "m_ObjectId": "bae315548e3b416b9ce12247a0b3c62c", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Split", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -702.0, + "y": 108.99999237060547, + "width": 119.99993896484375, + "height": 148.99996948242188 + } + }, + "m_Slots": [ + { + "m_Id": "d96aa5cf8e124d8e9508f1af10066616" + }, + { + "m_Id": "421cf3fdab494634821df4850c5ae86f" + }, + { + "m_Id": "cdb09dbcb94e4942b1c2fcf0d25fa5ad" + }, + { + "m_Id": "66910c0ae19b413c85a7cb4fabfabd47" + }, + { + "m_Id": "5d48be6f504a4cafb225460054134b71" + } + ], + "synonyms": [ + "separate" + ], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 1, + "m_Type": "UnityEditor.ShaderGraph.PositionNode", + "m_ObjectId": "bfc527b4b4384e42b7776b85d42b5978", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Position", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -1860.0, + "y": 201.0, + "width": 208.0, + "height": 314.0 + } + }, + "m_Slots": [ + { + "m_Id": "6ea0f5695dcd4ea1838baf2a4da1be4b" + } + ], + "synonyms": [ + "location" + ], + "m_Precision": 1, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 2, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_Space": 0, + "m_PositionSource": 0 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "c088c8b62a2046509886a1751fd2d26f", + "m_Id": 2, + "m_DisplayName": "G", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "G", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.BlockNode", + "m_ObjectId": "c27b9444ac2f45e2a3beef05492b9f10", + "m_Group": { + "m_Id": "" + }, + "m_Name": "SurfaceDescription.Alpha", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 0.0, + "y": 0.0, + "width": 0.0, + "height": 0.0 + } + }, + "m_Slots": [ + { + "m_Id": "0a4b5f51ca4b4aaa8698cf645348cd56" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_SerializedDescriptor": "SurfaceDescription.Alpha" +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicValueMaterialSlot", + "m_ObjectId": "c55c0ae6f1764ac4b2273d735bfd5346", + "m_Id": 0, + "m_DisplayName": "A", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "A", + "m_StageCapability": 3, + "m_Value": { + "e00": 0.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 0.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 0.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 0.0 + }, + "m_DefaultValue": { + "e00": 1.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 1.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 1.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "c58ea536b5fa483285ea400e2d874f46", + "m_Id": 1, + "m_DisplayName": "R", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "R", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.UVMaterialSlot", + "m_ObjectId": "c5f988123b2941759541c05a15a059b9", + "m_Id": 0, + "m_DisplayName": "UV", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "UV", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0 + }, + "m_Labels": [], + "m_Channel": 0 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "cdb09dbcb94e4942b1c2fcf0d25fa5ad", + "m_Id": 2, + "m_DisplayName": "G", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "G", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.SaturateNode", + "m_ObjectId": "d426b0eb14db4592b8c71f3bb39f1390", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Saturate", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -372.9999694824219, + "y": 394.0, + "width": 127.99995422363281, + "height": 93.99996948242188 + } + }, + "m_Slots": [ + { + "m_Id": "3ee7be3644e949b8ba43db66661003df" + }, + { + "m_Id": "85f41857a8284a219e88b0e784ead967" + } + ], + "synonyms": [ + "clamp" + ], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "d481dd03f6844811a6fb1ab00a31668c", + "m_Id": 0, + "m_DisplayName": "In", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "In", + "m_StageCapability": 3, + "m_Value": { + "x": -1.0, + "y": -1.0, + "z": -1.0, + "w": -1.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "d5f288fc63394bc8bf3da5d8b2abd34b", + "m_Id": 0, + "m_DisplayName": "A", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "A", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 1, + "m_Type": "UnityEditor.ShaderGraph.VoronoiNode", + "m_ObjectId": "d673de0ede754c98a7928d091eb9fa7b", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Voronoi", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -1827.0, + "y": -260.0, + "width": 208.0, + "height": 360.0 + } + }, + "m_Slots": [ + { + "m_Id": "c5f988123b2941759541c05a15a059b9" + }, + { + "m_Id": "2af71e0c3db4458b87d914dfb6a90937" + }, + { + "m_Id": "de81d660525a42eda4c81806473e0996" + }, + { + "m_Id": "08d2e7ca24d7473e91d7f9af92739a4d" + }, + { + "m_Id": "7939d3c129a34d0ea8fd322114020da4" + } + ], + "synonyms": [ + "worley noise" + ], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_HashType": 0 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "d834471efef443ba81cbdc86bf9ec9fc", + "m_Id": 2, + "m_DisplayName": "In", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "In", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "d96aa5cf8e124d8e9508f1af10066616", + "m_Id": 0, + "m_DisplayName": "In", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "In", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 3, + "m_Type": "UnityEditor.ShaderGraph.Internal.ColorShaderProperty", + "m_ObjectId": "da65b8b11bfb420cb97f88208998d143", + "m_Guid": { + "m_GuidSerialized": "693a611a-d203-4b7a-8e0a-e204da4994eb" + }, + "promotedFromAssetID": "", + "promotedFromCategoryName": "", + "promotedOrdering": -1, + "m_Name": "Color", + "m_DefaultRefNameVersion": 1, + "m_RefNameGeneratedByDisplayName": "Color", + "m_DefaultReferenceName": "_Color", + "m_OverrideReferenceName": "", + "m_GeneratePropertyBlock": true, + "m_UseCustomSlotLabel": false, + "m_CustomSlotLabel": "", + "m_DismissedVersion": 0, + "m_Precision": 0, + "overrideHLSLDeclaration": false, + "hlslDeclarationOverride": 0, + "m_Hidden": false, + "m_PerRendererData": false, + "m_customAttributes": [], + "m_Value": { + "r": 0.6341598033905029, + "g": 0.8542711138725281, + "b": 1.3041189908981324, + "a": 1.0 + }, + "isMainColor": false, + "m_ColorMode": 1 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "daef8f1185ab46c7ba92decbc643d2c6", + "m_Id": 1, + "m_DisplayName": "B", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "B", + "m_StageCapability": 3, + "m_Value": { + "x": 0.9900000095367432, + "y": 1.0, + "z": 1.0, + "w": 1.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "de2671aed46f47a584a5e956f79dccc7", + "m_Id": 1, + "m_DisplayName": "Edge2", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Edge2", + "m_StageCapability": 3, + "m_Value": { + "x": -1.5700000524520875, + "y": 1.0, + "z": 1.0, + "w": 1.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "de81d660525a42eda4c81806473e0996", + "m_Id": 2, + "m_DisplayName": "CellDensity", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "CellDensity", + "m_StageCapability": 3, + "m_Value": 5.0, + "m_DefaultValue": 5.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 1, + "m_Type": "UnityEditor.Rendering.Universal.ShaderGraph.UniversalTarget", + "m_ObjectId": "e0a3715738cc48178697041e70786ab3", + "m_Datas": [], + "m_ActiveSubTarget": { + "m_Id": "2c1a9cd6984643faa679b7afa7183a7c" + }, + "m_AllowMaterialOverride": false, + "m_SurfaceType": 1, + "m_ZTestMode": 4, + "m_ZWriteControl": 0, + "m_AlphaMode": 2, + "m_RenderFace": 0, + "m_AlphaClip": false, + "m_CastShadows": true, + "m_ReceiveShadows": true, + "m_DisableTint": false, + "m_Sort3DAs2DCompatible": false, + "m_AdditionalMotionVectorMode": 0, + "m_AlembicMotionVectors": false, + "m_SupportsLODCrossFade": false, + "m_CustomEditorGUI": "", + "m_SupportVFX": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.SubtractNode", + "m_ObjectId": "e3782c4f80804db1b72292a41e70d31e", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Subtract", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -550.0000610351563, + "y": 213.9999542236328, + "width": 126.0, + "height": 118.00001525878906 + } + }, + "m_Slots": [ + { + "m_Id": "9428e9fc61df411ebe46ae9558401e52" + }, + { + "m_Id": "daef8f1185ab46c7ba92decbc643d2c6" + }, + { + "m_Id": "b554d8bfbb804eb0b36178bf2905a2e2" + } + ], + "synonyms": [ + "subtraction", + "remove", + "minus", + "take away" + ], + "m_Precision": 0, + "m_PreviewExpanded": false, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.TangentMaterialSlot", + "m_ObjectId": "e61729ae71f04caba99931743fe28526", + "m_Id": 0, + "m_DisplayName": "Tangent", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Tangent", + "m_StageCapability": 1, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0 + }, + "m_Labels": [], + "m_Space": 0 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "ea736d7c1a004ff9bdd050fc8d749427", + "m_Id": 1, + "m_DisplayName": "B", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "B", + "m_StageCapability": 3, + "m_Value": { + "x": 2.0, + "y": 2.0, + "z": 2.0, + "w": 2.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicValueMaterialSlot", + "m_ObjectId": "eb5189e72a4e4b049dfafc08418bb549", + "m_Id": 1, + "m_DisplayName": "B", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "B", + "m_StageCapability": 3, + "m_Value": { + "e00": 5.0, + "e01": 2.0, + "e02": 2.0, + "e03": 2.0, + "e10": 2.0, + "e11": 2.0, + "e12": 2.0, + "e13": 2.0, + "e20": 2.0, + "e21": 2.0, + "e22": 2.0, + "e23": 2.0, + "e30": 2.0, + "e31": 2.0, + "e32": 2.0, + "e33": 2.0 + }, + "m_DefaultValue": { + "e00": 1.0, + "e01": 0.0, + "e02": 0.0, + "e03": 0.0, + "e10": 0.0, + "e11": 1.0, + "e12": 0.0, + "e13": 0.0, + "e20": 0.0, + "e21": 0.0, + "e22": 1.0, + "e23": 0.0, + "e30": 0.0, + "e31": 0.0, + "e32": 0.0, + "e33": 1.0 + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.PropertyNode", + "m_ObjectId": "eddc3f7fd15c4e1eaf7247cfe0283f5e", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Property", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": 77.00009155273438, + "y": 327.0000305175781, + "width": 105.00001525878906, + "height": 34.0 + } + }, + "m_Slots": [ + { + "m_Id": "70a872716d7f4ae09ed905505d77ab5b" + } + ], + "synonyms": [], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_Property": { + "m_Id": "da65b8b11bfb420cb97f88208998d143" + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.SmoothstepNode", + "m_ObjectId": "ee3fef83043544f4947b85d3a38ff304", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Smoothstep", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -605.0, + "y": 394.0000305175781, + "width": 208.0, + "height": 326.0000305175781 + } + }, + "m_Slots": [ + { + "m_Id": "0aff3ea969634c97bde7f5a1cfabd90d" + }, + { + "m_Id": "4a04270a33614d7eb453f8354d6ef64a" + }, + { + "m_Id": "d834471efef443ba81cbdc86bf9ec9fc" + }, + { + "m_Id": "72f85bf9a81343c69524949c56033d25" + } + ], + "synonyms": [ + "curve" + ], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + } +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "f0e0496e488440239cd5acd60ec7d780", + "m_Id": 3, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector1MaterialSlot", + "m_ObjectId": "f26995af12d64cd4997950504008f467", + "m_Id": 1, + "m_DisplayName": "Sine Time", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Sine Time", + "m_StageCapability": 3, + "m_Value": 0.0, + "m_DefaultValue": 0.0, + "m_Labels": [], + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.SceneDepthNode", + "m_ObjectId": "f2b988ff800c474485a6b32eb7ae23b0", + "m_Group": { + "m_Id": "" + }, + "m_Name": "Scene Depth", + "m_DrawState": { + "m_Expanded": true, + "m_Position": { + "serializedVersion": "2", + "x": -727.0000610351563, + "y": -29.000009536743165, + "width": 145.0, + "height": 110.99999237060547 + } + }, + "m_Slots": [ + { + "m_Id": "0642693c2c0c433aa02d537933fa3eb7" + }, + { + "m_Id": "642d460700f04ccca296bea826db184f" + } + ], + "synonyms": [ + "zbuffer", + "zdepth" + ], + "m_Precision": 0, + "m_PreviewExpanded": true, + "m_DismissedVersion": 0, + "m_PreviewMode": 0, + "m_CustomColors": { + "m_SerializableColors": [] + }, + "m_DepthSamplingMode": 2 +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "f5b16ceffb2e4aaaaf83e8ca4505d0d9", + "m_Id": 0, + "m_DisplayName": "Edge1", + "m_SlotType": 0, + "m_Hidden": false, + "m_ShaderOutputName": "Edge1", + "m_StageCapability": 3, + "m_Value": { + "x": -0.9399999976158142, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.DynamicVectorMaterialSlot", + "m_ObjectId": "f608d4aedd054c6ab08953df9a50507e", + "m_Id": 2, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_LiteralMode": false +} + +{ + "m_SGVersion": 0, + "m_Type": "UnityEditor.ShaderGraph.Vector4MaterialSlot", + "m_ObjectId": "f987169396bb47d3a8d871cb17fd7e29", + "m_Id": 0, + "m_DisplayName": "Out", + "m_SlotType": 1, + "m_Hidden": false, + "m_ShaderOutputName": "Out", + "m_StageCapability": 3, + "m_Value": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_DefaultValue": { + "x": 0.0, + "y": 0.0, + "z": 0.0, + "w": 0.0 + }, + "m_Labels": [] +} + diff --git a/Assets/_Content/Shaders/Teleporter.shadergraph.meta b/Assets/_Content/Shaders/Teleporter.shadergraph.meta new file mode 100644 index 0000000..dec3b5f --- /dev/null +++ b/Assets/_Content/Shaders/Teleporter.shadergraph.meta @@ -0,0 +1,18 @@ +fileFormatVersion: 2 +guid: 57626961be12583439d7170a477a46ef +ScriptedImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 2 + userData: + assetBundleName: + assetBundleVariant: + script: {fileID: 11500000, guid: 625f186215c104763be7675aa2d941aa, type: 3} + useAsTemplate: 0 + exposeTemplateAsShader: 0 + template: + name: + category: + description: + icon: {instanceID: 0} + thumbnail: {instanceID: 0} diff --git a/Assets/_Content/Shaders/WorldGrid.shader b/Assets/_Content/Shaders/WorldGrid.shader new file mode 100644 index 0000000..b1cd39c --- /dev/null +++ b/Assets/_Content/Shaders/WorldGrid.shader @@ -0,0 +1,322 @@ +Shader "Coiriergraphics/WorldGrid" +{ + Properties + { + [MainColor] _BaseColor ("ColorA", Color) = (0.105, 0.17, 0.22, 1) + _LineColor ("ColorB", Color) = (1, 1, 1, 1) + _DarkColor ("ColorC", Color) = (0.035, 0.055, 0.07, 1) + _Metallic ("Metallic", Range(0, 1)) = 0 + _Smoothness ("Smoothness", Range(0, 1)) = 0.3 + } + + SubShader + { + Tags { "RenderType"="Opaque" "RenderPipeline"="UniversalPipeline" "Queue"="Geometry" } + LOD 300 + + HLSLINCLUDE + #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl" + + CBUFFER_START(UnityPerMaterial) + half4 _BaseColor; + half4 _LineColor; + half4 _DarkColor; + half _Metallic; + half _Smoothness; + CBUFFER_END + + // Fixed pattern settings (meters, after object scale compensation). + #define TRIPLANAR_SHARPNESS 16.0 + #define DOT_SPACING 0.2 + #define DOT_DIAMETER 0.026 + #define DOT_DARKEN 0.30 + #define DOT_FADE_START 1.5 + #define DOT_FADE_END 5.0 + #define GRID_WIDTH 0.008 + #define GRID_DARKEN 0.45 + #define MAJOR_GRID_WIDTH 0.015 + #define MAJOR_GRID_OPACITY 0.20 + #define CROSS_ARM_LENGTH 0.0425 + #define CROSS_WIDTH 0.014 + #define MAJOR_CROSS_ARM_LENGTH 0.14 + #define MAJOR_CROSS_WIDTH 0.040 + #define CROSS_OPACITY 0.11875 + + // Anti-alias the edge, but NEVER inflate tiny shapes by the full pixel + // footprint. That was turning the crosses into huge white squares. + float Stroke(float distanceToCenter, float halfWidth, float pixelWidth) + { + float edge = max(min(pixelWidth * 0.5, halfWidth * 0.5), 0.000001); + return 1.0 - smoothstep(halfWidth - edge, halfWidth + edge, distanceToCenter); + } + + // x = dots, y = 1m grid, z = 4m major grid, w = small crosses. + // Larger 4m crosses are returned separately so they can force the full pattern color. + float4 Pattern2D(float2 p, out float majorCrossMask) + { + float2 pixel = max(fwidth(p), float2(0.000001, 0.000001)); + float footprint = max(pixel.x, pixel.y); + + float2 dotIndex = floor(p / DOT_SPACING + 0.5); + float2 dotLocal = p - dotIndex * DOT_SPACING; + float dotMask = Stroke(length(dotLocal), DOT_DIAMETER * 0.5, length(pixel)); + // Entire dot rows and columns coinciding with a 1m grid line are absent. + // This avoids visible circles straddling thin lines (even with AA). + float2 distanceToGridIndex = abs((frac(dotIndex / 5.0 + 0.5) - 0.5) * 5.0); + dotMask *= step(0.5, min(distanceToGridIndex.x, distanceToGridIndex.y)); + // Remove sub-pixel dots rather than allowing them to alias or expand. + dotMask *= 1.0 - smoothstep(0.004, 0.014, footprint); + + float2 cell = frac(p + 0.5) - 0.5; + float2 gridDist = abs(cell); + float gridMask = max( + Stroke(gridDist.x, GRID_WIDTH * 0.5, pixel.x), + Stroke(gridDist.y, GRID_WIDTH * 0.5, pixel.y)); + gridMask *= 1.0 - smoothstep(0.025, 0.10, footprint); + + float2 majorDist = abs((frac(p / 4.0 + 0.5) - 0.5) * 4.0); + float majorMask = max( + Stroke(majorDist.x, MAJOR_GRID_WIDTH * 0.5, pixel.x), + Stroke(majorDist.y, MAJOR_GRID_WIDTH * 0.5, pixel.y)); + + // True plus signs: intersect two thin, finite line segments. + float horizontal = Stroke(abs(cell.y), CROSS_WIDTH * 0.5, pixel.y) + * Stroke(abs(cell.x), CROSS_ARM_LENGTH, pixel.x); + float vertical = Stroke(abs(cell.x), CROSS_WIDTH * 0.5, pixel.x) + * Stroke(abs(cell.y), CROSS_ARM_LENGTH, pixel.y); + float crossMask = max(horizontal, vertical); + // Suppress the ENTIRE cross at 1m intersections located on 4m lines. + // Using the nearest integer grid intersection prevents partial crosses. + float2 intersection = floor(p + 0.5); + float2 intersection4 = abs((frac(intersection / 4.0 + 0.5) - 0.5) * 4.0); + crossMask *= step(0.5, min(intersection4.x, intersection4.y)); + // Crosses are intentionally not drawn when they become sub-pixel. + crossMask *= 1.0 - smoothstep(0.025, 0.09, footprint); + + // Larger crosses only at intersections of TWO 4m lines. + float majorHorizontal = Stroke(majorDist.y, MAJOR_CROSS_WIDTH * 0.5, pixel.y) + * Stroke(majorDist.x, MAJOR_CROSS_ARM_LENGTH, pixel.x); + float majorVertical = Stroke(majorDist.x, MAJOR_CROSS_WIDTH * 0.5, pixel.x) + * Stroke(majorDist.y, MAJOR_CROSS_ARM_LENGTH, pixel.y); + majorCrossMask = max(majorHorizontal, majorVertical); + majorCrossMask *= 1.0 - smoothstep(0.025, 0.09, footprint); + + // Dots must not appear on ANY line work: 1m grid, 4m grid, 1m crosses, or 4m crosses. + float occupiedByLines = saturate(max(max(gridMask, majorMask), max(crossMask, majorCrossMask))); + dotMask *= 1.0 - occupiedByLines; + + return saturate(float4(dotMask, gridMask, majorMask, crossMask)); + } + + float3 ObjectAxisScales() + { + float3x3 m = (float3x3)GetObjectToWorldMatrix(); + return float3(length(mul(m, float3(1, 0, 0))), + length(mul(m, float3(0, 1, 0))), + length(mul(m, float3(0, 0, 1)))); + } + ENDHLSL + + Pass + { + Name "ForwardLit" + Tags { "LightMode"="UniversalForward" } + Cull Back + ZWrite On + + HLSLPROGRAM + #pragma target 3.5 + #pragma vertex Vert + #pragma fragment Frag + #pragma multi_compile _ _MAIN_LIGHT_SHADOWS _MAIN_LIGHT_SHADOWS_CASCADE _MAIN_LIGHT_SHADOWS_SCREEN + #pragma multi_compile _ _ADDITIONAL_LIGHTS_VERTEX _ADDITIONAL_LIGHTS + #pragma multi_compile _ _ADDITIONAL_LIGHT_SHADOWS + #pragma multi_compile _ _SHADOWS_SOFT + #pragma multi_compile_fog + #pragma multi_compile _ LIGHTMAP_ON + #pragma multi_compile _ DIRLIGHTMAP_COMBINED + #pragma multi_compile _ _FORWARD_PLUS + #pragma multi_compile_instancing + + #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Lighting.hlsl" + + struct Attributes + { + float3 positionOS : POSITION; + float3 normalOS : NORMAL; + float2 staticLightmapUV : TEXCOORD1; + UNITY_VERTEX_INPUT_INSTANCE_ID + }; + + struct Varyings + { + float4 positionCS : SV_POSITION; + float3 positionWS : TEXCOORD0; + half3 normalWS : TEXCOORD1; + float3 positionOS : TEXCOORD5; + half3 normalOS : TEXCOORD6; + half3 vertexLighting : TEXCOORD2; + half fogFactor : TEXCOORD3; + DECLARE_LIGHTMAP_OR_SH(staticLightmapUV, vertexSH, 4); + UNITY_VERTEX_INPUT_INSTANCE_ID + }; + + Varyings Vert(Attributes input) + { + Varyings output = (Varyings)0; + UNITY_SETUP_INSTANCE_ID(input); + UNITY_TRANSFER_INSTANCE_ID(input, output); + VertexPositionInputs pos = GetVertexPositionInputs(input.positionOS); + VertexNormalInputs nrm = GetVertexNormalInputs(input.normalOS); + output.positionCS = pos.positionCS; + output.positionWS = pos.positionWS; + output.positionOS = input.positionOS; + output.normalOS = input.normalOS; + output.normalWS = nrm.normalWS; + output.vertexLighting = VertexLighting(pos.positionWS, nrm.normalWS); + output.fogFactor = ComputeFogFactor(pos.positionCS.z); + OUTPUT_LIGHTMAP_UV(input.staticLightmapUV, unity_LightmapST, output.staticLightmapUV); + OUTPUT_SH(output.normalWS, output.vertexSH); + return output; + } + + half4 Frag(Varyings input) : SV_Target + { + UNITY_SETUP_INSTANCE_ID(input); + float3 n = normalize(input.normalWS); + // Object-local projection, expressed in physical meters along each local axis. + // Moving/rotating an object moves/rotates the grid. Scaling it preserves spacing. + float3 patternPosition = input.positionOS * ObjectAxisScales(); + float3 localN = normalize((float3)input.normalOS); + float3 weights = pow(abs(localN), TRIPLANAR_SHARPNESS); + weights /= max(weights.x + weights.y + weights.z, 0.00001); + + float crossX, crossY, crossZ; + float4 pattern = Pattern2D(patternPosition.yz, crossX) * weights.x + + Pattern2D(patternPosition.xz, crossY) * weights.y + + Pattern2D(patternPosition.xy, crossZ) * weights.z; + float majorCross = saturate(crossX * weights.x + crossY * weights.y + crossZ * weights.z); + + // Tiny dark dots fade away with camera distance. + float cameraDistance = distance(input.positionWS, _WorldSpaceCameraPos); + float dotVisibility = 1.0 - smoothstep(DOT_FADE_START, DOT_FADE_END, cameraDistance); + half3 albedo = _BaseColor.rgb; + float darkening = saturate(pattern.x * DOT_DARKEN * dotVisibility + + pattern.y * GRID_DARKEN); + albedo = lerp(albedo, _DarkColor.rgb, darkening); + // "Transparency" is expressed as a color blend factor toward Pattern Color. + albedo = lerp(albedo, _LineColor.rgb, + saturate(pattern.z * MAJOR_GRID_OPACITY)); + albedo = lerp(albedo, _LineColor.rgb, + saturate(pattern.w * CROSS_OPACITY)); + // 4m crosses always use the full Pattern Color. + albedo = lerp(albedo, _LineColor.rgb, saturate(majorCross)); + + SurfaceData surface = (SurfaceData)0; + surface.albedo = albedo; + surface.alpha = 1; + surface.metallic = _Metallic; + surface.smoothness = _Smoothness; + surface.normalTS = half3(0, 0, 1); + surface.occlusion = 1; + + InputData lighting = (InputData)0; + lighting.positionWS = input.positionWS; + lighting.normalWS = n; + lighting.viewDirectionWS = GetWorldSpaceNormalizeViewDir(input.positionWS); + lighting.shadowCoord = TransformWorldToShadowCoord(input.positionWS); + lighting.fogCoord = input.fogFactor; + lighting.vertexLighting = input.vertexLighting; + lighting.bakedGI = SAMPLE_GI(input.staticLightmapUV, input.vertexSH, n); + lighting.normalizedScreenSpaceUV = GetNormalizedScreenSpaceUV(input.positionCS); + lighting.shadowMask = half4(1, 1, 1, 1); + + half4 color = UniversalFragmentPBR(lighting, surface); + color.rgb = MixFog(color.rgb, lighting.fogCoord); + return color; + } + ENDHLSL + } + + // Solid meshes cast shadows; the pattern only modifies their albedo. + Pass + { + Name "ShadowCaster" + Tags { "LightMode"="ShadowCaster" } + ZWrite On + ZTest LEqual + ColorMask 0 + Cull Back + + HLSLPROGRAM + #pragma vertex ShadowVert + #pragma fragment ShadowFrag + #pragma multi_compile_instancing + #pragma multi_compile_vertex _ _CASTING_PUNCTUAL_LIGHT_SHADOW + #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Shadows.hlsl" + + float3 _LightDirection; + float3 _LightPosition; + + struct ShadowAttributes + { + float3 positionOS : POSITION; + float3 normalOS : NORMAL; + UNITY_VERTEX_INPUT_INSTANCE_ID + }; + struct ShadowVaryings { float4 positionCS : SV_POSITION; }; + + ShadowVaryings ShadowVert(ShadowAttributes input) + { + UNITY_SETUP_INSTANCE_ID(input); + ShadowVaryings output; + float3 positionWS = TransformObjectToWorld(input.positionOS); + float3 normalWS = TransformObjectToWorldNormal(input.normalOS); + #if defined(_CASTING_PUNCTUAL_LIGHT_SHADOW) + float3 lightDirection = normalize(_LightPosition - positionWS); + #else + float3 lightDirection = _LightDirection; + #endif + float4 positionCS = TransformWorldToHClip(ApplyShadowBias(positionWS, normalWS, lightDirection)); + #if UNITY_REVERSED_Z + positionCS.z = min(positionCS.z, UNITY_NEAR_CLIP_VALUE); + #else + positionCS.z = max(positionCS.z, UNITY_NEAR_CLIP_VALUE); + #endif + output.positionCS = positionCS; + return output; + } + half4 ShadowFrag(ShadowVaryings input) : SV_Target { return 0; } + ENDHLSL + } + + Pass + { + Name "DepthOnly" + Tags { "LightMode"="DepthOnly" } + ZWrite On + ColorMask 0 + Cull Back + HLSLPROGRAM + #pragma vertex DepthVert + #pragma fragment DepthFrag + #pragma multi_compile_instancing + struct DepthAttributes + { + float3 positionOS : POSITION; + UNITY_VERTEX_INPUT_INSTANCE_ID + }; + struct DepthVaryings { float4 positionCS : SV_POSITION; }; + DepthVaryings DepthVert(DepthAttributes input) + { + UNITY_SETUP_INSTANCE_ID(input); + DepthVaryings output; + output.positionCS = TransformObjectToHClip(input.positionOS); + return output; + } + half4 DepthFrag(DepthVaryings input) : SV_Target { return 0; } + ENDHLSL + } + } + FallBack Off +} diff --git a/Assets/_Content/Shaders/WorldGrid.shader.meta b/Assets/_Content/Shaders/WorldGrid.shader.meta new file mode 100644 index 0000000..65bd577 --- /dev/null +++ b/Assets/_Content/Shaders/WorldGrid.shader.meta @@ -0,0 +1,9 @@ +fileFormatVersion: 2 +guid: 0b6b65e03c0cbc6458620f24738fd6c6 +ShaderImporter: + externalObjects: {} + defaultTextures: [] + nonModifiableTextures: [] + userData: + assetBundleName: + assetBundleVariant: