|
| 17 Jun 2013 04:21 PM |
function onPlayerEntered(newPlayer) local l = Instance.new("PointLight") l.Brightness = 2 l.Range = 4 l.Color = Color3.new(188, 202, 58) l:clone().Parent = newPlayer.CharacterTorso end game.Players.ChildAdded:connect(onPlayerEntered)
-- It makes a player's torso light up... any problems? Please make a major edit if I'm wrong.
I tried it and it doesn't work... |
|
|
| Report Abuse |
|
|
|
| 17 Jun 2013 04:22 PM |
game.Players.PlayerAdded:connect(function(plr) local l = Instance.new("PointLight", plr.Character.Torso) l.Brightness = 2 l.Range = 4 l.Color = Color3.new(188, 202, 58) end)
|
|
|
| Report Abuse |
|
|
|
| 17 Jun 2013 04:22 PM |
function onPlayerEntered(newPlayer) local l = Instance.new("PointLight") l.Brightness = 2 l.Range = 4 l.Color = Color3.new(188, 202, 58) l:clone().Parent = newPlayer.Character.Torso end game.Players.ChildAdded:connect(onPlayerEntered) -- You forgot a dot between Character and Torso |
|
|
| Report Abuse |
|
|
|
| 17 Jun 2013 04:23 PM |
Game.Players.PlayerAdded:connect(function(Player) Player.CharacterAdded:connect(function(Character) local Light = Instance.new("PointLight") Light.Brightness = 2 Light.Range = 4 Light.Color = Color3.new(188/255, 202/255, 58/255) repeat wait(1/30) until Character:FindFirstChild("Torso") Light.Parent = Character.Torso end) end) |
|
|
| Report Abuse |
|
|
|
| 17 Jun 2013 04:23 PM |
| perpetual pay attention to bad scripts like this, he names his function (newPlayer) at the top but at bottom it says :connect(onPlayerEntered) |
|
|
| Report Abuse |
|
|
|
| 17 Jun 2013 04:24 PM |
| codies is more effeicant or however ur spell |
|
|
| Report Abuse |
|
|
|
| 17 Jun 2013 04:25 PM |
| Tried the first 2 comments, but no luck |
|
|
| Report Abuse |
|
|
|
| 17 Jun 2013 04:26 PM |
Dude, it was supposed to be onPlayerEntered... you put what is behind (Inside here) Learn2Script |
|
|
| Report Abuse |
|
|
| |
|
| |
|
| |
|
|
| 17 Jun 2013 04:29 PM |
Try increasing the range and brightness.
Game.Players.PlayerAdded:connect(function(Player) Player.CharacterAdded:connect(function(Character) local Light = Instance.new("PointLight") Light.Brightness = 10 Light.Range = 10 Light.Color = Color3.new(188/255, 202/255, 58/255) repeat wait(1/30) until Character:FindFirstChild("Torso") Light.Parent = Character.Torso end) end)
|
|
|
| Report Abuse |
|
|
|
| 17 Jun 2013 04:29 PM |
| yah, but why do I need that? |
|
|
| Report Abuse |
|
|
|
| 17 Jun 2013 04:30 PM |
you are such an idiot get out we try to help you and you and your brain u call a rock thinks it matters what u call a function
|
|
|
| Report Abuse |
|
|
| |
|
| |
|
| |
|
| |
|
|
| 17 Jun 2013 04:40 PM |
| Whoever can fix gets a free gun in my current game |
|
|
| Report Abuse |
|
|
|
| 17 Jun 2013 04:41 PM |
| noone wants ur freemodel guns |
|
|
| Report Abuse |
|
|
Dr01d3k4
|
  |
| Joined: 11 Oct 2007 |
| Total Posts: 17916 |
|
|
| 17 Jun 2013 04:42 PM |
@masterblokz what?
@OP game.Players.PlayerAdded:connect(function(newPlayer) repeat wait(); until (newPlayer.Character); local l = Instance.new("PointLight", newPlayer.Character.Torso); l.Brightness = 2; l.Range = 4; l.Color = Color3.new(188 / 255, 202 / 255, 58 / 255) end);
|
|
|
| Report Abuse |
|
|
|
| 17 Jun 2013 04:44 PM |
| The 2nd comment should work. And also remember that the onPlayerEntered function doesn't work in solo. You can only test this script after you publish it in your places. |
|
|
| Report Abuse |
|
|
| |
|
|
| 17 Jun 2013 04:45 PM |
perp, before you help, learn how to script. god
theres no such thing as a onplayentered function |
|
|
| Report Abuse |
|
|
Joshuats
|
  |
| Joined: 14 May 2008 |
| Total Posts: 847 |
|
|
| 17 Jun 2013 04:45 PM |
@MMOfficial
Are you trying this script out in Tools>Test>Play Solo? If so, that may be the reason why the script may not be working. |
|
|
| Report Abuse |
|
|