-
What do you want to achieve? A script that makes an exact copy of the player as they run, then it fades away and deletes itself
-
What is the issue? I have a functioning script but some of the player’s 3d clothing isn’t being cloned and placed into the workspace
here’s a video of it in action so you can get a better understanding:
https://gyazo.com/d36348ff44809c1b60db0947fc567ca9 -
What solutions have you tried so far? I tried looping through all of the player’s parts and clone them but that brough up random errors and didn’t work at all.
here’s the script:
local UserInputService = game:GetService("UserInputService")
local player = game.Players.LocalPlayer
local character = player.Character
local running = false
local tween
local function CloneMe(char) -- cloning the player
char.Archivable = true
local clone = char:Clone()
char.Archivable = false
return clone
end
UserInputService.InputBegan:Connect(function(input, processed)
if processed then
return
end
if input.KeyCode == Enum.KeyCode.LeftShift then
character.Humanoid.WalkSpeed = 0
wait(0.05)
character.Humanoid.WalkSpeed = 100
running = true
while running == true do
character.Animate.run.RunAnim.AnimationId = "rbxassetid://8897379586"
local charClone = CloneMe(game.Players.LocalPlayer.Character)
charClone:FindFirstChild("Humanoid"):Destroy()
charClone.Parent = workspace
for i, v in pairs(charClone:GetDescendants()) do -- getting the clone's parts and fading them out
if v:IsA("MeshPart") or v:IsA("BasePart") or v:IsA("Texture") then
v.Anchored = true
v.CanCollide = false
local info = TweenInfo.new(0.5)
tween = game:GetService("TweenService"):Create(v, info, {Transparency = 1})
tween:Play()
end
end
tween.Completed:Connect(function() -- waiting for it to disappear before destroying
charClone:Destroy()
end)
wait(0.05)
end
end
end)
UserInputService.InputEnded:Connect(function(input, processed)
if processed then
return
end
if input.KeyCode == Enum.KeyCode.LeftShift then
running = false
character.Animate.run.RunAnim.AnimationId = "rbxassetid://8484175485"
character.Humanoid.WalkSpeed = 16
end
end)
all help would be very appreciated.