From 5e2e3230ea491fac72073942b08cab21997358c9 Mon Sep 17 00:00:00 2001 From: wassname Date: Wed, 12 Dec 2018 07:02:42 +0800 Subject: [PATCH] un13 --- src/js/walker.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/js/walker.js b/src/js/walker.js index 957ecb2..e37728a 100644 --- a/src/js/walker.js +++ b/src/js/walker.js @@ -97,7 +97,7 @@ class Walker { this.fd = new b2.FixtureDef(); this.fd.density = this.density; this.fd.restitution = 0.1; // bounciness - this.fd.friction = 10000; // only on contact (grip) + this.fd.friction = 10000000; // only on contact (grip) this.fd.shape = new b2.PolygonShape(); this.fd.filter.groupIndex = -1; @@ -572,7 +572,7 @@ class Walker { simulationPreStep(motorSpeeds) { // act for (var k = 0; k < this.joints.length; k++) { - this.joints[k].SetMotorSpeed(motorSpeeds[k] * 30); // action can range from -3 to 3, radians per second + this.joints[k].SetMotorSpeed(motorSpeeds[k] * 20); // action can range from -3 to 3, radians per second } for (let i = 0; i < motorSpeeds.length - this.joints.length; i++) { this.grips[i] = motorSpeeds[i] > 0