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

Local PointLight [SOLVED]

How would I make a PointLight, local. Meaning that only the player could see it. I don't think it would go in a PlayerGui, so, any help? Is this even possible?

Thanks!

1 answer

✓ Accepted answer

There are a couple ways of making objects like Parts local.

One way is to parent the object to the Camera in a LocalScript...

Instance.new("Part", workspace.CurrentCamera)

Another interesting method is parenting your local object to a Message in the Character object. Objects parented to the message will be localized to the player. Here's an example, assuming the variable character is a reference to the player's Character.

localSpace = Instance.new("Message", character)
Instance.new("Part", localSpace) -- A local Part

Using one of these methods above, we can simply make a Part local and then parent the PointLight to the local Part to get what you're looking for!

1 comment

0

Thanks! I'll use the first way because it's easier to understand and do.

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