Making len more sensible

This commit is contained in:
Ben Cragg 2019-04-03 12:22:21 +01:00
parent 3592de858c
commit e6392a228d
1 changed files with 1 additions and 1 deletions

View File

@ -409,7 +409,7 @@ func (l Line) IntersectRect(r Rect) Vec {
// Len returns the length of the line segment.
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.