212 lines
		
	
	
		
			10 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
		
		
			
		
	
	
			212 lines
		
	
	
		
			10 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
|  | // Made with Amplify Shader Editor | ||
|  | // Available at the Unity Asset Store - http://u3d.as/y3X  | ||
|  | Shader "11" | ||
|  | { | ||
|  | 	Properties | ||
|  | 	{ | ||
|  | 		[HDR]_Color("Color", Color) = (1,1,1,1) | ||
|  | 		_MainTex("MainTex", 2D) = "white" {} | ||
|  | 		_DissolveTex("DissolveTex", 2D) = "white" {} | ||
|  | 		_Dissolve("Dissolve", Range( 0 , 1)) = 0 | ||
|  | 		[Toggle]_HardSide("HardSide", Float) = 0 | ||
|  | 		[HideInInspector] _texcoord( "", 2D ) = "white" {} | ||
|  | 
 | ||
|  | 	} | ||
|  | 	 | ||
|  | 	SubShader | ||
|  | 	{ | ||
|  | 		 | ||
|  | 		 | ||
|  | 		Tags { "RenderType"="Transparent" "Queue"="Transparent" } | ||
|  | 	LOD 100 | ||
|  | 
 | ||
|  | 		CGINCLUDE | ||
|  | 		#pragma target 3.0 | ||
|  | 		ENDCG | ||
|  | 		Blend SrcAlpha OneMinusSrcAlpha | ||
|  | 		AlphaToMask Off | ||
|  | 		Cull Back | ||
|  | 		ColorMask RGBA | ||
|  | 		ZWrite Off | ||
|  | 		ZTest LEqual | ||
|  | 		Offset 0 , 0 | ||
|  | 		 | ||
|  | 		 | ||
|  | 		 | ||
|  | 		Pass | ||
|  | 		{ | ||
|  | 			Name "Unlit" | ||
|  | 			Tags { "LightMode"="ForwardBase" } | ||
|  | 			CGPROGRAM | ||
|  | 
 | ||
|  | 			 | ||
|  | 
 | ||
|  | 			#ifndef UNITY_SETUP_STEREO_EYE_INDEX_POST_VERTEX | ||
|  | 			//only defining to not throw compilation error over Unity 5.5 | ||
|  | 			#define UNITY_SETUP_STEREO_EYE_INDEX_POST_VERTEX(input) | ||
|  | 			#endif | ||
|  | 			#pragma vertex vert | ||
|  | 			#pragma fragment frag | ||
|  | 			#pragma multi_compile_instancing | ||
|  | 			#include "UnityCG.cginc" | ||
|  | 			#define ASE_NEEDS_FRAG_COLOR | ||
|  | 
 | ||
|  | 
 | ||
|  | 			struct appdata | ||
|  | 			{ | ||
|  | 				float4 vertex : POSITION; | ||
|  | 				float4 color : COLOR; | ||
|  | 				float4 ase_texcoord : TEXCOORD0; | ||
|  | 				UNITY_VERTEX_INPUT_INSTANCE_ID | ||
|  | 			}; | ||
|  | 			 | ||
|  | 			struct v2f | ||
|  | 			{ | ||
|  | 				float4 vertex : SV_POSITION; | ||
|  | 				#ifdef ASE_NEEDS_FRAG_WORLD_POSITION | ||
|  | 				float3 worldPos : TEXCOORD0; | ||
|  | 				#endif | ||
|  | 				float4 ase_texcoord1 : TEXCOORD1; | ||
|  | 				float4 ase_color : COLOR; | ||
|  | 				UNITY_VERTEX_INPUT_INSTANCE_ID | ||
|  | 				UNITY_VERTEX_OUTPUT_STEREO | ||
|  | 			}; | ||
|  | 
 | ||
|  | 			uniform sampler2D _MainTex; | ||
|  | 			uniform float4 _MainTex_ST; | ||
|  | 			uniform float4 _Color; | ||
|  | 			uniform float _HardSide; | ||
|  | 			uniform float _Dissolve; | ||
|  | 			uniform sampler2D _DissolveTex; | ||
|  | 			uniform float4 _DissolveTex_ST; | ||
|  | 
 | ||
|  | 			 | ||
|  | 			v2f vert ( appdata v ) | ||
|  | 			{ | ||
|  | 				v2f o; | ||
|  | 				UNITY_SETUP_INSTANCE_ID(v); | ||
|  | 				UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(o); | ||
|  | 				UNITY_TRANSFER_INSTANCE_ID(v, o); | ||
|  | 
 | ||
|  | 				o.ase_texcoord1.xy = v.ase_texcoord.xy; | ||
|  | 				o.ase_color = v.color; | ||
|  | 				 | ||
|  | 				//setting value to unused interpolator channels and avoid initialization warnings | ||
|  | 				o.ase_texcoord1.zw = 0; | ||
|  | 				float3 vertexValue = float3(0, 0, 0); | ||
|  | 				#if ASE_ABSOLUTE_VERTEX_POS | ||
|  | 				vertexValue = v.vertex.xyz; | ||
|  | 				#endif | ||
|  | 				vertexValue = vertexValue; | ||
|  | 				#if ASE_ABSOLUTE_VERTEX_POS | ||
|  | 				v.vertex.xyz = vertexValue; | ||
|  | 				#else | ||
|  | 				v.vertex.xyz += vertexValue; | ||
|  | 				#endif | ||
|  | 				o.vertex = UnityObjectToClipPos(v.vertex); | ||
|  | 
 | ||
|  | 				#ifdef ASE_NEEDS_FRAG_WORLD_POSITION | ||
|  | 				o.worldPos = mul(unity_ObjectToWorld, v.vertex).xyz; | ||
|  | 				#endif | ||
|  | 				return o; | ||
|  | 			} | ||
|  | 			 | ||
|  | 			fixed4 frag (v2f i ) : SV_Target | ||
|  | 			{ | ||
|  | 				UNITY_SETUP_INSTANCE_ID(i); | ||
|  | 				UNITY_SETUP_STEREO_EYE_INDEX_POST_VERTEX(i); | ||
|  | 				fixed4 finalColor; | ||
|  | 				#ifdef ASE_NEEDS_FRAG_WORLD_POSITION | ||
|  | 				float3 WorldPosition = i.worldPos; | ||
|  | 				#endif | ||
|  | 				float2 uv_MainTex = i.ase_texcoord1.xy * _MainTex_ST.xy + _MainTex_ST.zw; | ||
|  | 				float4 tex2DNode1 = tex2D( _MainTex, uv_MainTex ); | ||
|  | 				float temp_output_35_0 = (-1.0 + (_Dissolve - 0.0) * (1.0 - -1.0) / (1.0 - 0.0)); | ||
|  | 				float2 uv_DissolveTex = i.ase_texcoord1.xy * _DissolveTex_ST.xy + _DissolveTex_ST.zw; | ||
|  | 				float4 tex2DNode21 = tex2D( _DissolveTex, uv_DissolveTex ); | ||
|  | 				float smoothstepResult20 = smoothstep( ( temp_output_35_0 + 0.0 ) , ( ( temp_output_35_0 + 1.0 ) - 0.0 ) , tex2DNode21.r); | ||
|  | 				float smoothstepResult42 = smoothstep( ( _Dissolve + 0.0 ) , ( ( _Dissolve + 0.0 ) - 0.0 ) , tex2DNode21.r); | ||
|  | 				float4 appendResult19 = (float4(( tex2DNode1 * _Color * i.ase_color ).rgb , ( saturate( (( _HardSide )?( smoothstepResult42 ):( smoothstepResult20 )) ) * i.ase_color.a * ( tex2DNode1.a * _Color.a ) ))); | ||
|  | 				 | ||
|  | 				 | ||
|  | 				finalColor = appendResult19; | ||
|  | 				return finalColor; | ||
|  | 			} | ||
|  | 			ENDCG | ||
|  | 		} | ||
|  | 	} | ||
|  | 	CustomEditor "ASEMaterialInspector" | ||
|  | 	 | ||
|  | 	 | ||
|  | } | ||
|  | /*ASEBEGIN | ||
|  | Version=18935 | ||
|  | 37;222;2153;1126;2122.689;876.0624;2.251363;True;False | ||
|  | Node;AmplifyShaderEditor.RangedFloatNode;30;-2231.436,-31.39188;Inherit;False;Property;_Dissolve;Dissolve;3;0;Create;True;0;0;0;False;0;False;0;0;0;1;0;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.TFHCRemapNode;35;-1876.884,-246.0117;Inherit;False;5;0;FLOAT;0;False;1;FLOAT;0;False;2;FLOAT;1;False;3;FLOAT;-1;False;4;FLOAT;1;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.RangedFloatNode;46;-1894.74,249.543;Inherit;False;Constant;_Float3;Float 3;5;0;Create;True;0;0;0;False;0;False;0;1;0;0;0;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.RangedFloatNode;31;-1782.808,-30.26199;Inherit;False;Constant;_DissolveSmooth;DissolveSmooth;4;0;Create;True;0;0;0;False;0;False;1;1;0;0;0;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SimpleAddOpNode;34;-1528.045,-123.3491;Inherit;False;2;2;0;FLOAT;0;False;1;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SimpleAddOpNode;44;-1585.394,250.7352;Inherit;False;2;2;0;FLOAT;0;False;1;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SamplerNode;21;-2599.979,328.5791;Inherit;True;Property;_DissolveTex;DissolveTex;2;0;Create;True;0;0;0;False;0;False;-1;28c7aad1372ff114b90d330f8a2dd938;28c7aad1372ff114b90d330f8a2dd938;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.SimpleAddOpNode;48;-1423.331,109.7247;Inherit;False;2;2;0;FLOAT;0;False;1;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SimpleSubtractOpNode;43;-1422.331,250.7251;Inherit;False;2;0;FLOAT;0;False;1;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SimpleAddOpNode;32;-1365.982,-264.3595;Inherit;False;2;2;0;FLOAT;0;False;1;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SimpleSubtractOpNode;33;-1364.982,-123.3592;Inherit;False;2;0;FLOAT;0;False;1;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.WireNode;41;-2250.708,-262.6154;Inherit;False;1;0;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.WireNode;49;-2229.175,135.2531;Inherit;False;1;0;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SmoothstepOpNode;20;-1141.11,-315.9917;Inherit;True;3;0;FLOAT;0;False;1;FLOAT;0;False;2;FLOAT;1;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SmoothstepOpNode;42;-1140.663,58.09254;Inherit;True;3;0;FLOAT;0;False;1;FLOAT;0;False;2;FLOAT;1;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.ToggleSwitchNode;36;-689.5721,-218.2062;Inherit;False;Property;_HardSide;HardSide;4;0;Create;True;0;0;0;False;0;False;0;True;2;0;FLOAT;0;False;1;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SamplerNode;1;-473.7039,442.1267;Inherit;True;Property;_MainTex;MainTex;1;0;Create;True;0;0;0;False;0;False;-1;a78bffbeb81b48ae9ec71ad7969613e5;a78bffbeb81b48ae9ec71ad7969613e5;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.ColorNode;13;-373.5959,705.3488;Inherit;False;Property;_Color;Color;0;1;[HDR];Create;True;0;0;0;False;0;False;1,1,1,1;1.339623,1.181599,0,1;True;0;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4 | ||
|  | Node;AmplifyShaderEditor.VertexColorNode;10;-359.7986,193.3462;Inherit;False;0;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4 | ||
|  | Node;AmplifyShaderEditor.SaturateNode;9;-264.293,95.67428;Inherit;False;1;0;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SimpleMultiplyOpNode;50;-31.13734,336.0544;Inherit;False;2;2;0;FLOAT;0;False;1;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SimpleMultiplyOpNode;12;-15.80738,586.4908;Inherit;False;3;3;0;COLOR;0,0,0,0;False;1;COLOR;0,0,0,0;False;2;COLOR;0,0,0,0;False;1;COLOR;0 | ||
|  | Node;AmplifyShaderEditor.SimpleMultiplyOpNode;11;-73.39348,104.0796;Inherit;False;3;3;0;FLOAT;0;False;1;FLOAT;0;False;2;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.DynamicAppendNode;19;194.1035,296.5852;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.RangedFloatNode;7;-2001.354,889.4533;Inherit;False;Constant;_Float1;Float 1;2;0;Create;True;0;0;0;False;0;False;-2;0;0;0;0;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.RangedFloatNode;8;-2126.514,795.5339;Inherit;False;Constant;_Float2;Float 2;2;0;Create;True;0;0;0;False;0;False;0;0;0;1;0;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SimpleMultiplyOpNode;6;-1791.488,829.1774;Inherit;False;2;2;0;FLOAT;0;False;1;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.RangedFloatNode;5;-1807.468,705.0992;Inherit;False;Constant;_Float0;Float 0;2;0;Create;True;0;0;0;False;0;False;1;0;0;0;0;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.SimpleAddOpNode;3;-1576.733,681.9855;Inherit;True;3;3;0;FLOAT;0;False;1;FLOAT;0;False;2;FLOAT;0;False;1;FLOAT;0 | ||
|  | Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;0;422.8042,300.2393;Float;False;True;-1;2;ASEMaterialInspector;100;1;11;0770190933193b94aaa3065e307002fa;True;Unlit;0;0;Unlit;2;True;True;2;5;False;-1;10;False;-1;0;1;False;-1;0;False;-1;True;0;False;-1;0;False;-1;False;False;False;False;False;False;False;False;False;True;0;False;-1;False;True;0;False;-1;False;True;True;True;True;True;0;False;-1;False;False;False;False;False;False;False;True;False;255;False;-1;255;False;-1;255;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;True;True;2;False;-1;True;3;False;-1;True;True;0;False;-1;0;False;-1;True;2;RenderType=Transparent=RenderType;Queue=Transparent=Queue=0;True;2;False;0;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;True;1;LightMode=ForwardBase;False;False;0;;0;0;Standard;1;Vertex Position,InvertActionOnDeselection;1;0;0;1;True;False;;False;0 | ||
|  | WireConnection;35;0;30;0 | ||
|  | WireConnection;34;0;35;0 | ||
|  | WireConnection;34;1;31;0 | ||
|  | WireConnection;44;0;30;0 | ||
|  | WireConnection;44;1;46;0 | ||
|  | WireConnection;48;0;30;0 | ||
|  | WireConnection;43;0;44;0 | ||
|  | WireConnection;32;0;35;0 | ||
|  | WireConnection;33;0;34;0 | ||
|  | WireConnection;41;0;21;1 | ||
|  | WireConnection;49;0;21;1 | ||
|  | WireConnection;20;0;41;0 | ||
|  | WireConnection;20;1;32;0 | ||
|  | WireConnection;20;2;33;0 | ||
|  | WireConnection;42;0;49;0 | ||
|  | WireConnection;42;1;48;0 | ||
|  | WireConnection;42;2;43;0 | ||
|  | WireConnection;36;0;20;0 | ||
|  | WireConnection;36;1;42;0 | ||
|  | WireConnection;9;0;36;0 | ||
|  | WireConnection;50;0;1;4 | ||
|  | WireConnection;50;1;13;4 | ||
|  | WireConnection;12;0;1;0 | ||
|  | WireConnection;12;1;13;0 | ||
|  | WireConnection;12;2;10;0 | ||
|  | WireConnection;11;0;9;0 | ||
|  | WireConnection;11;1;10;4 | ||
|  | WireConnection;11;2;50;0 | ||
|  | WireConnection;19;0;12;0 | ||
|  | WireConnection;19;3;11;0 | ||
|  | WireConnection;6;0;8;0 | ||
|  | WireConnection;6;1;7;0 | ||
|  | WireConnection;3;0;21;1 | ||
|  | WireConnection;3;1;5;0 | ||
|  | WireConnection;3;2;6;0 | ||
|  | WireConnection;0;0;19;0 | ||
|  | ASEEND*/ | ||
|  | //CHKSM=154B49AE26B0346A72EFAC268C2B6094D06370C1 |