移除Core,新增各接口用于sdk扩展

This commit is contained in:
yhh
2020-12-30 16:28:07 +08:00
parent f934890fac
commit d84ffcc2b7
28 changed files with 2008 additions and 653 deletions

View File

@@ -23,5 +23,13 @@ module es {
Polygon.recenterPolygonVerts(points);
this.shape = new Polygon(points);
}
public debugRender(batcher: IBatcher) {
let poly = this.shape as Polygon;
batcher.drawHollowRect(this.bounds, Debug.colliderBounds, 1);
batcher.drawPolygon(this.shape.position, poly.points, Debug.colliderEdge, true, 1);
batcher.drawPixel(this.entity.transform.position, Debug.colliderPosition, 4);
batcher.drawPixel(this.shape.position, Debug.colliderCenter, 2);
}
}
}