From e66888535b55cc79de766b5296d426519e847009 Mon Sep 17 00:00:00 2001
From: havoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Date: Sun, 24 Jun 2007 07:15:53 +0000
Subject: [PATCH] slight simplification/optimization of an if statement (no
 change in behavior)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@7447 d7cf8633-e32d-0410-b094-e92efae38249
---
 gl_rmain.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gl_rmain.c b/gl_rmain.c
index 2883c1be..c0bc61c3 100644
--- a/gl_rmain.c
+++ b/gl_rmain.c
@@ -5014,7 +5014,7 @@ static void R_DrawTextureSurfaceList(int texturenumsurfaces, msurface_t **textur
 	else if (rsurface.texture->currentnumlayers)
 	{
 		// write depth for anything we skipped on the depth-only pass earlier
-		if (!writedepth && (rsurface.texture->currentmaterialflags & (MATERIALFLAG_BLENDED | MATERIALFLAG_ALPHATEST)))
+		if (rsurface.texture->currentmaterialflags & MATERIALFLAG_ALPHATEST)
 			writedepth = true;
 		GL_DepthRange(0, (rsurface.texture->currentmaterialflags & MATERIALFLAG_SHORTDEPTHRANGE) ? 0.0625 : 1);
 		GL_PolygonOffset(rsurface.texture->currentpolygonfactor, rsurface.texture->currentpolygonoffset);
-- 
2.39.5