add rope support

This commit is contained in:
Asraelite 2016-03-26 18:43:34 +00:00
parent ccc77490ea
commit ff0ac094cf
7 changed files with 91 additions and 19 deletions

View file

@ -3,8 +3,19 @@
const Copula = require('./copula.js');
class Rope extends Copula {
constructor(p1, p2) {
super();
constructor(b1, b2) {
super(b1, b2);
this.type = 'rope';
this._length = 0;
}
get length() {
return this._length;
}
set length(len) {
this.length = len;
this.b2joint.SetLength(len);
}
}