local mirclone = game:GetService("ReplicatedStorage").Mir:WaitForChild(player:WaitForChild("Mir").Value):Clone()
if mirclone:FindFirstChild("Kwami") then
local mirmodel = mirclone:FindFirstChild("Kwami")
end
mirclone.Parent = player:WaitForChild("Backpack")
✓ ANSWER ACCEPTED
The players get a value but then for some reason they wont get the clone?
1 answer
✓ Accepted answer
the player's backpack is reset whenever they spawn
usually, when PlayerAdded fires, the player's character won't have loaded yet, meaning the tool is deleted when they actually do spawn
you can put the tool in the player's StarterGear to ensure they get the tool every time they spawn, or if you just want them to have it the first time they spawn, you can wait for CharacterAdded to fire
-- StarterGear
local mirclone = game:GetService("ReplicatedStorage").Mir:WaitForChild(player:WaitForChild("Mir").Value):Clone()
if mirclone:FindFirstChild("Kwami") then
local mirmodel = mirclone:FindFirstChild("Kwami")
end
mirclone.Parent = player:WaitForChild("StarterGear")
-- CharacterAdded
player.CharacterAdded:Wait()
local mirclone = game:GetService("ReplicatedStorage").Mir:WaitForChild(player:WaitForChild("Mir").Value):Clone()
if mirclone:FindFirstChild("Kwami") then
local mirmodel = mirclone:FindFirstChild("Kwami")
end
mirclone.Parent = player:WaitForChild("Backpack")
1 comment
0
can this be put into a serverscript?
This discussion is preserved as it was. New answers, comments, and votes are closed.

4 comments
is it in a local script?
no but this is running in serverscriptservice
did you set the variable "player"?
yes like this :game:GetService("Players").PlayerAdded:Connect(function(player)