
GriefPrevention3D
Форк популярного GriefPrevention с поддержкой 3D-субделений. Создавайте участки с точными границами по высоте - идеально для многоуровневых построек и сложных приватов на сервере Minecraft.
Список изменений
GriefPrevention3D v18.3.9
Wiki: https://github.com/castledking/GriefPrevention3D/wiki
Overview
Fix for the per-claim PvP toggle: attacking a player inside a claim with PvP disabled silently denied the hit — the player was protected but never told why.
Root cause
The general melee PvP handler (handlePvpDamageByPlayer) had an early-return gate that skipped all
claim PvP checks when both global no-combat configs were off:
if (attackerData.ignoreClaims
|| !config_pvp_noCombatInPlayerLandClaims
&& !config_pvp_noCombatInAdminLandClaims) {
return false;
}
Servers running the per-claim PvP toggle typically leave the global "no combat in claims" flags
off (combat is decided per claim), so the gate short-circuited and handlePvpInClaim was never
reached. That meant claimIsPvPSafeZone was never consulted, the attack was not attributed to the
claim, and the "that player is in a PvP safe zone" / "can't fight while protected" message never
fired — the protection happened silently.
Fix
When the per-claim PvP toggle feature is enabled, the melee handler now bypasses the
global-config-only gate and falls through to the normal claim PvP logic. handlePvpInClaim
consults claimIsPvPSafeZone, which cancels the attack in a PvP-disabled claim and sends the
appropriate protection message to the attacker.
To summarize the resulting per-claim toggle behavior after v18.3.8 + this release:
- PvP enabled claim: combat works (overrides any global no-combat fallback);
- PvP disabled claim: combat is blocked and the attacker is told why;
- claims the server didn't enable the toggle for: fall back to the global config as before.
Upgrade notes
No configuration, storage, or migration changes. Drop-in replacement for v18.3.8.
