#My example of Anti-Cheat

2 messages · Page 1 of 1 (latest)

cinder wraith
#

Dear New State Mobile Development Team,

I’d like to share my concept anti-cheat solution that could help strengthen your existing systems, this code is not the best, but I believe you will make it better.

Key Issues & Proposed Solutions

  1. Memory Editing (HP, Ammo, Speed Hacks)

    • Solution: Server-side validation + memory integrity checks.
    • [C# Example]
      public class MovementValidator
      {
      private Vector3 lastPosition;
      private float maxSpeed = 10f; // Max allowed movement speed

    public bool IsMovementValid(Vector3 newPosition, float deltaTime)
    {
    float distance = Vector3.Distance(lastPosition, newPosition);
    float speed = distance / deltaTime;

     if (speed > maxSpeed)
     {
         Console.WriteLine($"[!] Speed hack detected: {speed} m/s");
         return false;
     }
     
     lastPosition = newPosition;
     return true;
    

    }
    }

  2. Aimbot & No-Recoil Cheats

    • Solution: Behavioral analysis (unnatural aim speed/recoil patterns).
    • [C# Example]
      public class AimbotDetector
      {
      private float lastAngle;
      private float maxHumanTurnSpeed = 90f; // Degrees per second

    public bool IsAimbotting(float newAngle, float deltaTime)
    {
    float angleChange = Math.Abs(newAngle - lastAngle);
    float turnSpeed = angleChange / deltaTime;

     if (turnSpeed > maxHumanTurnSpeed)
     {
         Console.WriteLine("[!] Aimbot detected!");
         return true;
     }
     
     lastAngle = newAngle;
     return false;
    

    }
    }

public class RecoilAnalyzer
{
private float expectedRecoil = 0.5f; // Expected recoil per shot

public bool HasNoRecoil(float actualRecoil)
{
    if (actualRecoil < expectedRecoil * 0.2f) // Too little recoil
    {
        Console.WriteLine("[!] No-recoil cheat detected!");
        return true;
    }
    return false;
}

}

  1. Process-Based Cheats (Cheat Engine, GameGuardian)

    • Solution: Detect and block known cheat tools.
    • [C# Example]
      // Detects Cheat Engine and similar tools
      public static bool IsCheatToolRunning()
      {
      string[] cheatProcesses = { "cheatengine", "gg", "wpepro" };
      foreach (var process in Process.GetProcesses())
      {
      if (cheatProcesses.Any(cheat => process.ProcessName.ToLower().Contains(cheat)))
      {
      Log($"[ANTICHEAT] Blocked: {process.ProcessName}");
      return true;
      }
      }
      return false;
      }
  2. File Tampering (Wallhacks, Model Mods)

    • Solution: SHA-256 file integrity checks.
    • [C# Example]
      using System.Security.Cryptography;

public static bool VerifyFileHash(string filePath, string expectedHash)
{
using (SHA256 sha256 = SHA256.Create())
{
byte[] fileBytes = File.ReadAllBytes(filePath);
byte[] hashBytes = sha256.ComputeHash(fileBytes);
string actualHash = BitConverter.ToString(hashBytes).Replace("-", "").ToLower();

    if (actualHash != expectedHash.ToLower())
    {
        Console.WriteLine("[!] Game file modified: " + filePath);
        return false;
    }
}
return true;

}

// Example usage:
// VerifyFileHash("weapons.dat", "a1b2c3...");

gloomy siren
#

There’s nothing much they can do — hackers are often more advanced than the game’s own security systems. They know every exploit and code in most shooting games. Sometimes, manual reporting helps ban them, but that’s about it. Those are the only practical steps developers can take to control cheating. I’ve already posted about this many days ago.

https://discord.com/channels/813464684904185896/1353541310086250567