From 260d6647e63eba63f5eacc2a6220177898ac89ab Mon Sep 17 00:00:00 2001 From: 8dcc <8dcc.git@gmail.com> Date: Thu, 27 Jul 2023 22:13:54 +0200 Subject: [PATCH] Check is_friend with player_extra_info --- src/util.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/util.c b/src/util.c index 682a031..101851b 100644 --- a/src/util.c +++ b/src/util.c @@ -32,10 +32,8 @@ bool valid_player(cl_entity_t* ent) { } bool is_friend(cl_entity_t* ent) { - /* TODO */ - - (void)ent; - return false; + return !strcmp(player_extra_info[ent->index].teamname, + player_extra_info[localplayer->index].teamname); } char* get_name(int ent_idx) {