Skip to content

Commit

Permalink
Cross-gen evolutions support moved from this project to WatWowMap/Pog…
Browse files Browse the repository at this point in the history
  • Loading branch information
Mygod committed Apr 6, 2023
1 parent aa60fcb commit db1a944
Showing 1 changed file with 6 additions and 19 deletions.
25 changes: 6 additions & 19 deletions ohbem.go
Original file line number Diff line number Diff line change
Expand Up @@ -541,27 +541,14 @@ func (o *Ohbem) QueryPvPRank(pokemonId int, form int, costume int, gender int, a
if evolution.GenderRequirement != 0 && gender != evolution.GenderRequirement {
continue
}
pushRecursively := func(form int) {
evolvedRanks, _ := o.QueryPvPRank(evolution.Pokemon, form, costume, gender, attack, defense, stamina, level)
for leagueName, results := range evolvedRanks {
if result[leagueName] == nil {
result[leagueName] = results
} else {
result[leagueName] = append(result[leagueName], results...)
}
evolvedRanks, _ := o.QueryPvPRank(evolution.Pokemon, evolution.Form, costume, gender, attack, defense, stamina, level)
for leagueName, results := range evolvedRanks {
if result[leagueName] == nil {
result[leagueName] = results
} else {
result[leagueName] = append(result[leagueName], results...)
}
}
pushRecursively(evolution.Form)
switch evolution.Pokemon {
case 26:
pushRecursively(50) // RAICHU_ALOLA
case 103:
pushRecursively(78) // EXEGGUTOR_ALOLA
case 105:
pushRecursively(80) // MAROWAK_ALOLA
case 110:
pushRecursively(944) // WEEZING_GALARIAN
}
}
}

Expand Down

0 comments on commit db1a944

Please sign in to comment.