Fix SulfurCubeBucket and TNT bypassing protection, along with some other changes - #1469
Open
CatTeaA wants to merge 11 commits into
Open
Fix SulfurCubeBucket and TNT bypassing protection, along with some other changes#1469CatTeaA wants to merge 11 commits into
CatTeaA wants to merge 11 commits into
Conversation
…oth; and some minor changes
…lags.animalgriefing/mobgriefing to more places
- bump flag-deny-message-cache max size to avoid bottleneck for large servers; 10k entries cost only 1MB - skip redundant NPC checks when sending messages. NPCs are exempted at frontend checks(sending a message to an NPC shouldn't cause any error either)
- when both the world blacklist and whitelist are empty, a boolean check is more lightweight
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Main changes:
1. Flags.shoot is now FlagMode.Both
(Fine-grained control over player projectile shooting)
2. Fix SulfurCubeBucket bypass protection.
3. Apply Flags.windexplode to (Wind Burst enchantment) and (Wind-Charged effect).
(We use ExplosionResult.TRIGGER_BLOCK to cover all forms of Wind Explode, since the Potion of Wind Charging allows any living entity to become an explosion source)
4. Fix fire_charge bypassing protection to ignite TNT
5. Add cooldown option for sending duplicate Flag deny messages(v1.16+)
(Effectively suppresses frequent duplicate Flag-Deny messages; players don't need to receive 20 identical denial messages within a single second)
Minor changes:
Clear player displays on config reload;
(Exempt some checks early when Visualizer.Type.Modern is not in use)
Notify player when knockback is denied, e.g., for wind charge explosion knockback rejection.
Name tag checks are only for LivingEntity – right‑click does nothing on non‑living entities(Armor stands are still LivingEntity)
Reuse and simplify many repetitive checks
Apply Flags.animalgriefing/mobgriefing to more places