Spigot Plugin

RiftAntiCheat

RiftAntiCheat includes a full set of commands for staff and administration. The main command /ac opens the main GUI, while /ac reload refreshes all configuration, checks, and messages. Staff can toggle alerts with /ac alerts or specify /ac alerts on and /ac alerts off to enable or disable cheat notifications, and use /ac debug <player> to view real-time information like violation levels, ping, movement data, and CPS, with /ac debug off disabling it. Player information can be viewed using /ac info <player>, showing violations, CPS, ping, flags, and movement data, while /ac logs <player>

Read the full description

displays full violation history. Moderation tools include /ac freeze <player> and /ac unfreeze <player> to control player movement, and /ac spectate <player> or /ac unspectate for staff spectating mode. Check management is handled with /ac checks, /ac checks toggle <check>, and /ac checks info <check> to list, enable, disable, or inspect specific anti-cheat checks. There is also a bypass system using /ac bypass <player>, manual punishment commands such as /ac kick <player> <reason>, /ac tempban <player> <time> <reason>, and /ac ban <player> <reason>, and a detailed /ac profile <player> command that shows stats like KDR, CPS history, reach violations, speed flags, join time, and ping history. System monitoring is available through /ac status, showing TPS, RAM usage, active checks, and flagged players, while ban wave tools include /ac banwave add <player>, /ac banwave remove <player>, /ac banwave start, and /ac banwave list. Data management is handled with /ac reset <player>, and the admin GUI can be opened with /ac gui. Additional tools include /ac cps <player> for live CPS tracking and /ac broadcast to toggle server-wide alerts. The recommended permission setup includes roles such as riftac.admin, riftac.staff, riftac.alerts, riftac.debug, riftac.logs, riftac.freeze, riftac.spectate, riftac.gui, riftac.bypass, riftac.punish.kick, riftac.punish.tempban, riftac.punish.ban, riftac.checks.toggle, and riftac.reload.

src/main/java/eu/codexe/riftanticheat/RiftAntiCheat.java
package eu.codexe.riftanticheat;

import eu.codexe.riftanticheat.commands.ACCommand;
import eu.codexe.riftanticheat.gui.AdminGui;
import eu.codexe.riftanticheat.listeners.ConnectionListener;
import eu.codexe.riftanticheat.listeners.PlayerMonitorListener;
import eu.codexe.riftanticheat.managers.AlertManager;
import eu.codexe.riftanticheat.managers.BanWaveManager;
import eu.codexe.riftanticheat.managers.CheckManager;
import eu.codexe.riftanticheat.managers.CooldownManager;
import eu.codexe.riftanticheat.managers.DebugManager;
import eu.codexe.riftanticheat.managers.FreezeManager;
import eu.codexe.riftanticheat.managers.ProfileManager;
import eu.codexe.riftanticheat.managers.PunishmentManager;
import eu.codexe.riftanticheat.managers.SpectateManager;
import eu.codexe.riftanticheat.storage.StorageManager;
import eu.codexe.riftanticheat.storage.YamlStorage;
import eu.codexe.riftanticheat.utils.ConfigManager;
import eu.codexe.riftanticheat.utils.MessageUtil;
import org.bukkit.Bukkit;
import org.bukkit.command.PluginCommand;
import org.bukkit.plugin.java.JavaPlugin;

public class RiftAntiCheat extends JavaPlugin {

    private static RiftAntiCheat instance;

    private ConfigManager configManager;
    private MessageUtil messageUtil;
    private StorageManager storageManager;
    private AlertManager alertManager;
    private CheckManager checkManager;
    private CooldownManager cooldownManager;
    private DebugManager debugManager;
    private FreezeManager freezeManager;
    private SpectateManager spectateManager;
    private PunishmentManager punishmentManager;
    private BanWaveManager banWaveManager;
    private ProfileManager profileManager;
    private AdminGui adminGui;

    @Override
    public void onEnable() {
        instance = this;
        saveDefaultConfig();
        configManager = new ConfigManager(this);
        messageUtil = new MessageUtil(this, configManager);
        storageManager = new YamlStorage(this);
        storageManager.load();
        alertManager = new AlertManager(this, storageManager);
        checkManager = new CheckManager(this, storageManager);
        cooldownManager = new CooldownManager(this);
        debugManager = new DebugManager(this, storageManager);
        freezeManager = new FreezeManager(this);
        spectateManager = new SpectateManager(this);
        punishmentManager = new PunishmentManager(this, storageManager);
        banWaveManager = new BanWaveManager(this, storageManager);
        profileManager = new ProfileManager(this, storageManager);
        adminGui = new AdminGui(this);