models with alpha channel and fog
Posted: Fri Mar 08, 2013 12:36 pm
hello forum, i am making a map in darkplaces with some models. I add fog but i have a problem:
the fog affects the models and dissapear when i move the mouse :? If i do not add shader scripts this bug doesnt appear but the models looks with transparency.
I need the correct shader to do not have bugs, i use this shader and didnt work correctly
I also test this taken from the multiplant pack from quake 3 arena
this doesn´t work correctly i have exactly the same bugs
Any help?
the fog affects the models and dissapear when i move the mouse :? If i do not add shader scripts this bug doesnt appear but the models looks with transparency.
I need the correct shader to do not have bugs, i use this shader and didnt work correctly
Code: Select all
{
map models/vegetales/pine1
alphaFunc GT0
rgbGen vertex
}
Code: Select all
surfaceparm alphashadow
cull none
nopicmip
{
map models/mapobjects/multiplant/pine1
blendFunc GL_ONE GL_ZERO
alphaFunc GE128
depthWrite
rgbGen identityLighting
}
{
map $lightmap
rgbGen identity
blendFunc GL_DST_COLOR GL_ZERO
depthFunc equal
}
Any help?