Trying to make the tool clone and then move to the players inventory

I’m trying to make thing where when the player presses on the flashlight it would then clone itself and appear in the players inventory, Not sure what I’m doing but I cant figure it out.

This is what I got so far.

local clickDetector = script.Parent.ClickDetector
local flashLight = script.Parent

	print("Flashlight cloned")

Screenshot 2023-07-05 153103

1 Like

Set the ExplosionType to NoCraters

EDIT: The title was botched! Actual answer: replace flashLight:Clone() with flashLight:Clone().Parent = player:FindFirstChild("Backpack")


When the flashlight is cloned it is not put in workspace it is put in a void. To prevent this you can create a variable that the clone is equal to. That way you can access the clone’s properties like parent.

By the way do you want a response to the explosion or the flashlight?

1 Like

I’m sorry, The title was from my recent post and I have no Idea why its there lol.

So how exactly do I parent it to the players inventory?

I tried: flashLight.Parent = game.StarterPack . but that didn’t work.

Please check this post: Trying to make the tool clone and then move to the players inventory - #2 by oddcraft18

1 Like

You do not want to set the flashlight’s parent to starter pack you want to set the clone. Also, if you put the clone in starter pack it will not appear until the player dies you want to put it in that player’s specific backpack.

1 Like

Thank you. Character limitttt.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.