Could you also make a video tutorial of this module. It seems really cool but I’m more of a visual learner
Maybe when I get the time soon!
Oh Okay! Also there’s a bug where the hitbox just doesnt work
Could you show an example? That seems strange.
Yes, Alright lemme pull up the video
I believe the issue is that the magnitude spatial type doesn’t account for objects, but only humanoids / characters. Here is what the code looks like unedited.
I hope this helps to solve the problem. When I changed the spatial type to “Box”, it was fixed.
Thank You!!
This helped me alot an now I can use this create module
You’re welcome! I’m glad I found a solution to your problem.
I’ve been trying to get this work for over a day, or two, but I have no clue what I’m doing wrong. I’m a really terrible scripter, as I don’t specialize in scripting - yes I’ve read the documentation, is it in the wrong spot? I don’t know how I’m supposed to fix this, as I don’t even know how to use this. Can someone help me with this error?
Edit -
Since this is a rather major problem, I’m gonna try out another module until someone can help me fix this out.
Make sure the HitboxClass Module object value is set to the HitboxClass module script! It might’ve gotten set to another value somehow. The next update I do I’ll likely remove this and have the module automatically make the object value instead.
Link to above video
I think I have it in the wrong place, because it’s nil when I start it, where should I put the module script? I’m calling it from the server, by the way.
The above is when I hit play, so I think it’s because of where I put the module.
There’s a bug in the module where the HitSomeone Event doesn’t work for some reason. However, HitObject will work
You need it in ReplicatedStorage. Both the client and server need to see it.
That sounds like intended behavior. Hitboxes can be in one of two modes, Humanoid or Object mode. They don’t do both at the same time.
It would be better if instead of settin some alive folder, i can just use Workspace so it can return the player characters too, here even if i set this to Workspace, it wont run and the reason i did this was because player character is in Workspace, not inside a folder
When im inside a hitbox, all it prints was the main character model (Daedalus) but doesn’t return a player model in that table if i set this to npc folder
If you absolutely need the hitbox to look through workspace, just remove or comment out the assertion on line 41 for checking if the alive folder is a descendant of workspace, as of the latest update. It’s generally good practice to keep all entities in a folder so it’s easier to go through them later.
I’m kinda confused about the second part, so you have an NPC folder that doesn’t contain actual player models, and only the NPCs? Do you want to search for both NPCs and players?
It’s a required setting and i didn’t know where to set so i set it to the NPC Folder other than workspace in the first place, I only need it to find player model as that’s what im supposed to do for an NPC but setting that to Workspace causes the error to suddenly happen.
i was about to comment the line where it errors but my only concern was the module won’t run at all cuz i thought it had a type checking that wont match so i didn’t bother removin or toggle the comment on that part.
You’d comment out that line and then in the HitSomeone signal, check if the model is associated with an NPC or not. There’s no type there, just an assertion.
Alright, but, what’s the ID supposed to be? I don’t see anything mentioning it, and the documents say it’s optional, but it’s clearly not (since I keep getting an index nil.)
I tried setting it to 0, but it’s still giving me an index nil, so, I don’t know what it’s supposed to be set to.
That’s saying that HitboxParams is nil. Are you passing it into the new function?