跳到正文

BlockTrackerApi

作者:_nArUTo_

This API provides a comprehensive block tracking system for Minecraft mods, enabling efficient monitoring, storage, and querying of specific block positions across dimensions with configurable world-generation and conditional rules.

收藏

介绍

中文介绍正在准备中,下面暂时显示原文。

BlockTracker

BlockTracker is a powerful Minecraft lib that provides a comprehensive API for tracking and monitoring specific blocks across your world. Designed primarily for mod developers, it offers efficient block position storage, retrieval, and event handling with minimal performance impact.

Key Features

  • Multi-Dimensional Tracking – Monitor blocks across all dimensions and chunks
  • Smart Filtering – Configurable rules for world generation and conditional tracking
  • Thread-Safe Operations – Built-in protection for server thread safety
  • High Performance – Optimized data structures using FastUtil for minimal overhead
  • Persistent Storage – Automatically saves and loads tracked block data
  • Flexible Query System – Multiple methods to retrieve tracked blocks by chunk, radius, or dimension

For Mod Developers

Easy Integration

// Track blocks with custom conditions
// Recommended init place: ServerAboutToStartEvent
BlockTrackerApi.trackBlock(Blocks.BEACON, true, block -> {
    return customConditionCheck(block);
});

Multiple Query Options

// Get blocks in specific chunk
LongSet blocks = BlockTrackerApi.getTrackedBlocks(level, chunkPos, Blocks.BEACON);

// Get blocks in area around position
ObjectList<LongSet> areaBlocks = BlockTrackerApi.getTrackedBlocks(level, centerPos, 3, Blocks.BEACON);

Note: This mod is primarily intended for developers. End-users will need mods that implement BlockTracker API to see its benefits.

常见问题

BlockTrackerApi 支持哪些 Minecraft 版本?

BlockTrackerApi 支持 Minecraft Java 版 1.16.5–1.21.1,共 5 个版本,可用的加载器:Forge / NeoForge。下载时注意选择和你游戏版本一致的文件。

BlockTrackerApi 怎么安装?

先用 PCL2 或 HMCL 启动器安装对应版本的 Forge / NeoForge,再把下载的 .jar 文件放进游戏目录的 mods 文件夹,重新启动游戏即可。开启了版本隔离的,mods 文件夹在 versions/版本名 下面。

评论

登录后评论和评分

_nArUTo_ 的其他作品

查看全部 →