Browse Source

fixed getInteractive when pos not yet updated

Nicolas Cannasse 5 năm trước cách đây
mục cha
commit
b3352c24d9
1 tập tin đã thay đổi với 1 bổ sung0 xóa
  1. 1 0
      h2d/Scene.hx

+ 1 - 0
h2d/Scene.hx

@@ -355,6 +355,7 @@ class Scene extends Layers implements h3d.IDrawable implements hxd.SceneEvents.I
 	public function getInteractive( x : Float, y : Float ) : Interactive {
 		var pt = shapePoint;
 		for( i in interactive ) {
+			if( i.posChanged ) i.syncPos();
 
 			var dx = x - i.absX;
 			var dy = y - i.absY;