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

Why do some names work and others don't?

Why is it that

wait(2)
Workspace.Player1.Torso:Destroy()

works, but

wait(2)
Workspace.Player1.LeftArm:Destroy()

doesn't? They're the same script but with the body part changed. Why does one work and the other not?

I don't want a script on how to make the second one work, I want to know why it doesn't.

1 answer

✓ Accepted answer

You need to put Left Arm In brackets and quotation marks because it's separated by a space. You also remove the dot after it's parent, but not after itself. Like this:

wait(2)
Workspace.Player1["Left Arm"]:Destroy()

2 comments

0

Ohhh, so Left Arm is a String? I assumed it was one word. Thanks!

0

No prob :P

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