I'm trying to create an afterimages script, but whenever I delete the humanoid, the classic clothing also gets deleted. I've tried a version where the humanoid stays, but for some reason it collides with the player which I don't want, which i found out is because only the head of the clone gets its CanCollide turned off? why isnt every part turning it off?
local function createAfterimage()
local clone = character:Clone()
clone.Humanoid:Destroy()
clone.HumanoidRootPart:Destroy()
for _, part in clone:GetDescendants() do
if part:IsA("BasePart") then
part.Transparency = 0.2
part.CanCollide = false
part.Anchored = true
part.CastShadow = false
game.TweenService:Create(part,TweenInfo.new(AfterimageDuration),{Transparency = 1}):Play()
elseif part:IsA("Decal") then
part.Transparency = 0.2
game.TweenService:Create(part,TweenInfo.new(AfterimageDuration),{Transparency = 1}):Play()
end
end
task.wait(0.05)
clone.Parent = workspace
task.wait(AfterimageDuration)
clone:Destroy()
end