Any idea how I can replace get_players to get accurate players team? In some mods that often switch players team, get_players always fail to return their current team correctly
Code:
stock show_chat(iClient, szMsg[])
{
if (msgSayText == -1)
msgSayText = get_user_msgid("SayText")
if (msgSayText)
{
new iNum, iPlayers[32], iPlayer
if (is_user_alive(iClient))
get_players(iPlayers, iNum, "ch")
else
get_players(iPlayers, iNum, "bch")
for (new i=0; i < iNum; i++)
{
iPlayer = iPlayers[i]
message_begin(MSG_ONE, msgSayText, {0, 0, 0}, iPlayer)
write_byte(iPlayer)
write_string(szMsg)
message_end()
}
}
}