Kartoffel, this is a little code pice by "grafton" from aum 71:

Code:
BMAP* projectiontex = "Spotlight1.jpg";

VECTOR temp_vec;  

function mtlProjection_event()  
{
	float pTexAdj[16] = { 0.5, 0.0, 0.0, 0.0, 0.0,-0.5,	0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 }; 
	pTexAdj[12] = 0.5 + (0.5/(float)bmap_width(projectiontex));
	pTexAdj[13] = 0.5 + (0.5/(float)bmap_height(projectiontex));
	mat_set(Levelgeometrie_bump.matrix,matViewProj);	 
	mat_multiply(Levelgeometrie_bump.matrix,pTexAdj);  
}

MATERIAL* mtlProjView =               
{
effect = " technique DepthTechnique { pass p0 {	}}";  
	event = mtlProjection_event;  
	flags = ENABLE_VIEW;		        
}

VIEW* ProjectionView =             
{
	material = mtlProjView;
	flags = VISIBLE;	
}

function initstages_startup()
{
	ProjectionView.stage = camera; 
}



I was wondering if I could attach an projection texture (from the spotlight) to your shader with this. But it didn`t work.

Do you know why it didn`t work?