#I need some help with my hit boxes and ragdolls ;(
1 messages · Page 1 of 1 (latest)
we gotta get the ball rolling somehow
Yeah, by learning, not generating crap
its like both
I tried to make them myself... that didnt work so I went to AI
arent you like prestige master or wtv? you here to help or troll?
everyone wants to make a tsb clone and it is guaranteed you have no chance of vibe coding your way into a working combat system. start with the basics https://create.roblox.com/docs/en-us/tutorials/fundamentals/coding-1/coding-fundamentals
Help, but can’t if your script is AI generated
coo
I have much to learn..
** You are now Level 2! **
ai slop ❤️🩹 ❤️🩹
add a angularbpdyvelocty or sum
hi i have similar combat. Heres my hitbox script
local function hitbox(combo, style)
local hitbox = Instance.new("Part")
hitbox.Size = Vector3.new(5, 5, 5)
hitbox.Parent = hrp
hitbox.Transparency = 1
hitbox.Anchored = true
hitbox.CanCollide = false
local params = OverlapParams.new()
params.FilterType = Enum.RaycastFilterType.Exclude
params.FilterDescendantsInstances = {char}
local hitchar = {}
local connection
task.delay(0.1, function()
if connection then
connection:Disconnect()
hitbox:Destroy()
end
end)
connection = RS.RenderStepped:Connect(function()
hitbox.CFrame = hrp.CFrame * CFrame.new(0, 0, -2)
local hits = game.Workspace:GetPartBoundsInBox(hitbox.CFrame, hitbox.Size, params)
for _, v in ipairs(hits) do
if v:FindFirstAncestorOfClass("Model") and not table.find(hitchar, v:FindFirstAncestorOfClass("Model")) then
local targetchar = v:FindFirstAncestorOfClass("Model")
local targethumanoid = targetchar:WaitForChild("Humanoid")
if targethumanoid == nil then return end
table.insert(hitchar, targetchar)
if char:GetAttribute("Stunned", true) then return end
vfxfunc(targetchar)
AttackHandler:FireServer(combo, style, targetchar)
end
end
end)
end
basically the hitbox is something called GetPartBoundInBox and the hitbox part is just a reference for the getpartboundinbox to follow.
the hitchars = {} is a table to store all the hitchars so they dont get hit again once hit
params are used to exclude the players char so they dont get hit
and its put in a renderstepped(Runs the code every frame, it also can only be used client side, heartbeat is the alternative for serverside but its "slower") to keep checking if something is in the bound box aka the hitbox, and if it's a model with a humanoid, if its just a model with no humanoid then it returnds end which basically ends the script