summaryrefslogtreecommitdiff
path: root/servers/physics_2d/body_2d_sw.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'servers/physics_2d/body_2d_sw.cpp')
-rw-r--r--servers/physics_2d/body_2d_sw.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/servers/physics_2d/body_2d_sw.cpp b/servers/physics_2d/body_2d_sw.cpp
index 6f244deb1e..7aa2f9b7de 100644
--- a/servers/physics_2d/body_2d_sw.cpp
+++ b/servers/physics_2d/body_2d_sw.cpp
@@ -532,13 +532,13 @@ void Body2DSW::integrate_velocities(real_t p_step) {
}
void Body2DSW::wakeup_neighbours() {
- for (List<Pair<Constraint2DSW *, int>>::Element *E = constraint_list.front(); E; E = E->next()) {
- const Constraint2DSW *c = E->get().first;
+ for (const Pair<Constraint2DSW *, int> &E : constraint_list) {
+ const Constraint2DSW *c = E.first;
Body2DSW **n = c->get_body_ptr();
int bc = c->get_body_count();
for (int i = 0; i < bc; i++) {
- if (i == E->get().second) {
+ if (i == E.second) {
continue;
}
Body2DSW *b = n[i];