4zx16

Ban Usernames v1

Oct 24th, 2021 (edited)
269
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.45 KB | None | 0 0
  1. --[[
  2.  || 📜 AUTHOR: @4zx16 || BAN USERNAMES V1 || ROBLOX STUDIO
  3. ]]
  4. local BannedUsernames = {}
  5.  
  6. local function playerIsBanned(Player)
  7.     for i,v in ipairs(BannedUsernames) do
  8.         if Player.Name == v then return true end
  9.     end
  10.     return false
  11. end
  12. game.Players.PlayerAdded:Connect(function(newPlayer)
  13.     if playerIsBanned(newPlayer) then
  14.         newPlayer:Kick("[⛏ Banned]: You cannot join this experience, you're in the ban list! (📃:USERNAME)")
  15.     end
  16. end)
Advertisement
Add Comment
Please, Sign In to add comment