use find method instead of binsearch

develop
Myk Taylor 2023-09-09 10:42:20 -07:00
parent e4edc9be4e
commit ee61c76bc0
No known key found for this signature in database
1 changed files with 1 additions and 1 deletions

@ -102,7 +102,7 @@ static void remove_seed_config(color_ostream &out, int id) {
static bool validate_seed_config(color_ostream& out, PersistentDataItem c)
{
int seed_id = get_config_val(c, SEED_CONFIG_ID);
auto plant = binsearch_in_vector(world->raws.plants.all, &df::plant_raw::index, seed_id);
auto plant = df::plant_raw::find(seed_id);
if (!plant) {
WARN(config, out).print("discarded invalid seed id: %d\n", seed_id);
return false;