Skip to content

Commit

Permalink
All other bots no longer try to clone a null pokemon
Browse files Browse the repository at this point in the history
  • Loading branch information
drgoku282 committed Mar 25, 2017
1 parent 634dbea commit 0097cd4
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions PKMN-NTR/Bot/Bot_Breeding6.cs
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 +727,7 @@ public async void RunBot()
case breedbotstates.readslot:
Report("Bot: Search for empty slot");
waitTaskPKM = Program.helper.waitPokeRead(Box, Slot);
breedPoke = (await waitTaskPKM).Clone();
breedPoke = await waitTaskPKM;
if (breedPoke == null)
{ // No data or invalid
attempts++;
Expand Down Expand Up @@ -1121,7 +1121,7 @@ public async void RunBot()
bool testsok = false;
Report("Bot: Check deposited egg");
waitTaskPKM = Program.helper.waitPokeRead(Box, Slot);
breedPoke = (await waitTaskPKM).Clone();
breedPoke = await waitTaskPKM;
if (breedPoke == null)
{ // No data or invalid
attempts++;
Expand Down
4 changes: 2 additions & 2 deletions PKMN-NTR/Bot/Bot_Breeding7.cs
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ public async void RunBot()
case breedbotstates.readslot:
Report("Bot: Search for empty slot");
waitTaskPKM = Program.helper.waitPokeRead(Box, Slot);
breedPoke = (await waitTaskPKM).Clone();
breedPoke = await waitTaskPKM;
if (breedPoke == null)
{ // No data or invalid
attempts++;
Expand Down Expand Up @@ -402,7 +402,7 @@ public async void RunBot()
bool testsok = false;
Report("Bot: Read recevied egg");
waitTaskPKM = Program.helper.waitPokeRead(Box, Slot);
breedPoke = (await waitTaskPKM).Clone();
breedPoke = await waitTaskPKM;
if (breedPoke == null)
{ // No data or invalid
attempts++;
Expand Down
2 changes: 1 addition & 1 deletion PKMN-NTR/Bot/Bot_WonderTrade6.cs
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ public async void RunBot()
case botstates.readpoke:
Report("Bot: Look for pokemon to trade");
waitTaskPKM = Program.helper.waitPokeRead(Box, Slot);
WTpoke = (await waitTaskPKM).Clone();
WTpoke = await waitTaskPKM;
if (WTpoke == null)
{ // No data or invalid
attempts++;
Expand Down
6 changes: 3 additions & 3 deletions PKMN-NTR/Bot/Bot_WonderTrade7.cs
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,7 @@ public async void RunBot()
case botstates.readpoke:
Report("Bot: Look for pokemon to trade");
waitTaskPKM = Program.helper.waitPokeRead(Box, Slot);
WTpoke = (await waitTaskPKM).Clone();
WTpoke = await waitTaskPKM;
if (WTpoke == null)
{ // No data or invalid
attempts++;
Expand Down Expand Up @@ -481,7 +481,7 @@ public async void RunBot()
case botstates.testpoke:
Report("Bot: Test if pokemon is selected");
waitTaskPKM = Program.helper.waitPokeRead(toppkmOff);
validator = (await waitTaskPKM).Clone();
validator = await waitTaskPKM;
if (validator == null)
{ // No data or invalid
Report("Bot: Error detected or slot is empty");
Expand All @@ -506,7 +506,7 @@ public async void RunBot()
case botstates.canceltouch:
Report("Bot: Cancel selection and check again");
waitTaskPKM = Program.helper.waitPokeRead(Box, Slot);
WTpoke = (await waitTaskPKM).Clone();
WTpoke = await waitTaskPKM;
if (WTpoke != null)
{
currentCHK = WTpoke.Checksum;
Expand Down

0 comments on commit 0097cd4

Please sign in to comment.