Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 5 additions & 10 deletions app/src/main/java/com/javaawesome/tag/MapsActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -133,9 +133,8 @@ public void onLocationResult(LocationResult locationResult) {
return;
}

sendUserLocationQuery(locationResult);
updateMarkerAndCircleForAllPlayers(players);

sendUserLocationQuery(locationResult);
}
};
}
Expand Down Expand Up @@ -237,10 +236,10 @@ public void handleMessage (Message inputMessage) {
//if the player is in the session, but not in the player list, then make a new player and add them to the players list and add a marker
if(contains == false){
Marker marker = mMap.addMarker(new MarkerOptions()
.position(player.getLastLocation())
.title(player.getUsername()));
.position(new LatLng(updatePlayer.lat(), updatePlayer.lon()))
.title(updatePlayer.username()));
Circle circle = mMap.addCircle(new CircleOptions()
.center(player.getLastLocation())
.center(new LatLng(updatePlayer.lat(), updatePlayer.lon()))
.radius(tagDistance)
.fillColor(Color.TRANSPARENT)
.strokeWidth(3));
Expand Down Expand Up @@ -641,11 +640,7 @@ public void onResponse(@Nonnull final Response<GetSessionQuery.Data> response) {
Log.i(TAG, "Starting point is " + startingPoint);

//once the session ID and starting loc are in place, then make the first player.
if (playerID == null) {
createPlayer();
} else {
queryForPlayerObject();
}
queryForPlayerObject();

Log.i(TAG, "Made it to the after the if/else within getSessionCallBack");
//converting from GetSessionItems to players
Expand Down