Перейти к содержимому
Mineforgian

Bookshelf Runtime Bundle

Core utilities from the Bookshelf modular datapack library: math, vectors, raycasting, entity control, blocks, health, and more.

Загрузки
701
Подписчики
3
Обновлён
17 июня 2026 г.
Лицензия
MPL-2.0

Опубликован 5 апреля 2025 г.

Bookshelf

Bookshelf is a library datapack for Minecraft. It's modular, so mapmakers can pick only the parts they need. This helps them create complex systems more easily.

Documentation      


⚡ Bookshelf Runtime Bundle

Core utilities from the Bookshelf modular datapack library: math, vectors, raycasting, entity control, blocks, health, and more.

"Don't reinvent the wheel, just realign it."

— Anthony J. D'Angelo

✨ Features

  • 🧠 Logic: math, bitwise operations, vectors, and randomness
  • 🎮 Entities: movement, position, health, hitboxes, and raycasting
  • 🌍 World: environment, generation, time, scheduling, and blocks
  • 🧩 Utilities: strings, ids, linking, gui, sidebar, view detection, and xp management

📚 Read the full documentation

📖 About Bookshelf

This bundle is part of the Bookshelf Library:

🧩 Find more modules in the Bookshelf organization
📦 Get the full Bookshelf Suite

🤝 Get involved

💬 Join our Discord community
🛠 Contribute via the contribution guide

Ченджлог

4.1.0Релиз26.2 · 17 июня 2026 г.

📦 Bookshelf - 4.1.0

🗂️ The Collection Update!

Adds a new collection module and support for Minecraft 26.2.

Bookshelf is now based on Minecraft 26.2.

  • 🐛 #552 - Migrate to the Minecraft 26.2 predicate format.

🧱 bs.block

  • #555 - Updated block mappings for Minecraft 26.2.

🗂️ bs.collection

  • 🎉 #510 - Added a new bs.collection module with 45+ functional programming operations for collections, including map/filter/reduce, set operations, slicing, aggregation, and generation utilities.

🎯 bs.hitbox

  • #555 - Updated entity hitboxes for Minecraft 26.2.

🔦 bs.raycast

  • 🐛 #556 - Fixed $raycast.prev_entry_distance and $raycast.prev_exit_distance lambda score scaling.
4.0.1Релиз26.1 · 4 апреля 2026 г.

📦 Bookshelf - 4.0.1

🩹 Hotfix!

This is a hotfix for version 4.0.0.

🎯 bs.hitbox

  • 🐛 #543 - Fixed glow squid entities hitboxes and the is_sized entity type tag.

🧣 bs.spline

  • 🐛 #545 - Fixed an issue where 2D and 3D stream functions incorrectly returned 1D results.
4.0.0Релиз26.1 · 24 марта 2026 г.

📦 Bookshelf - 4.0.0

🧹 The Tiny Sweep Update!

First release for Minecraft's new date-based versioning, dropping support for previous versions.

⚠️ BREAKING CHANGES: This version has breaking changes!

Bookshelf is now based on Minecraft 26.1.

🧱 bs.block

  • ⚠️ #509 - Removed multi-tick fill operations (fill_block, fill_type, fill_random). Use the new bs.generation module for async iteration with callbacks.
  • ⚠️ #523 - Removed deprecated functions and tags from previous versions.
  • ⚠️ #525 - Removed NBT concatenation from block output. State and NBT are now returned as separate fields.
  • #509 - Simplified fill_block to use the vanilla fill command (single-tick execution).
  • #509 - Simplified fill_type with a cleaner recursion model (single-tick execution).

🔬 bs.dump

  • 🐛 #524 - Updated #bs.dump:var for compatibility with Minecraft 26.1.

⛰️ bs.environment

  • 🐛 #527 - Fixed the different features of the module for Minecraft 26.1. Please, note that between previous Minecraft version and this one, the number of elapsed days has been reset to 0.

🌱 bs.generation

  • ⚠️ #509 - Complete module rework. Replaced gen_shape_2d, gen_fractal_shape_2d, and gen_simplex_shape_2d with a generic iteration system.
  • #509 - Added on_cuboid for 3D iteration over a cubic region with configurable direction, spacing, and tick limit.
  • #509 - Added on_rectangle for 2D iteration over a rectangular region with configurable direction, spacing, and tick limit.
  • #509 - Added predefined callbacks: set_block, set_block_type, set_random_block, fractal_noise_2d, and simplex_noise_2d.
  • 🐛 #435 - Configurable iteration direction now allows accommodating mask offsets when blocks are updated during iteration.

