mirror of
https://github.com/photonstorm/phaser
synced 2024-12-23 11:33:28 +00:00
23 lines
No EOL
445 B
TypeScript
23 lines
No EOL
445 B
TypeScript
/// <reference path="../../_definitions.ts" />
|
|
|
|
/**
|
|
* Phaser - Physics - Projection
|
|
*/
|
|
|
|
module Phaser.Physics.Projection {
|
|
|
|
export class AABBFull {
|
|
|
|
public static Collide(x: number, y: number, obj: Phaser.Physics.AABB, t: Phaser.Physics.TileMapCell) {
|
|
|
|
var l = Math.sqrt(x * x + y * y);
|
|
|
|
obj.reportCollisionVsWorld(x, y, x / l, y / l, t);
|
|
|
|
return Phaser.Physics.AABB.COL_AXIS;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} |