Screenshots

CXA can take a picture of a player's game screen and post it to Discord, automatically when a detection fires or on demand from staff. Screenshots give you evidence for bans and help you check player reports.

Needs screenshot-basic and Is Off by Default

Screenshots use the free screenshot-basic resource, which must be running on your server. They are also switched off until you turn them on in Configuration → System → Screenshots.

Requirements

RequirementWhy it is needed
screenshot-basic startedCXA asks this resource for the picture. Put ensure screenshot-basic above ensure cxa-anticheat in server.cfg.
Screenshots turned onConfig.Screenshot.Enabled is false by default.
Discord webhooksScreenshots are posted to Discord. Without a webhook for the channel, the picture is not kept anywhere.

How It Works

Automatic screenshots, when a detection fires:

  1. A detection with Screenshot on triggers. The console line and the in-game staff alert appear right away.
  2. CXA asks screenshot-basic for a picture of the player's game, using your Encoding and Quality.
  3. CXA waits until the picture arrives, for at most Timeout milliseconds.
  4. CXA applies the punishment. For ban and kick, the player is removed after this wait.
  5. The picture is attached to the Discord log of that punishment: the Bans, Kicks or Warns channel, or the detection's log channel for log.

If no picture arrives within Timeout, the punishment is applied without one. Detections with the punishment none never take a screenshot, because they write no log.

Manual screenshots, taken by staff with the cxascreenshot command, the in-game panel or the web panel, are posted to the Screenshots channel.

[PERF] Your server receives every picture, decodes it and uploads it to Discord. That costs CPU time and bandwidth for each screenshot, which is why the feature is off by default.

Setting It Up

Step 1 — Start screenshot-basic

Install screenshot-basic like any resource and start it before CXA:

# Screenshots (needed for CXA screenshots and Live Screens)
ensure screenshot-basic

# CXA Anticheat after it
ensure cxa-anticheat

Step 2 — Turn On Screenshots

Open Configuration → System → Screenshots in the web panel, switch the group on and save.

OptionKeyDefaultWhat it does
ScreenshotsEnabledfalseTurns screenshots on for detections and staff.
ResourceResource'screenshot-basic'Name of the screenshot resource. Change it only if your copy of screenshot-basic has another folder name.
EncodingEncoding'jpg'Image format: jpg, png or webp.
QualityQuality0.60.1 to 1.0. Lower values give smaller uploads.
TimeoutTimeout6000 msHow long CXA waits for the picture before it punishes without one. Panel range 1000 to 30000 ms.
Store screenshots onUpload'discord'discord attaches the picture to the Discord log. fivemanage uploads it to your Fivemanage account and posts the link instead. See Storing Screenshots on Fivemanage.

The same defaults in config.lua:

Config.Screenshot = {
    Enabled = false,                         -- [PERF] Each screenshot is decoded and uploaded by the server (CPU + bandwidth)
    Resource = 'screenshot-basic',
    Encoding = 'jpg',                        -- 'jpg', 'png' or 'webp'
    Quality = 0.6,                           -- 0.1 - 1.0, lower = smaller upload
    Timeout = 6000,                          -- ms to wait before punishing without a screenshot
    Upload = 'discord',                      -- 'discord' or 'fivemanage'
}

Step 3 — Set the Webhooks

Open Webhooks & keys → Discord webhooks and fill in:

  • Screenshots, for screenshots taken by staff.
  • Bans, Kicks, Warns and Detections, for automatic screenshots attached to detection logs.

Any empty channel falls back to Default. You can also set them in SvConfig.Webhooks in sv_config.lua. See Logging & Discord.

Step 4 — Choose the Detections

Every detection that supports it has its own Screenshot switch in the Configuration tab, with the hint "Attach a screenshot to the log (needs screenshot-basic)." In config.lua it is the Screenshot = true line of the detection.

These detections have Screenshot on by default:

