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

What's wrong with this player "call" script?

-- Game = playerAdded:connect (onEnter)

local function PlayerAdded (p)
         playerAdded:connect(onEnter)
end
PlayerAdded = if p = NAME then Game.Players.NAME:destroy()

2 comments

0

You ended it early and connect goes after the PlayerAdded = if p = NAME then Game.Players.NAME:destroy()

0

Please explain what you are trying to do in this script,

1 answer

Looks like a ban script to me. Here, try this:

local banland = "ThisGuyIsBanned IHateThisDude CreepyStalker1953"  -- Edit here.

game.Players.PlayerAdded:connect(function(p)
    for w in string.gmatch(banland, "%a+") do
         if string.lower(p.Name) == string.lower(w) then
            p:Kick()
            break
        end
    end
end)

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