I made a small localscript to clone a particle and go to my torso but my friends do not see me with the particle, this happens with any other script.
LocalScript in startepack and particle in replicatedstorage
Because I only see the particle in me and the others do not?
My localscript would look something like this:
1 | player = game.Players.LocalPlayer |
2 | c = player.Character |
3 | tor = c:FindFirstChild( "UpperTorso" ) |
4 |
5 | local en = game.ReplicatedStorage.ParticleEmitter:Clone() |
6 | en.Parent = tor |
FilteringEnabled prevents client changes from replicating to the server. This is a very effective method of preventing hacking, since the hacker can't modify their client and effect the whole server. Roblox has a great visualization of this. With that said, you're going to need to execute your code using a server script. Based on the wording of your question, I assume you only want this done to your character, I have corrected your script to do that. It must be a server script and I recommend putting it in ServerScriptService.
1 | game.Players.PlayerAdded:Connect( function (p) |
2 | p.CharacterAdded:Connect( function (c) |
3 | if p.UserId = = 363446931 then -- This is already your UserId |
4 | local en = game.ReplicatedStorage.ParticleEmitter:Clone() |
5 | en.Parent = c:WaitForChild( "UpperTorso" ) |
6 | end |
7 | end ) |
8 | end ) |
I hope my answer solved your problem! If it did please remember to mark it as correct!