GH-180 Add GriefPrevention region support for combat restrictions - #423
GH-180 Add GriefPrevention region support for combat restrictions#423vLuckyyy wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 689c1e9ddb
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| @Override | ||
| public Location getMax() { | ||
| Location max = this.claim.getGreaterBoundaryCorner(); | ||
| return new Location(this.world, max.getBlockX(), this.world.getMaxHeight() - 1, max.getBlockZ()); |
There was a problem hiding this comment.
Include the claim's greater boundary in containment
GriefPrevention's greater boundary corner is inclusive, but Region.contains compares every coordinate with < getMax(). Consequently, a combat-tagged player standing on a claim's maximum X or Z row is reported by GriefPrevention as inside the claim while GriefPreventionRegion.contains reports them outside; moves within that row are then handled as attempts to enter and cancelled rather than receiving the normal inside-region knockback. Represent the upper bounds as exclusive or override containment so the greater boundary blocks remain included.
Useful? React with 👍 / 👎.
Resolve: GH-180