how can I make it so the module accepts different name variations for the Attachments? for example: “DmgPoint1”, “DmgPoint2”, “DmgPoint3”…
hey guys, how can i add this hitobx to an player? like, when the player punch the hitbox appears
local Params = RaycastParams.new()
Params.FilterDescendantsInstances = {Character}
Params.FilterType = Enum.RaycastFilterType.Exclude
local newHitbox = RaycastHitBox.new(script.Parent.HitBox)
newHitbox.RaycastParams = Params
newHitbox.Visualizer = true
attempt to index nil with ‘RaycastParams’
is there a reason for this error? It just started to show up randomly now ever since I moved the sword to a new baseplate
I seem to be having an issue with my weapons system. Occasionally its not detecting a hit, is there a way around that?
Is this using parallel Lua? If not, would there ever be an update to support it?
Is it possible to make Dual holded weapon?
yeah, just set up two separate hitboxes
But how to make it in script to know there multiple parts inside with Attachements?
I got this error No attachments found in object: Hitbox. Can be safely ignored if using SetPoints.
Is there a reason on why the hitbox object completely stops working when you use it on a different script?
for some reason the raycast hitbox is going above the attachments (i checked ita nd the attachments are were they are meant to be, but the actual hitbox is way above it)
Did you check when you started the game or before? Something could be affecting it
how to make weapon hit multiple times like chainsaw?
IF YOU ARE LOOKING FOR THE SOLUTION OF THAT BUG IN WHICH HITBOX HITS FARTHER THAN IT’S ACTUALLY IS, HERE IT IS:
Put this script inside of Attachment solver module
--!strict
--- Calculates ray origin and directions for attachment-based raycast points
-- @author Swordphin123
local solver = {}
--- Solve direction and length of the ray by comparing current and last frame's positions
-- @param point type
function solver:Solve(point: {[string]: any}): (Vector3, Vector3)
--- If LastPosition is nil (caused by if the hitbox was stopped previously), rewrite its value to the current point position
if not point.LastPosition then
point.LastPosition = point.Instances[1].WorldPosition
end
local origin: Vector3 = point.LastPosition
local direction: Vector3 = point.Instances[1].WorldPosition - point.LastPosition
return origin, direction
end
function solver:UpdateToNextPosition(point: {[string]: any}): Vector3
return point.Instances[1].WorldPosition
end
function solver:Visualize(point: {[string]: any}): CFrame
return CFrame.lookAt(point.Instances[1].WorldPosition, point.LastPosition)
end
return solver
Hi, I am trying to use this for server hit detection, but I can’t seem to figure out how to make it work
My client sided code consists of detecting a player key press, and activating a server event with no parameters
My server sided code is what I am trying to figure out. I receive the event on the server, then I am wondering if I have to make a new hitbox object assigned to a player each time to detect punch hits, but I feel this is a bad way to go about it.
Please help
i fixed it, it was an issue with the method i was using to position the model
just use link attachments
make a for loop to index for link attachments and put it in a module and do index stuff idk
and name the attachments something like 1A, 1B its simpler
I would probably only have the client have the hotbox and make the server perform a series of checks. It works but it’s probably not the best way if you want it super secure
Two things.
One, would this be the most efficient and smooth way?
Two, how would a series of checks look like (what do you mean)
Thanks