fix line instantiation
This commit is contained in:
+1
-1
@@ -84,7 +84,7 @@ export default class SATX {
|
||||
}
|
||||
|
||||
static line(from, to) {
|
||||
return new SAT.Polygon(new SAT.Vector(...from.toArray()), [new SAT.Vector(), new SAT.Vector(...to.toArray())])
|
||||
return new SAT.Polygon(new SAT.Vector(...from.toArray()), [new SAT.Vector(), new SAT.Vector(...to.clone().sub(from).toArray())])
|
||||
}
|
||||
|
||||
static polygonToThreeVector2(polygon) {
|
||||
|
||||
Reference in New Issue
Block a user