Re-sort Area array during integration step
This commit is contained in:
parent
18a1403fcf
commit
600bae34bd
1 changed files with 1 additions and 0 deletions
|
@ -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--) {
|
||||
|
|
Loading…
Reference in a new issue