summary refs log tree commit diff stats
path: root/src/systems
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2018-05-04 11:34:57 -0400
committerKelly Rauchenberger <fefferburbia@gmail.com>2018-05-09 17:59:13 -0400
commit296a1c3aa0bdb27e7ee9b53f0382938d0fe6d1a0 (patch)
treeac2cad8e41c59d7301685f2438f99a646c8b7392 /src/systems
parent5b3d87d24b4c2c750d34d1e970254358cba087a4 (diff)
downloadtherapy-296a1c3aa0bdb27e7ee9b53f0382938d0fe6d1a0.tar.gz
therapy-296a1c3aa0bdb27e7ee9b53f0382938d0fe6d1a0.tar.bz2
therapy-296a1c3aa0bdb27e7ee9b53f0382938d0fe6d1a0.zip
Fixed bug with upward tilemap collision
A body moving upward would have its transform incorrectly measured against the map collision boundaries.
Diffstat (limited to 'src/systems')
-rw-r--r--src/systems/pondering.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/systems/pondering.cpp b/src/systems/pondering.cpp index f5d3df2..ed14772 100644 --- a/src/systems/pondering.cpp +++ b/src/systems/pondering.cpp
@@ -440,7 +440,7 @@ void PonderingSystem::tickBody(
440 it++) 440 it++)
441 { 441 {
442 // Check that the boundary is in range for the other axis. 442 // Check that the boundary is in range for the other axis.
443 if ((result.newX + transformable.h > it->second.lower) && 443 if ((result.newX + transformable.w > it->second.lower) &&
444 (result.newX < it->second.upper)) 444 (result.newX < it->second.upper))
445 { 445 {
446 // We have a collision! 446 // We have a collision!