So, I have made a "Attack." It clones a sphere from ServerStorage and makes it grow, hurting anything which touches it but normal players (I have made a R6 Model and named his humanoid BotHumanoid, and then checked if it had BotHumanoid, then makes it take damage, more info in the not working script.)
For some reason it doesn't work, if you can tell me how to fix it, I would be greatful.
bomb.Touched:Connect(function(hit) if hit.Parent.Name == "BotHumanoid" then local human = hit.Parent.BotHumanoid human.Health = human.Health - 10 end end) --The full script is in the comments, it's pretty long because I don't wanna use a while loop to resize the attack, I have a way to make it smoother, which requires me to do it without a while loop.
Not sure if this is what you wanted but you could try it.
script.Parent.Touched:Connect(function(hit) if hit.Parent:FindFirstChild("BotHumanoid") then hit.Parent.BotHumanoid:TakeDamage(5) end end)