hdkv
/
i2_bot
Archived
1
Fork 0

Fix bot failure on 10th grade hands in profiles

master
Vladimir Hodakov 2018-03-31 10:05:59 +04:00
parent dbaa85a517
commit 3129566a1c
1 changed files with 5 additions and 1 deletions

View File

@ -175,7 +175,11 @@ func (u *Users) ParseProfile(update *tgbotapi.Update, playerRaw *dbmapping.Playe
pkName := strings.Split(pokememeString, "+")[0]
pkName = strings.Replace(pkName, " ⭐", "", 1)
pkName = strings.TrimSuffix(pkName, " ")
pkName = strings.Split(pkName, "⃣ ")[1]
if strings.Contains(pkName, "🔟") {
pkName = strings.Split(pkName, "🔟 ")[1]
} else {
pkName = strings.Split(pkName, "⃣ ")[1]
}
pokememes[strconv.Itoa(pi)+"_"+pkName] = pkAttack
powerInt += c.Statistics.GetPoints(pkAttack)
}