Mineuniverse
Log in Register
Mods

Hitbox Api

Add more colliders for Minecraft
by anecansaitin
Download Claim this project
849 downloads
0 likes
Updated Jul 6, 2026
0 hypes
API and Library

Hitbox API

Adding more common collision boxes for Minecraft

  • Oriented Bounding Box (OBB)
  • Sphere
  • Capsule
  • Ray
  • Compound
    • Multiple collision boxes can be combined into one.
    • Composite collision boxes can be nested.

How to Use

In any place where collision detection is needed, create a collider object and use the methods in ColliderUtil to determine if a collider has occurred.

For entities (Entity), you can achieve collider caching by attaching HitboxDataAttachments#COLLISION. The cached collider can be rendered by pressing F3 + B. Note that this Data does not have a persistence implementation.

Performance

Testing Method

  • JMH Benchmark

Testing Environment

  • CPU: AMD R5 5600G
  • Memory: 32GB
  • JDK: Microsoft OpenJDK 21.0

Testing Settings

  • Warm-up Rounds: 5
  • Test Rounds: 5

Testing Items

  • Collision detection of the same type of collider
Collision Box Score Error Unit
Axis-Aligned Bounding Box 3561837865.930 157982649.213 ops/s
Capsule 22350681.198 238993.658 ops/s
Rotated Capsule 16842309.523 103959.918 ops/s
Oriented Bounding Box 5528493.224 64548.996 ops/s
Rotated Oriented Bounding Box 4648963.750 111369.535 ops/s
Sphere 119556589.705 1711146.560 ops/s

Note: Higher scores indicate better performance. Rotated means the collider is rotated and the relevant vectors are recalculated.

add collider for enttiy

hitboxapi-neo-1.21.1-1.0.0.jar
MC Client, NeoForge, 1.21.3, 1.21.1, Server, 1.21.2
Release 2024-12-03 Get

More from anecansaitin

Free camera API
9,451
Fire Crafting
938
Put Ingot Down!
2,484
Camera Anim
2,090
Free Camera API Tripod
202
Zoom camera
1,276

You Might Also Like

Vivecraft
A Minecraft VR mod on a loader of your choice!
9,988,339
Athena
A crossplatform (Forge/Fabric) solution to connected block textures for 1.19.4+
99,799,527
Lodestone
A collection of code used throughout projects under the Lodestar team.
9,914,417
TheDragonLib
A library for most of sokratis12GR's Mods
9,910,232
Multi Mob Library
A library mod containing essential files for Daveyx0's mob mods
9,892,767
FTB Library (Forge) (Legacy)
FTB Library is a library mod that is used for some of our mods.
98,265,314