From 41d007fe674bdf63c3ec2e4daae23f4744e9cb21 Mon Sep 17 00:00:00 2001 From: Richard Davey Date: Mon, 15 Jul 2019 16:30:08 +0100 Subject: [PATCH] `Origin.updateDisplayOrigin` no longer applies a Math.floor to the display origins, allowing you to have a 0.x origin for a Game Object that only has a width or height of 1. This fixes issues with things like 1x1 rectangles displaying incorrectly during rendering. --- src/gameobjects/components/Origin.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gameobjects/components/Origin.js b/src/gameobjects/components/Origin.js index 7962a7be8..43b03092a 100644 --- a/src/gameobjects/components/Origin.js +++ b/src/gameobjects/components/Origin.js @@ -186,8 +186,8 @@ var Origin = { */ updateDisplayOrigin: function () { - this._displayOriginX = Math.round(this.originX * this.width); - this._displayOriginY = Math.round(this.originY * this.height); + this._displayOriginX = this.originX * this.width; + this._displayOriginY = this.originY * this.height; return this; }