Run it
Copy the script and paste it into your executor.
repeat task.wait() until game:IsLoaded()
local Players = game:GetService("Players")
local VirtualUser = game:GetService("VirtualUser")
local Player = Players.LocalPlayer
while not Player do
Players:GetPropertyChangedSignal("LocalPlayer"):Wait()
Player = Players.LocalPlayer
end
if getconnections then
for _, connection in pairs(getconnections(Player.Idled)) do
pcall(function()
if connection["Disable"] then
connection["Disable"](connection)
elseif connection["Disconnect"] then
connection["Disconnect"](connection)
end
end)
end
else
Player.Idled:Connect(function()
VirtualUser:CaptureController()
VirtualUser:ClickButton2(Vector2.new())
)
This anti-AFK script was made because most other anti-AFK scripts are unnecessarily complicated, with UIs and extra features that are not needed. This one is built to be simple, lightweight, and reliable. Just put it in auto-execute and it will handle the rest. It includes checks to make sure Roblox, Players, and LocalPlayer are loaded before running, which prevents errors caused by the client still starting up.

Universal