]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
fix parameter number
authordivverent <divverent@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 1 Sep 2011 07:49:18 +0000 (07:49 +0000)
committerdivverent <divverent@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 1 Sep 2011 07:49:18 +0000 (07:49 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@11317 d7cf8633-e32d-0410-b094-e92efae38249

model_shared.c

index 1dbb18316e7c861373899dba01181ed5d7d181aa..40e7b278512194b6dd8d3957ee061e9499e29d2e 100644 (file)
@@ -2262,13 +2262,13 @@ void Mod_LoadQ3Shaders(void)
                                        if (numparameters >= 5)
                                        {
                                                if(!strcasecmp(parameter[3], "bias"))
-                                                       shader.offsetbias = atof(parameter[3]);
+                                                       shader.offsetbias = atof(parameter[4]);
                                                else if(!strcasecmp(parameter[3], "match"))
-                                                       shader.offsetbias = 1.0f - atof(parameter[3]);
+                                                       shader.offsetbias = 1.0f - atof(parameter[4]);
                                                else if(!strcasecmp(parameter[3], "match8"))
-                                                       shader.offsetbias = 1.0f - atof(parameter[3]) / 255.0f;
+                                                       shader.offsetbias = 1.0f - atof(parameter[4]) / 255.0f;
                                                else if(!strcasecmp(parameter[3], "match16"))
-                                                       shader.offsetbias = 1.0f - atof(parameter[3]) / 65535.0f;
+                                                       shader.offsetbias = 1.0f - atof(parameter[4]) / 65535.0f;
                                        }
                                }
                                else if (!strcasecmp(parameter[0], "deformvertexes") && numparameters >= 2)