-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1528 from cawk/master
Add PokeDex
- Loading branch information
Showing
6 changed files
with
54 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
using PoGo.NecroBot.Logic.State; | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading; | ||
using System.Threading.Tasks; | ||
using PoGo.NecroBot.Logic.Logging; | ||
|
||
namespace PoGo.NecroBot.Logic.Tasks | ||
{ | ||
class GetPokeDexCount | ||
{ | ||
|
||
|
||
public static async Task Execute(ISession session, CancellationToken cancellationToken) | ||
{ | ||
int Amount = 0; | ||
var PokeDex = await session.Inventory.GetPokeDexItems(); | ||
for (int i = 0; i < PokeDex.Count; i++) | ||
{ | ||
var CaughtPokemon = PokeDex[i].ToString().Split(new[] { "timesCaptured" }, StringSplitOptions.None); | ||
var split = CaughtPokemon[1].Split(' '); | ||
int Times = int.Parse(split[1]); | ||
if (Times == 0) | ||
{ | ||
|
||
|
||
} | ||
else | ||
{ | ||
Amount++; | ||
} | ||
} | ||
Logger.Write("Amount Of Pokemon Seen:" + PokeDex.Count + ":151" + ", Amount Of Pokemon Caught:" + Amount + ":151"); | ||
} | ||
} | ||
} |