Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to make "special" parts?

Asked by 10 years ago

How do you make a part that is only visible to ONE person. So it is invisible to everyone but a chosen person.

0
Seeing as you tagged "GUIs", I assume you mean how do you make part of a GUI visible to only one person? Vescatur 95 — 10y
0
Part as in brick. EzraNehemiah_TF2 3552 — 10y

2 answers

Log in to vote
1
Answered by
BlueTaslem 18071 Moderation Voter Administrator Community Moderator Super Administrator
10 years ago

The solution is local parts (or in general local objects).

The key to how they work is for the changes in the world made by a LocalScript to just never be sent to the server.

There are two standard ways to do this. The first is done by instancing a "non-replicating" object, such as a Message. For whatever reason, Messages, Hints, Sounds?, Scripts, &c. when created by LocalScripts are not received by the server.

As a result, their descendants will also not appear. So, in a LocalScript, if you parent everything to a Message created by that LocalScript, those things will only be visible to the local player.

If you don't like putting everything into an object created by the script, you can instead use the CurrentCamera, because this instance is not replicated and created for you. (I believe however that the CurrentCamera may be reset by death but I am not sure; this may or may not be a positive architectural difference, since a Message and its contents would persist between lives, and LocalScripts created anywhere would re-run upon respawning, so this must be considered)

Do not expect physics or physics based events to act properly with local objects. Walking into/on them as though they were anchored should work, however.

Alternatively, I believe by enabling "FilteringEnabled," all parts created by LocalScripts would be local. I have not used this method, so I don't know.

0
Got an answer by BlueTaslem! OMG OMG OMG OMG OMG EzraNehemiah_TF2 3552 — 10y
Ad
Log in to vote
-1
Answered by 10 years ago

Local parts! I don't know how to use them that well myself (TEE HEE) but there is a wiki page for it. COMMENCE KNOWLEDGE INTAKE

1
Wat? EzraNehemiah_TF2 3552 — 10y
0
Click the blue link... User#348 0 — 10y
0
If you aren't going to actually answer the question with information, you should at least answer it with a coherent direction. If you aren't going to do either of those things, you shouldn't answer at all. BlueTaslem 18071 — 10y
0
I was trying to direct him to a link where you can find out about local parts, because I do not know how to use them. User#348 0 — 10y
0
Why can't you just research it so I can understand. EzraNehemiah_TF2 3552 — 10y

Answer this question