catchablePokemon..encounterPokemon() allways FALSE
Hello,
My account is not banish. Pokemon Go still works.
I try my code few hours ago 2 or 3 times, it works. Since, no. Every pokemon encounter return false to the encounterPokemon() function.
Can someone help me ?
Regards
`PokemonGo go = new PokemonGo(new GoogleUserCredentialProvider(http, token), http);
go.setLocation(X,Y, Math.random());
List<CatchablePokemon> catchablePokemon = go.getMap().getCatchablePokemon();
System.out.println("Pokemon : " + catchablePokemon.size());
for (CatchablePokemon cp : catchablePokemon) {
EncounterResult encResult = cp.encounterPokemon();
if (encResult.wasSuccessful()) { // ALWAYS RETURN FALSE NOW
System.out.println("Encounter: " + cp.getPokemonId());
CatchOptions options = new CatchOptions(go);
options.useRazzberries(false);
CatchResult result = cp.catchPokemon(options);
System.out.println("Try to catch : " + cp.getPokemonId() + " " + result.getStatus());
try {
Random r = new Random();
int low = 5000;
int high = 10000;
int res = r.nextInt(high-low) + low;
new Thread().sleep(res);
} catch (InterruptedException e) {
e.printStackTrace();
}
}
}
`
That could be the temp ban that prevents capture. Try again in a few hours and report back if it doesn't resolve itself.
I only use this code 2 or 3 times working and you think i'm already temp ban ? So what's the point ? What am I doing wrong ? Because i only use this in area near to my house
Only things i always use a new token to make my program work. Could be from there ? I don't know how to do otherwise on a main Java class
In a for loop, you still fire each encounter immediately, but the catch results are posted with a random sleep time. In theory, you could still be firing each catch result within 0 - 5000 MS of each other.
Ok, better like this ? :
for (CatchablePokemon cp : catchablePokemon) { try { Random r = new Random(); int low = 5000; int high = 10000; int res = r.nextInt(high-low) + low; new Thread().sleep(res); } catch (InterruptedException e) { e.printStackTrace(); } EncounterResult encResult = cp.encounterPokemon(); if (encResult.wasSuccessful()) { System.out.println("Meet : " + cp.getPokemonId()); CatchOptions options = new CatchOptions(go); options.useRazzberries(false); CatchResult result = cp.catchPokemon(options); System.out.println("Try catch: " + cp.getPokemonId() + " " + result.getStatus()); try { Random r = new Random(); int low = 1000; int high = 5000; int res = r.nextInt(high-low) + low; new Thread().sleep(res); } catch (InterruptedException e) { e.printStackTrace(); } } }
Also how can i store the google authentification ?
It now seems to works again. What are the precaution to take to not be ban ?
I use my program this morning, first location it works, next, just above, it does not.
What's wrong ?
Maybe don´t use a random for z?
Is this still occurring? If it is, what does EncounterResult#getStatus return?