🎯 bs.hitbox

  • ⚠️ #523 - Removed deprecated functions and tags from previous versions.
  • ⚠️ #532 - Removed fluids from the intangible block tag to simplify the use of hitbox providers.
  • #532 - Updated entity hitboxes for Minecraft 26.1.

🏃 bs.move

  • ⚠️ #523 - Removed deprecated arguments from previous versions.

🔦 bs.raycast

  • ⚠️ #531 - Removed deprecated bs:out raycast and bs:lambda raycast storage data.
  • ⚠️ #531 - Renamed on_hit_point callback to on_entry_point. Added new on_exit_point callback.
  • ⚠️ #531 - Renamed $raycast.distance to $raycast.entry_distance. Added $raycast.exit_distance.
  • ⚠️ #531 - Replaced $raycast.pierce_distance (delta) with $raycast.prev_entry_distance and $raycast.prev_exit_distance (absolute values). Compute deltas manually for more flexibility (e.g., entry - prev_entry).
  • #531 - Added $raycast.entry_point.[x,y,z] and $raycast.exit_point.[x,y,z] lambda scores for precise hit positions relative to the target.
  • #531 - Added $raycast.targeted_block.[x,y,z] lambda scores for targeted block coordinates.
  • 📝 #531 - Improved documentation with comprehensive "How to use" section including examples for callbacks, filtering, piercing, and hitbox providers.
3.2.2Релиз1.21.9, 1.21.10, 1.21.11 · 1 февраля 2026 г.

📦 Bookshelf - 3.2.2

🩹 Hotfix!

This is a hotfix for version 3.2.1.

🎯 bs.hitbox

  • 🐛 #520 - Fixed Nautilus entities hitboxes.
  • 🐛 #519 - Fixed fluid hitbox providers for full liquid blocks.
3.2.1Релиз1.21.9, 1.21.10, 1.21.11 · 12 января 2026 г.

📦 Bookshelf - 3.2.1

🩹 Hotfix!

This is a hotfix for version 3.2.0.

🎲 bs.random

  • 🐛 #514 - Fixed #bs.random:choice rarely selecting the last option.
3.2.0Релиз1.21.9, 1.21.10, 1.21.11 · 9 декабря 2025 г.

📦 Bookshelf - 3.2.0

🧱 The Block Update!

Introduces new block data and deprecates several older features in preparation for the future.

Bookshelf is now based on Minecraft 1.21.9-1.21.11.

  • #403 - Added the #bs.load:status function to view loaded modules.
  • #501 - Optimized tp commands used in macros.
  • #501 - Reduce NBT writing and remove a few macros.
  • 🐛 #501 - Ensure sculk sensors are not triggered when markers are killed.

🧱 bs.block

  • 🗑️ #489 - Deprecated play_block_sound in favor of more granular functions (play_break_sound, etc.).
  • #496 - Added new predicates: is_conductive, is_powered, is_spawnable, is_strongly_powered, and is_weakly_powered.
  • #496 - Added new functions: is_touching_power, is_touching_strong_power, and is_touching_weak_power.
  • #489 - Added new block property functions: get_blast_resistance, get_friction, get_hardness, get_instrument, get_jump_factor, get_luminance, get_sounds, and get_speed_factor.
  • #489 - Added new block sound functions: play_break_sound, play_hit_sound, play_fall_sound, play_place_sound, and play_step_sound.
  • #489 - Added new block tags: can_occlude and ignited_by_lava.
  • #489 - Modified emit_block_particle to support a default type, aligning it with the new block sound function behavior.

🎯 bs.environment

  • 🐛 #501 - Fixed look_at functions teleporting the player to the current execution position.

🎯 bs.hitbox

  • 🗑️ #484 - Block tag has_offset has been deprecated and will be removed in a v4.0.0. Please use has_shape_offset instead.
  • 🗑️ #484 - Function #bs.hitbox:get_block has been deprecated and will be removed in a v4.0.0. Please use #bs.hitbox:get_block_shape or #bs.hitbox:get_block_collision instead.
  • 🗑️ #484 - Functions #bs.hitbox:is_entity_in_block_interaction, #bs.hitbox:is_entity_in_blocks_interaction, and #bs.hitbox:is_in_block_interaction have been deprecated and will be removed in a v4.0.0. Please use #bs.hitbox:is_entity_in_block_shape, #bs.hitbox:is_entity_in_blocks_shape, or #bs.hitbox:is_in_block_shape instead.
  • #502 - Added new 1.21.11 entities.

