Fixed HitTest issue with scrollFactor

This commit is contained in:
Richard Davey 2017-07-29 01:05:46 +01:00
parent db113b58da
commit 08ce1c37da
2 changed files with 4 additions and 4 deletions

View file

@ -1,4 +1,4 @@
var CHECKSUM = {
build: '41aa6700-73b9-11e7-89dd-e354e5abd620'
build: '4bd62f10-73f1-11e7-b8d9-bbb34810695d'
};
module.exports = CHECKSUM;

View file

@ -32,10 +32,10 @@ var HitTest = function (tempMatrix, x, y, gameObjects, camera, output)
var point = GetTransformedPoint(
tempMatrix,
gameObject,
(screenPoint.x + camera.scrollX) * gameObject.scrollFactorX,
(screenPoint.y + camera.scrollY) * gameObject.scrollFactorY
screenPoint.x + camera.scrollX * gameObject.scrollFactorX,
screenPoint.y + camera.scrollY * gameObject.scrollFactorY
);
if (PointWithinHitArea(gameObject, point.x, point.y, camera))
{
output.push(gameObject);