]> git.rm.cloudns.org Git - xonotic/netradiant.git/commitdiff
fix ignoring surface alpha for surfacemodels
authorRudolf Polzer <divverent@xonotic.org>
Sun, 5 Jun 2011 17:32:43 +0000 (19:32 +0200)
committerRudolf Polzer <divverent@xonotic.org>
Sun, 5 Jun 2011 17:32:43 +0000 (19:32 +0200)
tools/quake3/q3map2/surface.c

index ca4f5fa6ebd28138f4978040c365524d4d7d292a..ba400b082df8068acc0397e7310e03e58233fe8c 100644 (file)
@@ -3108,7 +3108,7 @@ int AddSurfaceModelsToTriangle_r( mapDrawSurface_t *ds, surfaceModel_t *model, b
                        /* roll the dice (model's odds scaled by vertex alpha) */
                        odds = model->odds * (tri[ 0 ]->color[ 0 ][ 3 ] + tri[ 0 ]->color[ 0 ][ 3 ] + tri[ 0 ]->color[ 0 ][ 3 ]) / 765.0f;
                        r = Random();
-                       if( r > model->odds )
+                       if( r > odds )
                                return 0;
                        
                        /* calculate scale */