feat: add CraftEngine custom block support for island level calculation#419
Open
tastybento wants to merge 1 commit intodevelopfrom
Open
feat: add CraftEngine custom block support for island level calculation#419tastybento wants to merge 1 commit intodevelopfrom
tastybento wants to merge 1 commit intodevelopfrom
Conversation
Adds CraftEngine block detection to processBlock() alongside ItemsAdder, Oraxen, and Nexo. CraftEngine blocks are counted using their native namespaced ID (e.g. mynamespace:my_block) and can be assigned point values in blockconfig.yml. Adds isCraftEngine() to Level and validates CE block IDs in BlockConfig.isOther(). Requires BentoBox 3.15.0-SNAPSHOT. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
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.
Summary
processBlock()alongside ItemsAdder, Oraxen, and NexoisCraftEngine()toLevel.javafollowing the same pattern asisItemsAdder()/isNexo()BlockConfig.isOther()so admins can configure point values inblockconfig.ymlbentobox.versionto3.15.0-SNAPSHOT(requires feat: add CraftEngineHook for centralised custom block support BentoBox#2952)How it works
CraftEngine blocks are identified by their native namespaced ID (e.g.
mynamespace:my_block). Inblockconfig.ymladmins assign values using those IDs directly:CraftEngine can be excluded from level calculation by adding
CraftEnginetodisabled-plugin-hooksin the Level config.Context
Requested in issue #418. BentoBoxWorld/BentoBox#2952 adds the
CraftEngineHookthat this PR uses — no direct CraftEngine compile dependency is needed in Level.Depends on: BentoBoxWorld/BentoBox#2952
Test plan
disabled-plugin-hooks: [CraftEngine]in config → CE blocks ignored (counted as vanilla material)blockconfig.yml; invalid IDs rejected with log warning🤖 Generated with Claude Code