Hitbox Api
No reviews yet
Add more colliders for Minecraft
Provides a framework or library for other mods to use.
Neoforge is a fork of the Minecraft Forge available for versions 1.20.1+ of Minecraft. Many Forge mods are compatible with Neoforge and vice versa.
Community voices
Reviews
Click once to include, again to exclude, again to clear
No reviews yet. Be the first to review this project!
Get it on
Available Platforms
Compatibility
Supported Environments
About
Project Details
For authors
Embed Badge
If you're the author of this project, you can embed a live badge anywhere that supports HTML or Markdown. It updates automatically whenever ratings change.
Use HTML for any page that supports it, or Markdown for README files and Markdown-based descriptions.
Identifiers
Platform IDs
Resources
External Links
About
Description
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.

Hitbox API
Adding more common collider for Minecraft
- Oriented Bounding Box (OBB)
- Sphere
- Capsule
- Ray
- Compound
- Multiple collider can be combined into one.
- Composite collider 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 box 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
| Collider | 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.

Versions
Files
Relations
Project Relations
More like this
Similar Mods
Suggestions use data such as tags, dependencies, dependents, descriptions, titles, and more to rank how much they overlap with this mod.
On ModDex
Community snapshot
By the numbers
Statistics
Want to reach Minecraft players?
We're looking for a server hosting partner to feature here and other parts of the site. Interested? Send us a message!
Get in touchGet it on
Available Platforms
On ModDex
Community snapshot
By the numbers
Statistics
Resources