Visdude11
|
  |
| Joined: 20 Jun 2010 |
| Total Posts: 42 |
|
|
| 08 Jul 2011 03:05 AM |
Hey guys.
I am an scripter, so I can script great things, but Ive always sucked at endings.
So I wondered how many end`s I need on this script:
game.Players.PlayerAdded:connect(function(Player) if (Player:IsInGroup(222634)==true) and script.Group.Value == true then print(Player.Name.. " is from team green forest") Char:MoveTo(script.Parent.Position) else end
I tried to do that who the output said, so I put in extra end. And after that I added another extra end.
So it was:
game.Players.PlayerAdded:connect(function(Player) if (Player:IsInGroup(222634)==true) and script.Group.Value == true then print(Player.Name.. " is from team green forest") Char:MoveTo(script.Parent.Position) else end end end
Then I tried this:
game.Players.PlayerAdded:connect(function(Player) if (Player:IsInGroup(222634)==true) and script.Group.Value == true then print(Player.Name.. " is from team green forest") Char:MoveTo(script.Parent.Position) else end end end()
and this:
game.Players.PlayerAdded:connect(function(Player) if (Player:IsInGroup(222634)==true) and script.Group.Value == true then print(Player.Name.. " is from team green forest") Char:MoveTo(script.Parent.Position) else end end() end
I cant get it to work, so please help me. |
|
|
| Report Abuse |
|
|
pridak245
|
  |
| Joined: 22 Feb 2009 |
| Total Posts: 5089 |
|
|
| 08 Jul 2011 03:08 AM |
How many blue letters are there? If there 2 then, end end If there are 3 then, end end end Etc. |
|
|
| Report Abuse |
|
|
|
| 08 Jul 2011 03:21 AM |
| i need help with scripting |
|
|
| Report Abuse |
|
|
|
| 08 Jul 2011 03:21 AM |
| i need help wuth scripting!!!!! |
|
|
| Report Abuse |
|
|
|
| 08 Jul 2011 03:22 AM |
| can you help meh with scripting?!? that would be great |
|
|
| Report Abuse |
|
|
OBFAlt
|
  |
| Joined: 06 Jul 2011 |
| Total Posts: 35 |
|
|
| 08 Jul 2011 03:38 AM |
*takes Lua book of Luaness and slaps DD with it*
BE ENLIGHTENED! |
|
|
| Report Abuse |
|
|
Visdude11
|
  |
| Joined: 20 Jun 2010 |
| Total Posts: 42 |
|
|
| 08 Jul 2011 03:49 AM |
I tried it, but it wasnt really helpfull..
The output says: Workspace.Group spawn.spawn:6: ')' expected (to close '(' at line 1) near 'end'
How do I close that? |
|
|
| Report Abuse |
|
|
|
| 08 Jul 2011 03:50 AM |
I doubt it taht you're a great scripter.. -.-
game.Players.PlayerAdded:connect(function(Player) if (Player:IsInGroup(222634)==true) and script.Group.Value == true then print(Player.Name.. " is from team green forest") Char:MoveTo(script.Parent.Position) else end end)
You need a extra parenthesis to close the anonymous function.
|
|
|
| Report Abuse |
|
|
|
| 08 Jul 2011 03:52 AM |
Also, where did you define 'Char' ?
game.Players.PlayerAdded:connect(function(Player) if (Player:IsInGroup(222634)==true) and script.Group.Value == true then print(Player.Name.. " is from team green forest") Player.Character:MoveTo(script.Parent.Position) else print("Not green forest.") end end) |
|
|
| Report Abuse |
|
|
Visdude11
|
  |
| Joined: 20 Jun 2010 |
| Total Posts: 42 |
|
|
| 08 Jul 2011 03:58 AM |
| Thanks, I left roblox for 5 months and got to train scripting again :P |
|
|
| Report Abuse |
|
|