small optimization

This commit is contained in:
cxgeorge 2001-06-10 03:52:44 +00:00
parent b3131cd0d6
commit b050bd8459
1 changed files with 15 additions and 6 deletions

View File

@ -172,19 +172,28 @@ handle_entries() {
}
}
if (_horizontal) {
net_shove[2] = 0.0;
LMatrix4f mat;
def.get_mat(mat);
// def.set_mat(LMatrix4f::translate_mat(net_shove) * mat);
mat(3,0) += net_shove[0];
mat(3,1) += net_shove[1];
if (!_horizontal) {
mat(3,2) += net_shove[2];
}
def.set_mat(mat);
if (collide_cat.is_debug()) {
if (_horizontal)
net_shove[2] = 0.0;
collide_cat.debug()
<< "Net shove on " << *from_node << " is: "
<< net_shove << "\n";
}
LMatrix4f mat;
def.get_mat(mat);
def.set_mat(LMatrix4f::translate_mat(net_shove) * mat);
}
}
}