]> git.jsancho.org Git - lugaru.git/blobdiff - Source/Graphic/Models.cpp
Cleaned Terrain Decal handling
[lugaru.git] / Source / Graphic / Models.cpp
index f58962c2f4ab5e3c5f57aea22b7f49f1f19abe26..ee5add1a88dde9aa6cbb3dd281c372ba300d31c7 100644 (file)
@@ -28,7 +28,7 @@ extern float viewdistance;
 extern XYZ viewer;
 extern float fadestart;
 extern float texdetail;
-extern bool decals;
+extern bool decalstoggle;
 
 int Model::LineCheck(XYZ *p1, XYZ *p2, XYZ *p, XYZ *move, float *rotate)
 {
@@ -103,7 +103,7 @@ int Model::LineCheckPossible(XYZ *p1, XYZ *p2, XYZ *p, XYZ *move, float *rotate)
     return firstintersecting;
 }
 
-int Model::LineCheckSlidePossible(XYZ *p1, XYZ *p2, XYZ *p, XYZ *move, float *rotate)
+int Model::LineCheckSlidePossible(XYZ *p1, XYZ *p2, XYZ *move, float *rotate)
 {
     static int j;
     static float distance;
@@ -463,7 +463,7 @@ bool Model::loadnotex(const std::string& filename)
 }
 
 
-bool Model::load(const std::string& filename, bool texture)
+bool Model::load(const std::string& filename)
 {
     FILE *tfile;
     long i;
@@ -536,7 +536,7 @@ bool Model::load(const std::string& filename, bool texture)
     return true;
 }
 
-bool Model::loaddecal(const std::string& filename, bool texture )
+bool Model::loaddecal(const std::string& filename)
 {
     FILE *tfile;
     long i, j;
@@ -962,7 +962,7 @@ void Model::drawdifftex(Texture texture)
 
 void Model::drawdecals(Texture shadowtexture, Texture bloodtexture, Texture bloodtexture2, Texture breaktexture)
 {
-    if (decals) {
+    if (decalstoggle) {
         if (type != decalstype)
             return;
         static int i;
@@ -1062,7 +1062,7 @@ void Model::drawdecals(Texture shadowtexture, Texture bloodtexture, Texture bloo
 
 void Model::DeleteDecal(int which)
 {
-    if (decals) {
+    if (decalstoggle) {
         if (type != decalstype)
             return;
         decaltype[which] = decaltype[numdecals - 1];
@@ -1081,7 +1081,7 @@ void Model::DeleteDecal(int which)
 
 void Model::MakeDecal(int atype, XYZ *where, float *size, float *opacity, float *rotation)
 {
-    if (decals) {
+    if (decalstoggle) {
         if (type != decalstype)
             return;
 
@@ -1159,7 +1159,7 @@ void Model::MakeDecal(int atype, XYZ *where, float *size, float *opacity, float
 
 void Model::MakeDecal(int atype, XYZ where, float size, float opacity, float rotation)
 {
-    if (decals) {
+    if (decalstoggle) {
         if (type != decalstype)
             return;