Open
Description
The callback assigned to Flxg.collide gives back a FlxOject with coordinates x = 0 and y = 0 all the time
I used the following code:
override public function update():void
{
FlxG.collide(_bullets,collisionMap,bulletMap);
super.update();
}
private function bulletMap(b:FlxObject,cmp:FlxObject):void
{
FlxG.log(String(cmp.x) + "," + String(cmp.y) + "; " + String(b.x) + "," + String(b.y));
}
I get the following output for multiple bullets shot:
51.199999999999704,440; 0,0
410.07500000000067,312; 0,0
461.2250000000009,312; 0,0
Note: the tile resolution used is 8 x 8