TeamMeanMachine / meanlib

A Kotlin FRC library
The Unlicense
16 stars 3 forks source link

Allow access to Path2DCurve tailPoint #9

Closed andrewda closed 5 years ago

andrewda commented 5 years ago

Makes it easier to update paths on the fly by doing something like:


path.addPointAngleAndMagnitude(0.0, 0.0, 0.0, 1.0)
path.addPointAngleAndMagnitude(1.0, 1.0, 0.0, 1.0)

// path.xyCurve is (0.0, 0.0, 0.0) to (1.0, 1.0, 0.0)

path.removePoint(path.xyCurve.tailPoint)

path.addPointAngleAndMagnitude(2.0, 2.0, 15.0, 1.0)

// path.xyCurve is (0.0, 0.0, 0.0) to (2.0, 2.0, 15.0)