From b07fafd5a9fa5de6fea383f5b562894f5fa1ecd5 Mon Sep 17 00:00:00 2001 From: jmbau <30726620+jmbau@users.noreply.github.com> Date: Sun, 13 Aug 2023 18:05:51 +0200 Subject: [PATCH] Update humanio.c --- src/humanio.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/humanio.c b/src/humanio.c index b9913f6..68e9e3d 100644 --- a/src/humanio.c +++ b/src/humanio.c @@ -230,13 +230,7 @@ int SARHumanLoadFromFile(sar_human_data_struct *hd, const char *filename) { FGetValuesF(fp, value, 1); if(hdp_ptr != NULL) - { - hdp_ptr->assisting_humans = - ( - (MAX((int)value[0], 0) < SAR_ASSISTING_HUMANS_MAX) - ? MAX((int)value[0], 0) : SAR_ASSISTING_HUMANS_MAX - ); - } + hdp_ptr->assisting_humans = CLIP((int)value[0], 0, SAR_ASSISTING_HUMANS_MAX); }