summaryrefslogtreecommitdiff
path: root/2d/_collisions
diff options
context:
space:
mode:
Diffstat (limited to '2d/_collisions')
-rwxr-xr-x2d/_collisions/polygon_polygon/dist/output.wasmbin58079 -> 58262 bytes
-rw-r--r--2d/_collisions/polygon_polygon/main.cpp2
2 files changed, 1 insertions, 1 deletions
diff --git a/2d/_collisions/polygon_polygon/dist/output.wasm b/2d/_collisions/polygon_polygon/dist/output.wasm
index a047d19..055fbb7 100755
--- a/2d/_collisions/polygon_polygon/dist/output.wasm
+++ b/2d/_collisions/polygon_polygon/dist/output.wasm
Binary files differ
diff --git a/2d/_collisions/polygon_polygon/main.cpp b/2d/_collisions/polygon_polygon/main.cpp
index 620edaa..9cb3eb2 100644
--- a/2d/_collisions/polygon_polygon/main.cpp
+++ b/2d/_collisions/polygon_polygon/main.cpp
@@ -72,7 +72,7 @@ struct Rigidbody {
float32 impulseDtSeconds = nextTimeAppliedSeconds - i.timeAppliedSeconds;
Vector2 forceToApply = i.force * (impulseDtSeconds / i.timeOfApplicationSeconds);
- force += forceToApply * impulseDtSeconds;
+ force += forceToApply;
i.timeAppliedSeconds = nextTimeAppliedSeconds;