Re-sort Area array during integration step

This commit is contained in:
Fabio Alessandrelli 2015-03-24 04:05:56 +00:00
parent 18a1403fcf
commit 600bae34bd

View file

@ -378,6 +378,7 @@ void BodySW::integrate_forces(real_t p_step) {
bool replace = false;
gravity=Vector3(0,0,0);
if (ac) {
areas.sort();
const AreaCMP *aa = &areas[0];
density = aa[ac-1].area->get_density();
for(int i=ac-1;i>=0;i--) {