//SHADER SCRIPT FOR LLOYDMDM2 - ANCIENT ARCHIPELAGO


// q3map_sun <red> <green> <blue> <intensity> <degrees> <elevation>
// color will be normalized, so it doesn't matter what range you use
// intensity falls off with angle but not distance 100 is a fairly bright sun
// degree of 0 = from the east, 90 = north, etc.  altitude of 0 = sunrise/set, 90 = noon

textures/lloydmdm2/lloydmdm2_skybox
{
	qer_editorimage textures/lloydmdm2/lmsky2.tga
	surfaceparm noimpact
	surfaceparm nolightmap
	surfaceparm sky
	//q3map_sun .5 .37 .19  30 70
	//q3map_sun .5 .37 .19 70 170 40
	q3map_sun .5 .37 .19 155 170 33
	//q3map_surfacelight 80
	q3map_surfacelight 100

        skyparms env/lloydmdm2/lloydmdm2sky - -
	
}


//LIGHTS

textures/lloydmdm2/lloydmdm2lt_400
{
	qer_editorimage textures/lloydmdm2/lloydmdm2lt.tga
	q3map_lightimage textures/lloydmdm2/lloydmdm2lt.blend.tga
	q3map_surfacelight 400
	light 1
	surfaceparm nomarks
	{
		map $lightmap
		rgbGen identity
	}
	{
		map textures/lloydmdm2/lloydmdm2lt.tga
		blendFunc GL_DST_COLOR GL_ZERO
		rgbGen identity
	}
	{
		map textures/lloydmdm2/lloydmdm2lt.blend.tga
		blendfunc GL_ONE GL_ONE
	}
}


textures/lloydmdm2/lloydmdm2lt_1000
{
	qer_editorimage textures/lloydmdm2/lloydmdm2lt.tga
	q3map_lightimage textures/lloydmdm2/lloydmdm2lt.blend.tga
	q3map_surfacelight 1000
	light 1
	surfaceparm nomarks
	{
		map $lightmap
		rgbGen identity
	}
	{
		map textures/lloydmdm2/lloydmdm2lt.tga
		blendFunc GL_DST_COLOR GL_ZERO
		rgbGen identity
	}
	{
		map textures/lloydmdm2/lloydmdm2lt.blend.tga
		blendfunc GL_ONE GL_ONE
	}
}


textures/lloydmdm2/lloydmdm2lt_2000
{
	qer_editorimage textures/lloydmdm2/lloydmdm2lt.tga
	q3map_lightimage textures/lloydmdm2/lloydmdm2lt.blend.tga
	q3map_surfacelight 2000
	light 1
	surfaceparm nomarks
	{
		map $lightmap
		rgbGen identity
	}
	{
		map textures/lloydmdm2/lloydmdm2lt.tga
		blendFunc GL_DST_COLOR GL_ZERO
		rgbGen identity
	}
	{
		map textures/lloydmdm2/lloydmdm2lt.blend.tga
		blendfunc GL_ONE GL_ONE
	}
}

textures/lloydmdm2/lloydmdm2lt_10000
{
	qer_editorimage textures/lloydmdm2/lloydmdm2lt.tga
	q3map_lightimage textures/lloydmdm2/lloydmdm2lt.blend.tga
	q3map_surfacelight 10000
	light 1
	surfaceparm nomarks
	{
		map $lightmap
		rgbGen identity
	}
	{
		map textures/lloydmdm2/lloydmdm2lt.tga
		blendFunc GL_DST_COLOR GL_ZERO
		rgbGen identity
	}
	{
		map textures/lloydmdm2/lloydmdm2lt.blend.tga
		blendfunc GL_ONE GL_ONE
	}
}

textures/lloydmdm2/lloydmdm2lt_5000
{
	qer_editorimage textures/lloydmdm2/lloydmdm2lt.tga
	q3map_lightimage textures/lloydmdm2/lloydmdm2lt.blend.tga
	q3map_surfacelight 5000
	light 1
	surfaceparm nomarks
	{
		map $lightmap
		rgbGen identity
	}
	{
		map textures/lloydmdm2/lloydmdm2lt.tga
		blendFunc GL_DST_COLOR GL_ZERO
		rgbGen identity
	}
	{
		map textures/lloydmdm2/lloydmdm2lt.blend.tga
		blendfunc GL_ONE GL_ONE
	}
}

textures/lloydmdm2/lloydmdm2lt_20000
{
	qer_editorimage textures/lloydmdm2/lloydmdm2lt.tga
	q3map_lightimage textures/lloydmdm2/lloydmdm2lt.blend.tga
	q3map_surfacelight 20000
	light 1
	surfaceparm nomarks
	{
		map $lightmap
		rgbGen identity
	}
	{
		map textures/lloydmdm2/lloydmdm2lt.tga
		blendFunc GL_DST_COLOR GL_ZERO
		rgbGen identity
	}
	{
		map textures/lloydmdm2/lloydmdm2lt.blend.tga
		blendfunc GL_ONE GL_ONE
	}
}

//VINES

textures/lloydmdm2/vines
{	
    	qer_editorimage textures/lloydmdm2/vines.tga
	surfaceparm trans	
	surfaceparm alphashadow
   	surfaceparm nonsolid
	surfaceparm nomarks	
	cull none
        nopicmip
	{
		map textures/lloydmdm2/vines.tga
		blendFunc GL_ONE GL_ZERO
		alphaFunc GE128
		depthWrite
		rgbGen identity
	}
	{
		map $lightmap
		rgbGen identity
		blendFunc GL_DST_COLOR GL_ZERO
		depthFunc equal
	}
}

textures/lloydmdm2/vines2
{	
    	qer_editorimage textures/lloydmdm2/vines2.tga
	surfaceparm trans	
	surfaceparm alphashadow
   	surfaceparm nonsolid
	surfaceparm nomarks	
	cull none
        nopicmip
	{
		map textures/lloydmdm2/vines2.tga
		blendFunc GL_ONE GL_ZERO

	alphaFunc GE128
		depthWrite
		rgbGen identity
	}
	{
		map $lightmap
		rgbGen identity
		blendFunc GL_DST_COLOR GL_ZERO
		depthFunc equal
	}
}


//bounce pad

textures/lloydmdm2/lloydmdm2_bouncepad1
{

	//q3map_surfacelight 2000
	qer_editorimage textures/lloydmdm2/lloydmdm2_bouncepad1.tga
	surfaceparm nodamage
	q3map_lightimage textures/sfx/jumppadsmall.tga	
	q3map_surfacelight 400

	
	{
		map textures/lloydmdm2/lloydmdm2_bouncepad1.tga
		rgbGen identity
	}
	
	{
		map $lightmap
		rgbGen identity
		blendfunc gl_dst_color gl_zero
	}
	
	{
		map textures/sfx/bouncepad01b_layer1.tga
		blendfunc gl_one gl_one
		rgbGen wave sin .5 .5 0 1.5	
	}

	{
		clampmap textures/sfx/jumppadsmall.tga
		blendfunc gl_one gl_one
		tcMod stretch sin 1.2 .8 0 1.5
		rgbGen wave square .5 .5 .25 1.5
	}

	//	END
}