DetectionConfig path
Carrying a vehicleConfig.ClientDetections.VehicleCarry
Teleport to waypointConfig.ClientDetections.WaypointTeleport
Wall shot (illegal RPF)Config.ClientDetections.WallShot
Aimbot (headshot ratio)Config.ServerDetections.Aimbot
Long range melee (infinite punch)Config.ServerDetections.MeleeDistance
One punch (illegal RPF)Config.ServerDetections.OnePunch
Modified game files (illegal RPF)Config.GameFiles.Integrity
Fast reload, fast run, strafe boost (illegal RPF)Config.GameFiles.Timing

They only take screenshots once Step 2 is done. Turn the switch on for the detections where a picture helps you judge the case, for example noclip or invisibility, and leave it off for detections that fire often.

Taking a Screenshot Manually

cxascreenshot

Takes a screenshot of one player and posts it to the Screenshots channel.

Usage:

Console
# In the server console
cxascreenshot 12

# In the game chat
/cxascreenshot 12

Parameters:

  • id (number): The player's server ID

What happens:

  • CXA checks your permission, that the player is online and that screenshots are available.
  • It takes the screenshot and posts it to the Screenshots channel with the title Screenshot, the player's identifiers and your name in the Admin field (Console from the console).

Output:

  • Screenshot of <name> was sent to the logs. when it worked.
  • Usage: /cxascreenshot <id> without a valid ID.
  • Player not found. when nobody has that ID.
  • Screenshots are disabled or screenshot-basic is not started. when screenshots are off or the resource is not running.
  • Screenshot could not be taken. when no picture arrived within Timeout.

By default the server console and the staff roles owner, admin and moderator can use it. Rename it, limit it or disable it (empty name) in Configuration → Staff roles & commands. See Console & Chat Commands.

In-Game Panel

Open the in-game panel with /cxa, select a player and click Screenshot. The panel shows Taking screenshot…, then opens a window with the picture. The same picture is posted to the Screenshots channel, and the action is logged to the Admin channel as In-game panel action. By default the owner, admin and moderator roles can use it (Config.Permissions.Menu.Screenshot).

Panel on codexart.net

In the web panel, open Players and click the camera button next to an online player, or open the player's details and click Screenshot. On the Live map tab, select a player and click Screenshot. Confirm with Take screenshot.

The panel answers Queued. Your server runs it within 30 seconds. The picture goes to the Screenshots channel; it is not shown in the web panel. The outcome appears in Commands → Results, for example sent_to_webhook, screenshot_unavailable, screenshot_failed or player_offline. Team members with the owner, admin or editor role can do this, and each request is recorded in Activity as Screenshot requested.

Where Screenshots End Up

Taken byDiscord channelAlso shown
A detection with Screenshot onThe channel of that log: Bans, Kicks, Warns, or the detection's log channelNo
cxascreenshotScreenshotsReply in chat or console
In-game panelScreenshotsIn the in-game panel window
Web panelScreenshotsResult in Commands → Results

Screenshots are never saved on your server. With Store screenshots on set to Discord webhook, Discord is the only place they are kept. With Fivemanage, they are kept in your Fivemanage account: the Discord log shows the picture from its Fivemanage link, detection logs in the panel's Logs tab show a preview with an Open screenshot link, and a screenshot taken from the web panel shows Open screenshot in the player's Recent panel actions.

Storing Screenshots on Fivemanage

Fivemanage is a media host built for FiveM servers. Use it when you want screenshots outside Discord, for example to keep them longer or to open them straight from the panel.

  1. Create an account on Fivemanage, open the Tokens page of the dashboard and create an API token.
  2. In the web panel, open Webhooks & keys and paste the token into Fivemanage API key. Save. You can also put it in sv_config.lua instead:
SvConfig.Fivemanage = {
    ApiKey = '',
}
  1. Open Configuration → System → Screenshots, set Store screenshots on to Fivemanage and save.

Your server uploads each picture itself, so the token never reaches players. If Fivemanage cannot be reached or refuses the token, the server console shows Fivemanage upload failed (HTTP 401), the screenshot is attached to the Discord log instead with the real status, and the picture is attached to the Discord log as before. With Fivemanage selected but no token saved, screenshots go to Discord.

