Skip to content

Commit

Permalink
Velocity fix for paths (#54)
Browse files Browse the repository at this point in the history
* added start/end velocities to path class

* version
  • Loading branch information
BBScholar authored Mar 19, 2019
1 parent ce37626 commit f649c7a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ dependencies {
}

group = 'org.team5499'
version = '2.10.1'
version = '2.10.2'


task sourcesJar(type: Jar) {
Expand Down
6 changes: 6 additions & 0 deletions src/main/kotlin/org/team5499/monkeyLib/path/Path.kt
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,12 @@ class Path(
val endPose: Pose2dWithCurvature
get() = Pose2dWithCurvature(points.get(pathLength - 1))

val startVelocity: Double
get() = velocities.get(0)

val endVelocity: Double
get() = velocities.get(velocities.size - 1)

init {
if (points.size != velocities.size) {
println("coords length: ${points.size}, velo length: ${velocities.size}")
Expand Down

0 comments on commit f649c7a

Please sign in to comment.