reduce update packets sent

This commit is contained in:
Asraelite 2016-03-30 12:50:59 +01:00
parent d6daed2e9b
commit ef2d067b38
15 changed files with 67 additions and 14 deletions

View file

@ -18,6 +18,9 @@ const b2Vec2 = Box2D.b2Vec2;
class Physics {
constructor() {
Box2D.b2_linearSleepTolerance = 0.002;
Box2D.b2_angularSleepTolerance = 0.002;
this.world = new Box2D.b2World(new b2Vec2(0, 0), false);
this.toRemove = [];
this.toWeld = [];