// Made with Amplify Shader Editor // Available at the Unity Asset Store - http://u3d.as/y3X Shader "QFX/ProjectilesFX/Particles" { Properties { _TintColor ("Tint Color", Color) = (0.5,0.5,0.5,0.5) _MainTex ("Particle Texture", 2D) = "white" {} _InvFade ("Soft Particles Factor", Range(0.01,3.0)) = 1.0 [Enum(UnityEngine.Rendering.BlendMode)]_SrcBlend("SrcBlend", Int) = 5 [Enum(UnityEngine.Rendering.BlendMode)]_DstBlend("DstBlend", Int) = 10 _EmissiveMultiply("Emissive Multiply", Float) = 1 _OpacityMultiply("Opacity Multiply", Float) = 1 [HideInInspector] _texcoord( "", 2D ) = "white" {} } Category { SubShader { LOD 0 Tags { "Queue"="Transparent" "IgnoreProjector"="True" "RenderType"="Transparent" "PreviewType"="Plane" } Blend [_SrcBlend] [_DstBlend] ColorMask RGB Cull Off Lighting Off ZWrite Off ZTest LEqual Pass { CGPROGRAM #ifndef UNITY_SETUP_STEREO_EYE_INDEX_POST_VERTEX #define UNITY_SETUP_STEREO_EYE_INDEX_POST_VERTEX(input) #endif #pragma vertex vert #pragma fragment frag #pragma target 2.0 #pragma multi_compile_instancing #pragma multi_compile_particles #pragma multi_compile_fog #define ASE_NEEDS_FRAG_COLOR #include "UnityCG.cginc" struct appdata_t { float4 vertex : POSITION; fixed4 color : COLOR; float4 texcoord : TEXCOORD0; UNITY_VERTEX_INPUT_INSTANCE_ID }; struct v2f { float4 vertex : SV_POSITION; fixed4 color : COLOR; float4 texcoord : TEXCOORD0; UNITY_FOG_COORDS(1) #ifdef SOFTPARTICLES_ON float4 projPos : TEXCOORD2; #endif UNITY_VERTEX_INPUT_INSTANCE_ID UNITY_VERTEX_OUTPUT_STEREO }; #if UNITY_VERSION >= 560 UNITY_DECLARE_DEPTH_TEXTURE( _CameraDepthTexture ); #else uniform sampler2D_float _CameraDepthTexture; #endif //Don't delete this comment // uniform sampler2D_float _CameraDepthTexture; uniform sampler2D _MainTex; uniform fixed4 _TintColor; uniform float4 _MainTex_ST; uniform float _InvFade; uniform int _DstBlend; uniform int _SrcBlend; uniform float _EmissiveMultiply; uniform float _OpacityMultiply; v2f vert ( appdata_t v ) { v2f o; UNITY_SETUP_INSTANCE_ID(v); UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(o); UNITY_TRANSFER_INSTANCE_ID(v, o); v.vertex.xyz += float3( 0, 0, 0 ) ; o.vertex = UnityObjectToClipPos(v.vertex); #ifdef SOFTPARTICLES_ON o.projPos = ComputeScreenPos (o.vertex); COMPUTE_EYEDEPTH(o.projPos.z); #endif o.color = v.color; o.texcoord = v.texcoord; UNITY_TRANSFER_FOG(o,o.vertex); return o; } fixed4 frag ( v2f i ) : SV_Target { UNITY_SETUP_INSTANCE_ID( i ); UNITY_SETUP_STEREO_EYE_INDEX_POST_VERTEX( i ); #ifdef SOFTPARTICLES_ON float sceneZ = LinearEyeDepth (SAMPLE_DEPTH_TEXTURE_PROJ(_CameraDepthTexture, UNITY_PROJ_COORD(i.projPos))); float partZ = i.projPos.z; float fade = saturate (_InvFade * (sceneZ-partZ)); i.color.a *= fade; #endif float2 uv_MainTex = i.texcoord.xy * _MainTex_ST.xy + _MainTex_ST.zw; float4 temp_output_6_0 = ( _TintColor * tex2D( _MainTex, uv_MainTex ) * i.color * unity_ColorSpaceDouble ); float4 appendResult11 = (float4(( _EmissiveMultiply * (temp_output_6_0).rgb ) , saturate( ( (temp_output_6_0).a * _OpacityMultiply ) ))); fixed4 col = appendResult11; UNITY_APPLY_FOG(i.fogCoord, col); return col; } ENDCG } } } CustomEditor "ASEMaterialInspector" } /*ASEBEGIN Version=18500 526.4;252.8;952;548;2340.43;876.0764;2.867286;True;False Node;AmplifyShaderEditor.TemplateShaderPropertyNode;2;-1172.291,-120.6237;Inherit;False;0;0;_MainTex;Shader;0;5;SAMPLER2D;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4 Node;AmplifyShaderEditor.ColorSpaceDouble;26;-368.2641,132.006;Inherit;False;0;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4 Node;AmplifyShaderEditor.TemplateShaderPropertyNode;4;-577.5504,-419.3011;Inherit;False;0;0;_TintColor;Shader;0;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4 Node;AmplifyShaderEditor.SamplerNode;1;-988.0105,-142.42;Inherit;True;Property;_TextureSample0;Texture Sample 0;0;0;Create;True;0;0;False;0;False;-1;None;None;True;0;False;white;Auto;False;Object;-1;Auto;Texture2D;8;0;SAMPLER2D;;False;1;FLOAT2;0,0;False;2;FLOAT;0;False;3;FLOAT2;0,0;False;4;FLOAT2;0,0;False;5;FLOAT;1;False;6;FLOAT;0;False;7;SAMPLERSTATE;;False;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4 Node;AmplifyShaderEditor.VertexColorNode;5;-642.0381,170.3069;Inherit;False;0;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4 Node;AmplifyShaderEditor.SimpleMultiplyOpNode;6;-238.5061,-115.3267;Inherit;False;4;4;0;COLOR;0,0,0,0;False;1;COLOR;0,0,0,0;False;2;COLOR;0,0,0,0;False;3;COLOR;0,0,0,0;False;1;COLOR;0 Node;AmplifyShaderEditor.ComponentMaskNode;9;-10.45271,-46.19868;Inherit;False;False;False;False;True;1;0;COLOR;0,0,0,0;False;1;FLOAT;0 Node;AmplifyShaderEditor.RangedFloatNode;16;-51.60943,95.66205;Inherit;False;Property;_OpacityMultiply;Opacity Multiply;3;0;Create;True;0;0;False;0;False;1;1;0;0;0;1;FLOAT;0 Node;AmplifyShaderEditor.SimpleMultiplyOpNode;17;179.3525,16.21677;Inherit;False;2;2;0;FLOAT;0;False;1;FLOAT;0;False;1;FLOAT;0 Node;AmplifyShaderEditor.ComponentMaskNode;8;54.08418,-133.834;Inherit;False;True;True;True;False;1;0;COLOR;0,0,0,0;False;1;FLOAT3;0 Node;AmplifyShaderEditor.RangedFloatNode;12;91.3055,-292.1298;Inherit;False;Property;_EmissiveMultiply;Emissive Multiply;2;0;Create;True;0;0;False;0;False;1;1;0;0;0;1;FLOAT;0 Node;AmplifyShaderEditor.SaturateNode;10;306.7094,-32.51043;Inherit;False;1;0;FLOAT;0;False;1;FLOAT;0 Node;AmplifyShaderEditor.CommentaryNode;21;-888.6321,-449.778;Inherit;False;222.385;257.1656;Custom Blending;2;19;20;;1,0,0,1;0;0 Node;AmplifyShaderEditor.SimpleMultiplyOpNode;7;477.6564,-298.0962;Inherit;False;2;2;0;FLOAT;0;False;1;FLOAT3;0,0,0;False;1;FLOAT3;0 Node;AmplifyShaderEditor.IntNode;20;-838.1912,-397.6119;Inherit;False;Property;_SrcBlend;SrcBlend;0;1;[Enum];Create;True;0;1;UnityEngine.Rendering.BlendMode;True;0;False;5;5;0;1;INT;0 Node;AmplifyShaderEditor.DynamicAppendNode;11;734.5671,-122.9821;Inherit;False;FLOAT4;4;0;FLOAT3;0,0,0;False;1;FLOAT;0;False;2;FLOAT;0;False;3;FLOAT;0;False;1;FLOAT4;0 Node;AmplifyShaderEditor.IntNode;19;-840.7595,-311.9804;Inherit;False;Property;_DstBlend;DstBlend;1;1;[Enum];Create;True;0;1;UnityEngine.Rendering.BlendMode;True;0;False;10;10;0;1;INT;0 Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;32;900.8318,-124.5001;Float;False;True;-1;2;ASEMaterialInspector;0;7;QFX/ProjectilesFX/Particles;0b6a9f8b4f707c74ca64c0be8e590de0;True;SubShader 0 Pass 0;0;0;SubShader 0 Pass 0;2;True;2;5;True;20;10;True;19;0;1;False;-1;0;False;-1;False;False;False;False;False;False;False;False;True;2;False;-1;True;True;True;True;False;0;False;-1;False;False;False;False;True;2;False;-1;True;3;False;-1;False;True;4;Queue=Transparent=Queue=0;IgnoreProjector=True;RenderType=Transparent=RenderType;PreviewType=Plane;False;0;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;True;0;0;;0;0;Standard;0;0;1;True;False;;False;0 WireConnection;1;0;2;0 WireConnection;6;0;4;0 WireConnection;6;1;1;0 WireConnection;6;2;5;0 WireConnection;6;3;26;0 WireConnection;9;0;6;0 WireConnection;17;0;9;0 WireConnection;17;1;16;0 WireConnection;8;0;6;0 WireConnection;10;0;17;0 WireConnection;7;0;12;0 WireConnection;7;1;8;0 WireConnection;11;0;7;0 WireConnection;11;3;10;0 WireConnection;32;0;11;0 ASEEND*/ //CHKSM=FE6E0DBCF91887F99CB020075F2A404DEC0996F1