Problem with simple projection shader

First time messing around with shaders, i’ve got what im after however the projected texture is projected black, loosing all it’s colour.

Here’s the shader:

 Shader "Projector Shader" {
       Properties {
          
          _Tex ("Projector", 2D) = "" { TexGen ObjectLinear }
          
       }
    
       Subshader {
          
          Pass {
          
            Blend DstColor Zero 
              
             SetTexture [_Tex] {
             
                Matrix [_Projector]
                 
             }
          }
       }
    }

What’s causing this to happen?

you forgot about falloff the texture where projector should be hided.

  • add this to property:
_FallOff ("FallOff", 2D) = "white" {}
  • add this as second texture block:
SetTexture [_FallOff] {
  constantColor (1,1,1,0)
  combine previous lerp (texture) constant
  Matrix [_ProjectorClip]
}
  • and attach fallof texture (gradient alpha from 1(left) to 0(right))