🏃 bs.move

  • #473 - Added custom block hitboxes and soft collisions.
  • 🐛 #487 - Prevented false collisions on zero-velocity axes with partial blocks such as slabs.

🔦 bs.raycast

  • #473 - Added custom block hitboxes and improved multi-layer piercing.

👀 bs.view

  • 🐛 #498 - Fixed #bs.view:at_block_placement to match vanilla placement behavior for special blocks such as cauldrons, hoppers, composters, and scaffolding.
3.1.1Релиз1.21.6, 1.21.7, 1.21.8 · 30 августа 2025 г.

📦 Bookshelf - 3.1.1

🩹 Hotfix Release!

Patch release for version 3.1.0.

🎯 bs.environment

  • 🐛 #482 - Fixed misplaced test function that caused module load errors.
3.1.0Релиз1.21.6, 1.21.7, 1.21.8 · 17 июля 2025 г.

📦 Bookshelf - 3.1.0

💫 The Spatial Update!

Introduces Moon and Sun position features, as well as fully customizable hitboxes that integrate across the entire Bookshelf ecosystem.

Bookshelf is now based on Minecraft 1.21.8.

🧱 bs.block

  • 🐛 #469 - Fixed missing execute in minecraft:overworld when running location-based loot tables.

🔬 bs.dump

  • 🐛 #441 - Fixed #bs.dump:var incorrectly appending undefined to output.

⛰️ bs.environment

  • #14 - Added #bs.environment:get_sun_angle to get the sun's angle at a specific time on the Y axis relative to the horizon, in degrees.
  • #14 - Added #bs.environment:get_moon_angleto get the moon's angle at a specific time on the Y axis relative to the horizon, in degrees.
  • #14 - Added #bs.environment:get_current_sun_angle to get the current sun's angle on the Y axis relative to the horizon, in degrees.
  • #14 - Added #bs.environment:get_current_moon_angle to get the current moon's angle on the Y axis relative to the horizon, in degrees.
  • #14 - Added #bs.environment:get_moon_phase to get the current moon phase as a string identifier following Minecraft's 8-day lunar cycle.
  • #14 - Added #bs.environment:look_at_sun to orient the executing entity to look at the sun.
  • #14 - Added #bs.environment:look_at_moon to orient the executing entity to look at the moon.
  • #475 - Added time-based predicates: is_day_time, is_night_time, is_sunrise_time, is_sunset_time for determining current time of day.
  • #475 - Added villagers behavior predicates: is_villager_working_time, is_villager_socializing_time, is_villager_sleeping_time for detecting villager activity phases.
  • #475 - Added beds usage predicate: is_bed_time for determining when players can use beds based on weather and time conditions.
  • #475 - Added mobs behavior predicates: is_undead_burning_time, is_monster_spawning_time for detecting mob behavior condition according to weather and time.
  • #475 - Added bees behavior predicate: is_bee_sleeping_time for detecting time when bees are in their nests/hives.
  • #475 - Added creakings spawning predicate: is_creaking_spawn_time for detecting time when creakings can spawn.

❤️ bs.health

  • 🐛 #466 - Fixed a bug where healing on Paper servers always set players' health to maximum.

🎯 bs.hitbox

  • #465 - Added support for custom hitboxes. #bs.hitbox:get_entity now also returns depth in addition to width. For most dynamic entities depth equals width, except for static entities (e.g. item frames, paintings) and custom hitboxes.

🖱️ bs.interaction

  • 🐛 #463 - Fixed an issue where left/right click events could incorrectly target previously clicked entities instead of the current one.

🏃 bs.move

  • #465 - Optimized bounding box computation for moving entities and added support for baked and custom hitboxes.

🧭 bs.position

  • 🐛 #455 – Replaced /rotate with /tp in bs.position to fix jitter and momentum issues.

🎲 bs.random

  • #286 - Added support for normal distribution generation to bs.random module.
  • 🐛 #469 - Fixed missing execute in minecraft:overworld when running location-based loot tables.

🔦 bs.raycast

  • #465 - Added support for baked and custom entity hitboxes.
  • #445 - #bs.raycast:run now computes all lambda data before invoking callbacks.
  • 🐛 #457 - Fixed raycasts not stopping at the nearest hit when detecting both blocks and entities.

🧣 bs.spline

  • #417 - Added full support for linear splines.

Комментарии

Загружаем…