Detect if local script has been disabled/deleted?

I need this feature, for my anti-cheat, so that exploiters can’t disable it. I’ve seen some game owners make their own, but I don’t know how to do that.

3 Likes

I’m not sure, but can you try doing
if Parent(wherever your localscript is inside of).localscript(name of script).Disabled == true/false then

2 Likes

I don’t think you can do that. Exploiters disable/delete the script on the client, which won’t be replicated to the server.

I don’t think it’s wise to create a system like that. A local script runs on the client, and if you’re planning on detecting it on the server, your remotes events that sends the data can be easily deleted and prevented. Which results in the server causing an error or yielding indefinitely.

This will not work. Exploiters don’t need to set the disabled property to false nor delete it, for it to not execute.

1 Like

Exploiters can only delete local scripts. If they delete server scripts, it won’t don’t anything.

Yea they can’t delete server script, but you’re trying to detect if a local script is deleted/disabled and that can’t be done on the server.

Hm, it seems making an anti cheat will be more challenging than i anticipated then

The best you can do is server-sided checks and securing your remotes.

I think you can detect if a localscript has been deleted if It’s in the StarterCharacterScripts.

script.Destroying inside of the localscript?

Heya! I was wondering the same question and got the genius idea in my head:
Why not just make a localscript constantly fire the same RemoteEvent to the server every 5 seconds, so server checks if it is being fired, if it’s not then :Kick()

Also, you could make the system that server fires client, if client exists then it will fire server back to prove it exists, if its not: kick

An exploiter can fire that event themselves

i forgor :skull: (char limit fhskjdfbdsjlkfsdlfb)