12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970 |
- Shader "CompassNavigatorPro/Sprite Overlay Unlit"
- {
- Properties
- {
- _Color ("Main Color", Color) = (1,1,1,1)
- _MainTex ("Base (RGB) Trans (A)", 2D) = "white" {}
- }
- SubShader
- {
- Tags
- {
- "Queue"="Transparent+100"
- "IgnoreProjector"="True"
- "RenderType"="Transparent"
- "DisableBatching"="LODFading"
- }
- Cull Off
- ZWrite Off
- ZTest Always
- Blend SrcAlpha OneMinusSrcAlpha
-
- Pass
- {
- CGPROGRAM
- #pragma vertex vert
- #pragma fragment frag
- #include "UnityCG.cginc"
- struct appdata
- {
- float4 vertex : POSITION;
- float2 uv : TEXCOORD0;
- half4 color : COLOR;
- };
- struct v2f
- {
- float4 vertex : SV_POSITION;
- float2 uv : TEXCOORD0;
- half4 color : COLOR;
- };
- sampler2D _MainTex;
- float4 _MainTex_ST;
- fixed4 _Color;
- v2f vert (appdata v)
- {
- v2f o;
- o.vertex = UnityObjectToClipPos(v.vertex);
- o.uv = TRANSFORM_TEX(v.uv, _MainTex);
- o.color = v.color;
- return o;
- }
-
- fixed4 frag (v2f i) : SV_Target
- {
- half4 col = tex2D(_MainTex, i.uv) * i.color;
- col *= _Color;
- return col;
- }
- ENDCG
- }
- }
- FallBack Off
- }
|