Changelog
Changes:
-
Added support for detecting deep-slate variants of ores. Now, ores like
DEEPSLATE_DIAMOND_ORE
are recognized as part of the same group as their standard counterparts (DIAMOND_ORE
). -
Updated the
isDetectedOre
method to handle both standard ores and their deep-slate variants, ensuring that all relevant ores are correctly identified. -
Introduced the
isOreVariant
method to determine if a given material is a variant of a detected ore. This method accounts for different ore types such as deep-slate variants. -
Enhanced the
formatOreName
method to include names for both standard and deep-slate ores. This ensures that messages display consistent ore names regardless of the variant mined. -
Modified the vein detection logic to handle all 26 neighboring blocks, including diagonals, ensuring that ores connected in any direction are recognized as part of the same vein.
-
Implemented checks to ensure that messages are only sent once per group of connected ores, preventing multiple messages for a single vein of ores.
-
Added a
processedBlocks
set to track all processed blocks within a vein to avoid sending duplicate messages when mining multiple blocks within the same vein. -
Ensured that if a block is replaced in a previously processed vein, it will be detected correctly and not trigger duplicate messages.
Bug Fixes:
-
Fixed an issue where messages were incorrectly sent for subsequent mining actions in the same vein, ensuring that only one message is sent per vein.
-
Resolved the issue of ore detection not working for blocks replaced in an already found vein, ensuring consistent behavior.
Other Improvements:
- Enhanced performance by optimizing vein detection and message sending logic.