I coded this in like 10 minutes and then checked with bots and it worked.
All names are stored in
g_stored_names[MAX_NAMES+1][33] array (isn't it obvious? - look at name), lines:
Code:
g_last_name_pos += 1
copy(g_stored_names[g_last_name_pos], 32, name)
@_Master_:
You should analyze whole algorithm... I set g_last_name_pos = 0 in logevent_round_start() to reset names (g_last_name_pos==0 means no names stored). "for" loop is for linear search in
g_stored_names array. If there are no names stored then it shouldnt start any search, instead it will store player name in first empty cell in
g_stored_names array. On next connection attempts g_last_name_pos will be >=1, so it will start the search...
__________________