Fix stringToInt in a few places.

This commit is contained in:
Stephen Anthony 2020-02-09 16:58:56 -03:30
parent 5273986e88
commit 737cf7b3b7
1 changed files with 3 additions and 3 deletions

View File

@ -51,7 +51,7 @@ Int32 HighScoreManager::numVariations()
Properties props;
string numVariations = properties(props).get(PropType::Cart_Variations);
return (numVariations == EmptyString) ? 1 : std::min(stoi(numVariations), 256);
return (numVariations == EmptyString) ? 1 : std::min(BSPF::stringToInt(numVariations), 256);
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
@ -60,7 +60,7 @@ Int32 HighScoreManager::numPlayers()
Properties props;
string numPlayers = properties(props).get(PropType::Cart_Players);
return (numPlayers == EmptyString) ? 1 : std::min(stoi(numPlayers), 4);
return (numPlayers == EmptyString) ? 1 : std::min(BSPF::stringToInt(numPlayers), 4);
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
@ -194,4 +194,4 @@ Int32 HighScoreManager::score()
return scores[std::min(player, Int32(3))];
return -1;
}
}