Making len more sensible
This commit is contained in:
parent
3592de858c
commit
e6392a228d
|
@ -409,7 +409,7 @@ func (l Line) IntersectRect(r Rect) Vec {
|
||||||
|
|
||||||
// Len returns the length of the line segment.
|
// Len returns the length of the line segment.
|
||||||
func (l Line) Len() float64 {
|
func (l Line) Len() float64 {
|
||||||
return l.A.Sub(l.B).Len()
|
return l.A.To(l.B).Len()
|
||||||
}
|
}
|
||||||
|
|
||||||
// Moved will return a line moved by the delta `Vec` provided.
|
// Moved will return a line moved by the delta `Vec` provided.
|
||||||
|
|
Loading…
Reference in New Issue