X-Git-Url: https://git.jsancho.org/?a=blobdiff_plain;ds=sidebyside;f=Source%2FObjects%2FObject.cpp;h=3a49c9c43e16d821a70dda19aa4e13d3434fa1a3;hb=a389d6c2d7aef7995826f3c20ffe5e5a998d858d;hp=12c96e5fda4fe8e8e09f89bf0c5acd3774e29251;hpb=7d2f9d40d94d14a61ecdaaa2c41f964029815bc2;p=lugaru.git diff --git a/Source/Objects/Object.cpp b/Source/Objects/Object.cpp index 12c96e5..3a49c9c 100644 --- a/Source/Objects/Object.cpp +++ b/Source/Objects/Object.cpp @@ -744,28 +744,6 @@ void Object::AddObjectsToTerrain() } } -bool Object::Checkcollide(XYZ startpoint, XYZ endpoint, int which) -{ - static XYZ colpoint, colviewer, coltarget; - static int i; - - startpoint.y += .1; - endpoint.y += .1; - startpoint.y -= .1; - endpoint.y -= .1; - - for (i = 0; i < objects.size(); i++) { - if (objects[i]->type != treeleavestype && objects[i]->type != treetrunktype && objects[i]->type != bushtype && objects[i]->type != firetype && i != which) { - colviewer = startpoint; - coltarget = endpoint; - if (objects[i]->model.LineCheck(&colviewer, &coltarget, &colpoint, &objects[i]->position, &objects[i]->yaw) != -1) - return 1; - } - } - - return 0; -} - void Object::SphereCheckPossible(XYZ *p1, float radius) { int whichpatchx = p1->x / (terrain.size / subdivision * terrain.scale);