Improve movement
This commit is contained in:
parent
e01400058d
commit
9e35538b79
13 changed files with 164 additions and 125 deletions
|
|
@ -98,15 +98,11 @@ export class BlobShape extends Drawable {
|
|||
}
|
||||
|
||||
public minDistance(target: vec2): number {
|
||||
// todo
|
||||
return 0;
|
||||
/*return (
|
||||
Math.min(
|
||||
this.head.distance(target),
|
||||
this.leftFoot.distance(target),
|
||||
this.rightFoot.distance(target)
|
||||
) / 2
|
||||
);*/
|
||||
return Math.min(
|
||||
this.head.distance(target),
|
||||
this.leftFoot.distance(target),
|
||||
this.rightFoot.distance(target),
|
||||
);
|
||||
}
|
||||
|
||||
protected getObjectToSerialize(transform2d: mat2d, transform1d: number): any {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue