I'm trying to make an anti-AFK disconnection script for my game. Thanks for the Help.
'AFK Disconnection' is directly dependent on the players individual interaction with the game. The only way for them to interact is by using their mouse or keyboard, so sorry to say, but you can't prevent it.