"find out when player is AFK by the function or a callback" -?the fastest method.
Code:
if(NetStats_MessagesRecvPerSecond(playerid) == 1)
{
//Player is AFK.
}