feat: poly-decomp

This commit is contained in:
cha0s 2019-04-12 23:51:14 -05:00
parent 901330011e
commit 90070840d6
2 changed files with 3 additions and 8 deletions

View File

@ -5,12 +5,6 @@ import {ShapeList, PolygonShape, RectangleShape} from '@avocado/physics';
import {AbstractBody} from '../abstract/body';
// Trick matter into not needing decomp for our convex polygons.
const g = typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : undefined;
if (g) {
g.decomp = true;
}
export class Body extends AbstractBody {
static collisionCategory(group) {

View File

@ -1,6 +1,6 @@
{
"name": "@avocado/physics",
"version": "1.0.2",
"version": "1.0.3",
"main": "index.js",
"author": "cha0s",
"license": "MIT",
@ -11,6 +11,7 @@
"@avocado/mixins": "1.x",
"@avocado/physics": "1.x",
"immutable": "4.0.0-rc.12",
"matter-js": "0.14.2"
"matter-js": "0.14.2",
"poly-decomp": "0.3.0"
}
}