Bans Are Not Delayed

For bans and kicks, the player is removed first and the upload happens afterwards, so Fivemanage never slows down a punishment.

Privacy

A screenshot shows what is on the player's game screen at that moment, which can include chat messages, phone apps and other personal details. Handle them with care:

  • Tell your players in your server rules that staff can take screenshots.
  • Give only staff access to the Discord channels that receive screenshots.
  • Use manual screenshots to check a concrete suspicion, not to watch players for no reason.
  • Delete screenshots in Discord when you no longer need them as evidence.

Recommendations

Recommended:

  • Keep jpg with a Quality around the default. It keeps uploads small and the picture readable.
  • Turn screenshots on for detections where you want evidence before a ban.
  • Give the Screenshots channel its own webhook, so staff screenshots don't get lost among detection logs.

Avoid:

  • Screenshots on detections that fire very often, such as log detections you are still tuning. Each one costs server CPU and bandwidth.
  • A very long Timeout on ban and kick detections. The player stays in the game until the picture arrives or Timeout runs out.
  • Posting screenshots in public channels.

Detections & Punishments

Live Screens

  • Live Screens stream a player's screen in the panel. Every frame is a screenshot on that player's game.
  • They have their own settings and always use a resource named screenshot-basic.
  • See Live Screens.

Logging & Discord

Staff Roles & Command Access

Team Access

  • Website team roles decide who can request screenshots from the web panel.
  • See Team Access.

Limitations

  • Security rules and join screening never take screenshots. During join screening the player is not in the game yet.
  • A screenshot shows one moment. Use it together with the detection details, not as the only proof.
  • The Resource option only applies to screenshots. Live Screens need the resource to be named exactly screenshot-basic.
  • Large png pictures take longer to upload than jpg or webp.

Common Problems

"Screenshots are disabled or screenshot-basic is not started."

What you see: cxascreenshot answers Screenshots are disabled or screenshot-basic is not started.

How to fix it:

  • Turn on Configuration → System → Screenshots and save. Your server applies it within a minute.
  • Check that screenshot-basic is running: type ensure screenshot-basic in the server console and add the line to server.cfg.
  • If your screenshot resource has another folder name, enter that name in Resource.

"Screenshot could not be taken."

What you see: cxascreenshot answers Screenshot could not be taken., or the in-game panel shows Screenshot failed.

How to fix it:

  • Raise Timeout. The player's game did not deliver the picture in time.
  • Try again with another player. If it fails for everyone, restart screenshot-basic.

The Command Says "sent to the logs" but Nothing Arrives

What you see: You get Screenshot of <name> was sent to the logs. but the Discord channel stays empty.

How to fix it:

  • Set a Screenshots webhook, or a Default webhook, in Webhooks & keys.
  • Check that Configuration → Logs → Logging → Discord webhooks is on.
  • Check that the webhook still exists in Discord.

Detection Logs Have No Picture

What you see: A detection with Screenshot on posts its log without an image.

How to fix it:

  • Check that Configuration → System → Screenshots is on.
  • Check that the detection's punishment is not none; that punishment writes no log.
  • Raise Timeout if the picture is sometimes missing.
  • Check that the detection's own Screenshot switch is on and saved.

The In-Game Panel Says "screenshot-basic is not running."

What you see: Clicking Screenshot in the in-game panel shows screenshot-basic is not running.

How to fix it:

  • The in-game panel shows this text whenever screenshots are unavailable, including when Configuration → System → Screenshots is off. Turn it on.
  • Start screenshot-basic and keep it above ensure cxa-anticheat in server.cfg.

Commands → Results Shows an Error

What you see: A screenshot requested from the web panel ends with screenshot_unavailable, screenshot_failed or player_offline.

How to fix it:

  • screenshot_unavailable: screenshots are off or screenshot-basic is not running.
  • screenshot_failed: no picture within Timeout. Raise it and try again.
  • player_offline: the player left before your server ran the request.

© 2026 CodeXart Studios · CXA Anticheat