HitboxRemaster Beta Release! (Current ver. v1.1.1)

Introducing HitboxRemaster! A performant, light-weight and typesafe module for creating dynamic Hitbox and static Zone objects based on the Spatial Query API.
Latest build: beta v1.1.1 (18 Oct 2023)

Useful links:
Source
API
Examples
Changelogs
Benchmark

Why HitboxRemaster?

  • Easy to use - Clear and concise class API, ready for simple operations in just a few lines.
  • Type-safe - Extensively typed. Safe to use in a strict-typechecking environment.
  • Powerful - Libraries like Trajectory and Metafunctions to enable advanced use-cases.
  • Customizable - Customize the behavior of individual Hitboxes and Zones with properties and methods.
  • Performant - Blazingly-fast to run and use.
  • Object-oriented - Everything in this module are objects, enabling compatibility with different programming paradigms.
  • Memory-proof - Automatic garbage-collect operations. Manual garbage-collect can be initiated on every class with simple methods.
  • Replication - Fully usable on both server and client.

HitboxRemaster is not compatible with roblox-ts, though this might change in the future. (No promise)

How to Install:
Copy the code of HitboxRemaster into a ModuleScript, then require it in a Script or LocalScript.

Disclaimer: HitboxRemaster is currently in a Beta state, stability in a production environment is not guaranteed and almost definitely not bug-free, though this will improve with subsequent updates.

HitboxRemaster is free and open source, for any use including commercial. You are free to modify and fork HitboxRemaster for your own needs. Credits are not required (but I would appreciate it <3), but you must not claim that you’re the creator of this module and its assets.

I’ll try to read and respond to as many comments as I can! If you encounter a bug or issue with HitboxRemaster, please file an issue on github!

21 Likes

Hi @LadyCelastia, I saw this post and figured it might be what I needed, could I use this module for a quick hitbox? I’ve been trying to make a hitbox cover an entire room (not too big of a room) but then do Detroy() on it after a task.wait(2). My current hitbox system wasn’t cutting it and I wanted to know if this could be used for something like that?

3 Likes

Also, heavy sidenote. But how did you make the website for: “Hitbox - HitboxRemaster”?

I like how well organized it is and how clean it looks and wanted to make one of my own. Is there a tutorial video or how would I go about making something as such?

2 Likes

Github has some documentation for it, runs in tandem with the repo, nice and clean :pray:

4 Likes

Thank you for that @Wertyhappy27

Yeah it is possible. The limit of how big a hitbox can be is the same as the limit of roblox’s spatial query API.

As for the website, it was made using mkdocs (a python package) in a python virtual environment inside visual studio code. The website was generated using a yml script, along with .md files detailing each page and image files used in the website. Then, the website is pushed onto github via workflows and manual force push commands in system kernel, with a SSH key. I recommend checking out a tutorial video on youtube on how to do it, it’s pretty simple once you’ve seen someone else do it. (Keep in mind that windows, mac and linux all have different kernel command prefixes and arguments for python and python packages! You need to read the python api for your os)

1 Like

Question: Why should I use this over Muchacho hitbox?

2 Likes

Would use this for R2D but I legit don’t have time to redo my melee system for this :stuck_out_tongue:

1 Like

Each hitbox/hit detection module has its own pros and cons, some are more performant while others offer more functionalities. It’s really up to which one fits your criteria more

Edit: For anyone who sees this, I’m currently working on a major update for HitboxRemaster, probably releasing this week. Stay tuned!

1 Like

Nevermind, it’s releasing today.

Major Update v1.1 (17/10/2023)

  • Completely overhauled types, works with Roblox Studio intellisense now.
  • Major optimization: All ScriptSignals of Hitbox and Zone now only fire when there is at least 1 ScriptConnection.
  • Hitbox now backtracks if the distance between last frame’s position and current frame’s position is larger than the Hitbox. (Only works on Sphere shape currently)
  • Added Hitbox.PartEntered and Hitbox.PartLeft, both are ScriptSignals of the Hitbox class which fires when any part enters or leaves the Hitbox while the Hitbox is active.
  • Hitbox now no longer completely ignore characters with a ForceField. Due to this, characters with a ForceField are now registered by Hitbox.Hit, please adjust your scripts accordingly.
  • API updated.
  • Plus all the previous v1.0 changes!

Again, if you encounter any issue or have any feature suggestion, please tell me! :smile:

2 Likes

Well, I designed the module to be as friendly to use as possible. In my opinion, it would take less time to set-up a melee system with HitboxRemaster than with BasePart.Touched, since everything like debounce and maximum hits allowed are handled by the module. But when it comes to hit detection, it’s mostly personal preference. Some prefer minimal modules like otam, some prefer elaborate ones like raycast hitbox and zoneplus and others prefer doing it themselves. There’s nothing wrong with using a method over another. If you feel like sticking to your current method, don’t feel pressured to change. You are not required to change.