thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
|
| 18 Jan 2014 07:39 PM |
Bannednoobs = {"thetacahalt", "Random"}
game.Players.PlayerAdded:connect(function(player) for i, v in pairs(Bannednoobs) do if string.lower(player.Name) == string.lower(v) then pcall(function() v:Destroy() end) end end end)
|
|
|
| Report Abuse |
|
|
thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
| |
|
Goulstem
|
  |
| Joined: 04 Jul 2012 |
| Total Posts: 7177 |
|
| |
|
thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
| |
|
thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
|
| 18 Jan 2014 07:54 PM |
| Help me please, the script doesn't work |
|
|
| Report Abuse |
|
|
thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
| |
|
thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
|
| 18 Jan 2014 08:02 PM |
| I don't see nothing wrong with this, however it doesn't work. |
|
|
| Report Abuse |
|
|
| |
|
suremark
|
  |
| Joined: 13 Nov 2007 |
| Total Posts: 6315 |
|
|
| 18 Jan 2014 08:09 PM |
Ipairs is technically more suited, but the difference in logic is nil.
Here's a better way to do what you want:
Bannedlist = {Noob1 = true; Noob2 = true;}
game.Players.PlayerAdded:connect(function(Player) if Bannedlist[Player.Name] then -- pcall(Player.Destroy, Player) (you don't actually need to do this) Player:Destroy() end end) |
|
|
| Report Abuse |
|
|
thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
| |
|
thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
|
| 18 Jan 2014 08:18 PM |
| And, why are you putting them to true, lol. |
|
|
| Report Abuse |
|
|
thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
| |
|
thetacah
|
  |
| Joined: 18 Jan 2013 |
| Total Posts: 16026 |
|
| |
|