Knightmare Server-side Anti-Cheat Service [updated 10/2/2024]

To me, this is such an important aspect to anti-cheats. My general philosophy with them is to automate blocking the blatant stuff. Anything more nuanced can be dealt with manually. Also it is really nice to see the updates and responding to potential improvements in detail. Shows you care, so thank you for your work.

3 Likes

I’ve made a minor service update today. :face_with_raised_eyebrow:
If you are using the auto-update code version, then your servers are already protected. :+1: Instructions for setting up your game to auto-update with each version release is located at the first post on top.

If you prefer the manual update method, I’ve updated the download model at the top as well. Hopefully one day Roblox will give us the ability to release “public” packages to make updating easier with patching, but until then I use the hacky method. :rofl:

8/3/2024

  • Added FPS selector to Debug Window. You can control how fast the client is processing
    the debug data from the server. The max speed is 5 FPS and the lowest is 0 FPS that
    will freeze debug data processing.

This only affects the client, not the server. A large amount of debug data can be generated when testing with a lot of players, which might slow some older mobile devices to a crawl. This allows you to slow down the refresh speed to your client and reclaim some device speed, or even turn it off with the 0 setting if the mobile device is struggling even at the lowest setting of 1 FPS.

The new Debug Window will look like this. The text color will copy whatever you have set for the main debug window itself.
Knightmare_AntiCheat_DebugFPS1

Another service update today. :tada:
If you are using the auto-update code version, then your servers are already protected. :+1: Instructions for setting up your game to auto-update with each version release is located at the first post on top.

If you prefer the manual update method, I’ve updated the download model at the top as well.

8/17/2024

  • Added new configuration option for Teleport Anti-cheat to ignore other players during scans for collideable objects. This is useful for games where players are able to move through each other by design.
  • Updated Teleport Anti-cheat detection to perform additional scans from the hands and feet to check for colliedable objects. This helps to cut down on false detection events when players are moving around objects smaller than the player.
1 Like

Service update today. :tada:
If you are using the auto-update code version, then your servers are already protected. :+1: Instructions for setting up your game to auto-update with each version release is located at the first post on top.

If you prefer the manual update method, I’ve updated the download model at the top as well.

9/22/2024

  • Reduced WaitForChild time on the Character Model from 5 Seconds to 1 Second since scans are done 4 times per second, waiting longer is not really necessary.
  • When a Teleport Cheat is detected and the player is sent back to the last location before the event, their linear velocity is sapped to 0. This helps to stop players from getting caught in a mid-air loop where they are falling so fast, they keep triggering the teleport cheat thus never reaching the bottom of a long fall.

Explanation of recent changes:

  1. The first change of reducing the WaitForChild timeout for the Character Model is simply for efficiency reasons. When the player falls into a pit or some other way that destroys the character model, that leaves nothing to scan, so that player can be skipped until a valid Character Model is available for scanning. A sneaky player could technically hang their scanning routine by creating an infinite wait on the character model by leaving the server at just the right moment after their own character model was destroyed in-game and then returning. So the default timeout was used (5 seconds) to combat this type of direct attack on the anti-cheat service. Since scanning is done 4 times per second (not 5 seconds), the extra wait time isn’t really necessary to combat this type of exploit.
  2. The second update that saps the linear velocity of a player during a teleport cheat is to help developers with unique case where a (non-cheating) player is falling for a long distance and the teleport cheat detection will see this high rate of speed as a teleport cheat and attempt to force-teleport them back up in the air. The issue is that the momentum of the player is the same and thus gravity will keep accelerating the player faster and faster.

To the point where they get stuck in teleport cheat loop as per this example video I made below. In this example, I set the max teleport distance super low to trigger it with only a short falling distance, but the same can happen anywhere in a game map where the player can fall so far and so fast as to create a false teleport cheat event.

What has changed is that now upon a teleport cheat event detected, when the player is force teleported back, it also saps any linear velocity. This will allow the player to actually reach the bottom of a fall (or pit) without being stuck forever in the air. It’s not a perfect solution, but it can help developers having issues because of this without having to create some type of workaround.

The most useful being for Large Open Map Obby developers where they want to prevent cheaters from teleporting check point to check point, but don’t want to put up invisible walls or death boxes underneath or through-out the whole map.

Example video using the same Teleport Cheat settings but with the New Update, how the falling player will be treated. At least now, they can reach the bottom without getting stuck forever. :thinking:

1 Like

Service update today. :tada:
If you are using the auto-update code version, then your servers are already protected. :+1: Instructions for setting up your game to auto-update with each version release is located at the first post on top.

If you prefer the manual update method, I’ve updated the download model at the top as well.

10/2/2024

  • Minor Syntax Service update to keep it current with Roblox Code Etiquette.
  • Tracer Lines added to Teleport Debug for better Visual Tuning of anti-cheat service.
  • Added additional “maxShortRangeTeleport” check to better filter false events that trigger when a player moves around a sharp corner really fast.

Explanation of recent changes:

  1. This is a syntax update on using services in Roblox via their recommended code etiquette. It’s just how a developer assigns an object to the service without using shorthand. :thinking:
  2. This update will be very useful for Obby Developers (or anyone else really) as it gives visual tracers in-game when you enable debugging for the Teleport anti-cheat services. The tracers stay for 30 seconds so as not to pollute your world if you are setting off a lot of cheat detection events on purpose. :wink:
  3. This update helps Obby developers where players jumping or running around sharp corners triggers a false teleport cheat detection event. This update takes the current maxShortRangeTeleport and applies an additional check to the collide-able object by checking the distance where the “hit” takes place on that specific object. A player that is right against an object and moves around a sharp enough corner fast enough can create a collision of the raycheck because of the distance the player can cover between scans. The additional check simply looks at where the player was during the last scan, how much distance was between the player and the hit point on the object and if that distance is less than the developer maxShortRangeTeleport setting. This distance should be less than the distance of the two scans already, so logically, if the player was below this threshold, it was more likely because the player “moved” around the object and not directly through it. It’s not a perfect solution, but it helps a lot with false detection events in testing. It also gives more power to the maxShortRangeTeleport setting to help reduce false events.

Here are some example pictures below of the tracer lines:

My character clipped the side of this object and triggered a possible cheat detection. The tracers show where the anti-cheat was finding a collision via the yellow lines, the green line is where it found a path without a collision and considered it a false positive without punishing the player.
Teleport Tracer1

This was a teleport exception, so it colors it green. It still traces out the path to show the developer where the exception was allowed.

This is an active teleport cheat detected with the red line showing the first detection point, the yellow lines are where it tried to peak around the collisions with the head, hands and feet but still found no clear path, so it was considered a valid teleport cheat through a collide-able object.
Teleport Tracer3

Seem pretty promising, will be referencing this later on!