Small styling fixes.

This commit is contained in:
Richard Davey 2016-06-09 23:27:19 +01:00
parent 5415d9b603
commit 1daf897b23

View file

@ -129,8 +129,8 @@ Phaser.Physics.Arcade.TilemapCollision.prototype = {
return false;
}
var tilemapLayerOffsetX = (!tilemapLayer.fixedToCamera ? tilemapLayer.position.x : 0);
var tilemapLayerOffsetY = (!tilemapLayer.fixedToCamera ? tilemapLayer.position.y : 0);
var tilemapLayerOffsetX = (!tilemapLayer.fixedToCamera) ? tilemapLayer.position.x : 0;
var tilemapLayerOffsetY = (!tilemapLayer.fixedToCamera) ? tilemapLayer.position.y : 0;
// We re-check for collision in case body was separated in a previous step
if (!tile.intersects((body.position.x - tilemapLayerOffsetX), (body.position.y - tilemapLayerOffsetY), (body.right - tilemapLayerOffsetX), (body.bottom - tilemapLayerOffsetY)))
@ -242,7 +242,7 @@ Phaser.Physics.Arcade.TilemapCollision.prototype = {
tileCheckX: function (body, tile, tilemapLayer) {
var ox = 0;
var tilemapLayerOffsetX = (!tilemapLayer.fixedToCamera ? tilemapLayer.position.x : 0);
var tilemapLayerOffsetX = (!tilemapLayer.fixedToCamera) ? tilemapLayer.position.x : 0;
if (body.deltaX() < 0 && !body.blocked.left && tile.collideRight && body.checkCollision.left)
{
@ -300,7 +300,7 @@ Phaser.Physics.Arcade.TilemapCollision.prototype = {
tileCheckY: function (body, tile, tilemapLayer) {
var oy = 0;
var tilemapLayerOffsetY = (!tilemapLayer.fixedToCamera ? tilemapLayer.position.y : 0);
var tilemapLayerOffsetY = (!tilemapLayer.fixedToCamera) ? tilemapLayer.position.y : 0;
if (body.deltaY() < 0 && !body.blocked.up && tile.collideDown && body.checkCollision.up)
{