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

Im cloning a character , and does error because its nil?

hello , im doing a script for script builder im trying to do an anti death and it has to clone the character but it only drops an error when trying to parent it

"20:40:09.345 - local cl = workspace.maumaumaumaumaumau:Clone() cl.Parent = workspace:1: attempt to index local 'cl' (a nil value) 20:40:09.348 - Stack Begin 20:40:09.351 - Script 'local cl = workspace.maumaumaumaumaumau:Clone() cl.Parent = workspace', Line 1 20:40:09.355 - Stack End"

this is the script i used

local cl = workspace.maumaumaumaumaumau:Clone()
cl.Parent = workspace
for i,v in pairs(cl:GetChildren()) do
	if v:IsA("Script") then
		v.Disabled = true
	end
end

3 comments

1

The archiveable property of the character is false by default, which means that you can't clone it.

0

OHHH , Thanks

0

ok

1 answer

✓ Accepted answer

Make it archivable

2 comments

0

shortest answer in Scripting Helpers history xD

0

it was simple lol

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