
FP's AntiFreecam
High-Performance Anti-Freecam/Anti-Xray for Spigot, Paper, Folia, and with Bedrock Support. Secure your world with ease againts freecammers.
- Загрузки
- 758
- Подписчики
- 5
- Обновлён
- 22 июня 2026 г.
- Лицензия
- MIT
Опубликован 20 мая 2026 г.
🛡️ FPAntiFreeCam
Anti-FreeCam/Anti-Xray Protection

Protect underground bases, caves, and hidden structures from players using FreeCam or X-Ray mods. FPAntiFreeCam intercepts outgoing packets and replaces underground blocks with air. So FreeCam users see nothing but void below the surface.
⚠️ This plugin does not block ore X-ray. It is designed to protect bases, farms, and hidden structures underground.
✨ Features
- 👁️ Anti-FreeCam / Anti-Xray — hides all underground blocks via packet manipulation.
- 📦 Entity hiding — conceals mobs, item frames, and farms inside protected zones.
- 🔔 Update checker — notifies admins in-game and in console when a new version is available.
- ⚡ Async & optimized — tick-batched chunk refreshes, minimal performance impact.
- 🌍 Universal platform support — Paper, Purpur, Spigot, Bukkit & Folia (multi-threaded region-aware scheduling).
- 📱 Bedrock support — Geyser / Floodgate compatible.
🖥️ Commands
| Command | Description | Permission |
|---|---|---|
/fpac reload |
Reload the config | fpantifreecam.admin |
/fpac stats |
Show live plugin stats | fpantifreecam.admin |
/fpac debug |
Toggle debug logging | fpantifreecam.admin |
/fpac world <add|remove> <world> |
Add/remove a protected world | fpantifreecam.admin |
/fpac bypass <player> |
Toggle bypass for a player | fpantifreecam.admin |
/fpac help |
Show command help | fpantifreecam.admin |
/fpreload |
Quick config reload shortcut | fpantifreecam.admin |
/fpdebug |
Quick debug toggle shortcut | fpantifreecam.admin |
Aliases: /fpafc, /antifreecam, /fpacreload, /fpacdebug
🔑 Permissions
| Permission | Description | Default |
|---|---|---|
fpantifreecam.admin |
Full access to all commands | OP |
fpantifreecam.reload |
Reload configuration | OP |
fpantifreecam.debug |
Toggle debug mode | OP |
fpantifreecam.world |
Manage protected worlds | OP |
fpantifreecam.bypass |
Exempt from protection (staff/builders) | ❌ |
⚙️ Config
Click to expand config.yml
# ============================================================
# FPAntiFreeCam – Configuration
# Anti-FreeCam protection for Spigot / Paper / Folia
# 1.19+ · 1.20+ · 1.21+ · 26.1+
# ============================================================
# PLEASE DO NOT CHANGE!!
config-version: 4.0
# ── General ──────────────────────────────────────────────────
settings:
# Check for updates on startup and notify admins (fpantifreecam.admin permission) on join.
update-checker: true
# Language file in plugins/FPAntiFreeCam/lang/<language>.yml
language: "en"
# Print verbose debug info to console (leave false in production)
debug-mode: false
# Seconds a player must wait between FreeCam-state refresh triggers.
# Prevents spam-refreshing when rapidly crossing the surface Y level.
refresh-cooldown-seconds: 3
# ── Protected worlds ─────────────────────────────────────────
# Add every world name that should have underground-hiding active.
# Tip: avoid nether/end worlds – they can cause visual glitches.
worlds:
list:
- "world"
# - "survival"
# - "resource_world"
# ── FreeCam protection thresholds ────────────────────────────
protection:
# Y level at-or-above which hiding is ALWAYS armed.
# Players standing at or above this Y cannot see blocks below void-y.
# Recommended: set to roughly your world's actual surface height.
# Example: 64 for a normal overworld, 31 for a flat/custom world.
# NOTE: This replaces the old "surface-y" key. Both are supported.
protection-y: 64.0
# Blocks below protection-y before protection turns OFF when descending.
# Prevents chunk-refresh spam when jumping at the surface boundary.
hysteresis-y: 2.0
# Every block at-or-below this Y is replaced with the void block
# (replacement.block-type) when protection is active.
# Pick the highest Y where your bases/storage actually sit, then add ~5 blocks.
# Unsure? Stand on your deepest vault floor in-game and use that Y minus 2.
# Default 15 works for typical overworld bases dug to Y~11-20.
void-y: 15
# Optional per-world void-y overrides (world name -> Y level).
# Worlds not listed here use the global void-y above.
# per-world-void-y:
# world_nether: 40
# resource_world: 20
# Pie-chart protection: strips tile entities and entity spawns from packets
# while protection is active. This prevents players from using the F3 pie chart
# to find bases (chests, mob farms, etc.) through the void.
pie-chart-protection: false
# Absolute Y floor. Players BELOW this value always have protection OFF.
# Fixes the void-floor bug when digging straight down near void-y level.
# Rule: void-y < deep-deactivation-y < protection-y
# Example with defaults: 15 < 20 < 64
deep-deactivation-y: 20.0
# Raycast zone: players between deep-deactivation-y and protection-y.
# Two sub-checks decide whether to arm protection here:
# 1. Look-direction: camera pointing upward (freecam angle exploit)
# 2. Sky access: open vertical path to protection-y (cave ceiling gap)
raycast:
enabled: true
# Minimum upward look vector (0.0–1.0) to arm protection. ~0.15 ≈ 9° above horizontal.
min-upward-angle: 0.15
# Milliseconds of stability before applying a state change via raycast.
# Prevents flicker near zone boundaries. 500ms is a good balance.
deactivation-debounce-ms: 500
# Also cast diagonal rays (NE/NW/SE/SW) to catch angled cave openings.
multi-directional: true
# ── Replacement block ─────────────────────────────────────────
# Block type sent to the client in place of hidden underground blocks.
# "air" produces a clean void look (recommended).
# "stone" can be used to fake a solid floor instead.
replacement:
block-type: "air"
# ── Entity hiding ─────────────────────────────────────────────
entities:
# Hide non-player entities that are inside the hidden zone.
# Prevents FreeCam from revealing mob farms / storage mobs.
hide-entities: true
# ── Player notifications ────────────────────────────────────────
notifications:
action-bar:
# Show a HUD message while protection is active for a player.
enabled: false
message-active: "&c☠ FreeCam Protected"
# ── Anti-cheat helpers ────────────────────────────────────────
anti-cheat:
freeze-detection:
# Log a console warning if a protected player above protection-y
# has not moved for N seconds (possible position-spoofing FreeCam).
enabled: false
seconds: 30
# ── Performance ───────────────────────────────────────────────
performance:
# Folia: enable region-aware chunk scheduling (auto-detected)
folia-optimizations: true
# Paper/Spigot: max chunks refreshed per server tick
max-chunks-per-tick: 40
# Instant protection: force a large-radius refresh when a player
# first enters the surface-y zone so bases are hidden immediately.
instant-protection:
enabled: true
# Chunks radius to refresh when instant protection fires
instant-load-radius: 14
# Pre-load distance in blocks above surface-y where instant refresh is armed
pre-load-distance: 10
# Force re-encode of chunk data immediately (prevents momentary base glimpse)
force-immediate-refresh: true
# Limit how far chunk REFRESHES reach when protection toggles.
# WARNING: does NOT limit packet masking — but stale client cache outside
# this radius may briefly show real blocks until those chunks reload.
# Leave disabled unless you need the perf savings and accept that tradeoff.
limited-area:
enabled: false
chunk-radius: 4
✅ Compatibility
| Platform | Supported |
|---|---|
| Paper 1.19 – 26.1.2+ | ✅ |
| Purpur | ✅ |
| Spigot | ✅ |
| Bukkit | ✅ |
| Folia | ✅ |
| Geyser / Floodgate | ✅ |
💬 Support
Discord: Join our Discord Server GitHub: FPAntiFreeCam GitHub
Secure what players shouldn't see.
Ченджлог
1.4.4Релиз26.1, 26.1.1, 26.1.2 · 22 июня 2026 г.
🛡️ FPAntiFreeCam v1.4.4 — Minor bug fixes
Fixed Plugin not able to check for updates (HTTP 404 error)
1.4.3Релиз26.1, 26.1.1, 26.1.2 · 5 июня 2026 г.
🛡️ FPAntiFreeCam v1.4.3 — Security & Optimization Update
This massive update introduces critical security hardening, prevents CPU thread/scheduler leaks on reload, and resolves several gameplay edge-cases such as vehicle mounting and spectator mode bypasses. Fully tested and verified on PaperMC & Folia from 1.19 up to 1.21.11 / 26.1.2.
🔒 Security & Protection Hardening
- Pie-Chart Protection Overhaul: Removed the
isPieChartProtectionEnabledconditional guard from block entities and spawn entity packet interception. Security features (like stripping tile entity NBT data and hiding underground entity packets) are now active unconditionally while a player is in the protected zone. - Teleport Race Condition Fixed: Delayed state updates to align perfectly with the actual teleport tick. This eliminates a brief 1-tick window where client-side exploits could grab chest/ore data before the teleport fully registered.
- Surface Raycast Protection Fixed: Corrected a bug where players standing fractionally below the surface Y-level had their protection inadvertently disabled.
- Mounting Protection: Integrated
VehicleEnterEventandVehicleExitEventmonitors to instantly evaluate protection states when players enter or leave vehicles.
⚡ Bug Fixes & Optimizations
- Scheduler Thread Leaks Remedied: Resolved a CPU leak during command reloads (
/fpac reload) where repeating background tasks were not tracked and canceled. All active schedulers are now safely destroyed and re-initialized. - Spectator Mode Bypass Support: Fixed a layout obscuring issue where Spectators traversing protected zones were impacted by the void replacement blocks.
- Event Listener Cleanup: Dropped redundant Bukkit event listeners to prevent internal state-racing during gamemode transitions.
- Invite Link Fix: Fixed the expired Discord invite link in documentation.
🔧 Configuration
- Verified compatibility across configurations. No manual file changes required!
1.3.1Релиз26.1, 26.1.1, 26.1.2 · 26 мая 2026 г.
Changelog
- Layer 1 logic system was inverted, they are now fixed.
1.3.0Релиз26.1, 26.1.1, 26.1.2 · 25 мая 2026 г.
✨ New
Two-layer underground detection system — replaces the old single raycast zone with a cleaner, more reliable two-layer approach:
Layer 1 – Hard floor (
deep-deactivation-y, default Y=20): if a player's feet are below this Y, protection is unconditionally OFF. No raycast, no exceptions. Fixes the Y=16 void bug and trial chamber weirdness entirely.Layer 2 – Raycast zone (between
deep-deactivation-yandsurface-y): two sub-checks decide whether to arm protection — camera angle (looking upward) and sky visibility (open ceiling above). Both must be false to stay unprotected.
Update checker — on startup, the plugin checks Modrinth for a newer version. If one exists, a banner is printed to console and any online admins (
fpantifreecam.admin) are notified. New admins are also notified on join. Toggle viasettings.update-checker: true/false.
⚙️ Config
- Added
protection.deep-deactivation-y: 20.0— the absolute Y floor below which protection is always off. - Added
settings.update-checker: true— toggle the update checker. - Removed
protection.raycast.zone— replaced bydeep-deactivation-y. - Existing configs are automatically migrated on first load (no manual edits needed).
1.2.0Релиз26.1, 26.1.1, 26.1.2 · 24 мая 2026 г.
🐛 Bug Fixes
Fixed protection not working for most surface players — a broken
effectiveVoidYcalculation in the packet handler was setting the hide threshold to Y=-12 for players between Y=15–47, making bases fully visible. Underground blocks are now always hidden correctly at the configuredvoid-y.Fixed raycast and move handler fighting each other — when a player dipped just below
surface-y,onPlayerMovewould deactivate protection instantly, then the raycast task would re-activate it 250ms later, causing rapid state flipping and chunk refresh spam. The move handler now defers to the raycast task inside the raycast zone.Fixed eye-Y vs feet-Y inconsistency — the raycast task used eye position (~1.6 blocks above feet) while the move handler used feet position, creating a dead zone where neither system owned the state. Both now use feet-Y consistently.
Fixed raycast overshoot — the vertical ray was cast
surfaceY - eyeY + 2.0blocks, overshooting past the surface and registering false positives from surface-level blocks.
✨ New
- Raycast deactivation debounce — protection now waits a configurable delay before
deactivating when a player leaves the raycast zone, preventing flicker at the boundary.
Configurable via
protection.raycast.deactivation-debounce-ms(default:500).
⚙️ Config
- Added
protection.raycast.deactivation-debounce-ms: 500— existing configs are automatically migrated on first load (no manual edits needed).
1.1.0Релиз26.1, 26.1.1, 26.1.2 · 21 мая 2026 г.
Bug fixes + Stability
- New features: Raycast-based activation (look-up-from-cave check) + enhanced /fpac stats with TPS, memory, uptime, and packet counters.
- Optimizations: Section-level skipping in ChunkListener (skip whole sections above voidY instead of iterating all 16 Y layers per section), int ID comparison instead of equals(), and early-out if minY > voidY.
- Fixed Underground Chunks not loading when player is underground/looking at the Configured Y Level.
1.0.0Релиз26.1, 26.1.1, 26.1.2 · 20 мая 2026 г.
Initial Release v1.0.0
- Updated PacketEvents to v2.12.1 for full Minecraft 1.21+ and 26.1 support.
- Fixed the IllegalStateException: void future error for improved connection stability.
- Added native support for Paper, Purpur, Folia, and Bedrock (Geyser/Floodgate).
- Implemented a smart config auto-updater and refined the startup branding.
Комментарии
Загружаем…