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

Particles on click?

Hi I have been wondering how people put particles inside their player when the play clicks the text button can you please help making the script work?

`plr = game.Workspace.Player

function onClicked()
	Instance.new("Fire", plr.Head)
end
script.Parent.MouseButton1Down:connect(onClicked)`

1 comment

1

are the two `'s ment to be there?

1 answer

✓ Accepted answer

You have a ' on the and last line, which is messing it up, remove that. Also, Head isn't inside the player, it's inside the Character. But Player isn't always going to be the player's name. You should use LocalPlayer.

local plr = game.Players.LocalPlayer --Define the player using localplayer

function onClicked()
    Instance.new("Fire", plr.Character.Head)
end

script.Parent.MouseButton1Down:connect(onClicked)

NOTE: This will only work if it's in a localscript!

2 comments

0

where is the other script!?!?!

0

Click advanced objects then localscript while selectig the gui.

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