Skip to content

Commit

Permalink
fix going for waypoint zero bug.
Browse files Browse the repository at this point in the history
  • Loading branch information
m4gr3d committed May 26, 2015
1 parent 726401a commit f2849e5
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,10 @@ public void onReceive(Context context, Intent intent) {
break;
case AttributeEvent.MISSION_ITEM_UPDATED:
int currentWaypoint = intent.getIntExtra(AttributeEventExtra.EXTRA_MISSION_CURRENT_WAYPOINT, 0);
speak("Going for waypoint " + currentWaypoint);
if(currentWaypoint != 0) {
//Zeroth waypoint is the home location.
speak("Going for waypoint " + currentWaypoint);
}
break;
case AttributeEvent.FOLLOW_START:
speak("Following");
Expand Down

0 comments on commit f2849e5

Please sign in to comment.