Pokemon-Go-Rocket-API
Pokemon-Go-Rocket-API copied to clipboard
How to get lured pokemon on fort
How to get lured pokemon on lured fort?
// first we need to get all map objects
var map = player.Map.GetMapObjects();
// after, let get ALL pokestops in map
var pokestops = map.MapCells.SelectMany(x => x.Fort).Where(i.Type == FortType.Checkpoint && i.CooldownCompleteTimestampMs < DateTime.UtcNow.ToUnixTime());
// now, lets find a pokestop lured and a lured pokemon =)
foreach (var pokestop in pokestops){
if(pokestop.LureInfo != null) {
//wow a lured pokestop
var luredpokemon = pokestop.LureInfo.ActivePokemonId;
// do what you want
}
}
I hope this help :)