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

How do I make a tool directly insert into a player's character?

Here is my code:

game.Players.PlayerAdded:connect(function(player)
	player.CharacterAdded:connect(function(character)
		local tool = Lighting.BasicTool:clone()
		Instance.new(tool,character)
	end)
end)

The tool's name is BasicTool. I have it in Lighting. I want it to automatically equip so I would directly put it into the player's character.

1 comment

0

Okay. Put it in backpack and use the script I do.

2 answers

if youre going to give it directly when they join why not just put it in the backpack

Put the tool in the backpack and use this NOTE: Put this script in the tool

game.Players.PlayerAdded:connect(function(p)
wait(5)
p.Character.Humanoid:EquipTool(p.Backpack["NameOfToolHere"])
end)
script.Parent.UnEquipped:connect(function()
p.Character.Humanoid:EquipTool(p.Backpack["NameOfToolHere"])
end)

That should work! If it doesn't give me a message.

1 comment

0

I'm trying to make it so you do not see the backpack.

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