Like Title says, but not a script like:
function onEquip "Blah blah blah" something.Equipped:connect(onEquip)
But a Script like:
script.Parent.Equipped:connect(function(...
I don't know how to do that, thnaks for the help
What you are trying to create is something called an anonymous function, a function that does not have a direct identifier, or name.
You can only use these kinds of functions with built-in ROBLOX events, such as Equipped or Touched.
yourTool.Equipped:connect(function() --Code for when the Tool is equipped. end)
That would be the same thing as
function onEquipped() --Code for when the Tool is equipped. end yourTool.Equipped:connect(onEquipped)
But in a less amount of lines.
Here is the Wiki page on anonymous functions so you can read more about them.
If I helped you out, be sure to accept my answer!