Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

I've been trying to make a rasengan tool?

but ROBLOX is saying "Touched" isn't a valid member of the tool. How do I fix this?


rasengan = game.StarterPack.Rasengan

local function onTouched(part) local h = part.Parent:Findfirstchild("Humanoid") h.Health:Takedamage(10) end script.Parent. Touched:connect(onTouched)

1 comment

0

Are you sure the Script isn't the 'Handle'? If not, then that may be your problem. :)

1 answer

The tool is not a Part so the Touched function will not work for it also please do the lua button and put your scripts in it so people can actually read your script its hard to read

also writing a onTouch script is way better if you write it this way

script.Parent.Touched:connect(function(hit)
local h = hit.Parent:FindFirstChild("Humanoid")
h.Health:TakeDamage(10)
end)

see this way you don't need to write that extra line at the very bottom

This discussion is preserved as it was. New answers, comments, and votes are closed.