X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fmap%2FEntity.cpp;h=6b6adaca3561e2d2f8aeeaf15d1eb369ce7b542d;hb=6ad33ca7db4f2d13311e2f8a9e77e57f907a576d;hp=93530f142735021f063f8dab333f66d694680f51;hpb=3701b454bd2c868a886ae5287d8209b714649344;p=l2e.git diff --git a/src/map/Entity.cpp b/src/map/Entity.cpp index 93530f1..6b6adac 100644 --- a/src/map/Entity.cpp +++ b/src/map/Entity.cpp @@ -123,7 +123,7 @@ void Entity::UpdateVelocity() { bool Entity::TileLock(const math::Vector &tileSize) const { // TODO: change position to point to the top-left corner of a tile Vector tilePosition(ToInt(position)); - return (tilePosition.X() % tileSize.X() == 0) && (tilePosition.Y() % tileSize.Y() == 0); + return tilePosition % tileSize == Vector(); }