From 2a83b97b29f23f12164c90386d23acd4c7289ec8 Mon Sep 17 00:00:00 2001 From: Unknown Date: Thu, 11 Aug 2016 16:49:47 -0400 Subject: [PATCH] Fix to rate limitations on startup when using the GUI --- src/main/java/dekk/pw/pokemate/PokeMate.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/java/dekk/pw/pokemate/PokeMate.java b/src/main/java/dekk/pw/pokemate/PokeMate.java index d37dba5..af33a50 100644 --- a/src/main/java/dekk/pw/pokemate/PokeMate.java +++ b/src/main/java/dekk/pw/pokemate/PokeMate.java @@ -10,6 +10,7 @@ import dekk.pw.pokemate.tasks.TaskController; import dekk.pw.pokemate.tasks.Update; import dekk.pw.pokemate.util.LatLongFromLocation; +import dekk.pw.pokemate.util.Time; import javafx.application.Application; import okhttp3.OkHttpClient; @@ -97,13 +98,14 @@ private PokeMate() throws LoginFailedException, RemoteServerException { context.setLat(lat); context.setLng(lng); go.setLocation(context.getLat().get(), context.getLng().get(), 0); + Time.sleep(5000); new Update(context).runOnce(); if (Config.isShowUI()) { PokeMateUI.setPoke(this); new Thread(() -> Application.launch(PokeMateUI.class, "")).start(); } - + Time.sleep(500); TaskController controller = new TaskController(context); controller.start(); startTime = System.currentTimeMillis();