SHARE
TWEET

Nametag Chams [RBX]

Vzurxy Feb 1st, 2019 (edited) 98 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. --[[
  2.  
  3. Set _G.NameESPEnabled to false to disable Nametag Chams.
  4. _G.NameChamsEnabled = false
  5.  
  6. ]]--
  7.  
  8. _G.NameChamsEnabled = true
  9.  
  10. Important = {Players = game:GetService("Players"), Workspace = game:GetService("Workspace"), CoreGui = game:GetService("CoreGui")}
  11.  
  12. function randomString()
  13.     local length = math.random(10,20)
  14.     local array = {}
  15.     for i = 1, length do
  16.         array[i] = string.char(math.random(32, 126))
  17.     end
  18.     return table.concat(array)
  19. end
  20.  
  21. local Color = Color3.new(255, 255, 255)
  22.  
  23. function CreateESP(Player)
  24.  
  25.     if Player ~= nil then
  26.  
  27.         local GetChar = Player.Character
  28.         if not GetChar then return end
  29.  
  30.         local GetHead do
  31.  
  32.             repeat wait() until GetChar:FindFirstChild("Head")
  33.  
  34.         end
  35.         GetHead = GetChar.Head
  36.  
  37.         local BillBoard = Instance.new("BillboardGui", Important.CoreGui)
  38.         BillBoard.Adornee = GetHead
  39.         BillBoard.ExtentsOffset = Vector3.new(0, 1, 0)
  40.         BillBoard.AlwaysOnTop = true
  41.         BillBoard.Size = UDim2.new(0, 5, 0, 5)
  42.         BillBoard.StudsOffset = Vector3.new(0, 3, 0)
  43.         BillBoard.Name = "BillBoard"
  44.  
  45.         local DisplayFrame = Instance.new("Frame", BillBoard)
  46.         DisplayFrame.ZIndex = 10
  47.         DisplayFrame.BackgroundTransparency = 1
  48.         DisplayFrame.Size = UDim2.new(1,0,1,0)
  49.  
  50.         Color = Player.TeamColor.Color
  51.  
  52.         local name = Instance.new("TextLabel", DisplayFrame)
  53.         name.Name = Player.Name
  54.         name.ZIndex = 10
  55.         name.Text = Player.Name
  56.         name.Visible = true
  57.         name.TextColor3 = Color
  58.         name.BackgroundTransparency = 1
  59.         name.Size = UDim2.new(1, 0, 10, 0)
  60.         name.Font = Enum.Font.SourceSansLight
  61.         name.TextSize = 20
  62.         name.TextStrokeTransparency = 0.5
  63.     end
  64. end
  65.  
  66. for i,v in pairs(Important.Players:GetChildren()) do
  67.     Color = v.TeamColor.Color
  68.     CreateESP(v)
  69. end
  70.  
  71. for i,v in pairs(Important.Players:GetChildren()) do
  72.     v.CharacterAdded:Connect(function()
  73.         wait()
  74.         Color = v.TeamColor.Color
  75.         CreateESP(v)
  76.     end)
  77. end
  78.  
  79. function ReClearESP()
  80.     for i,v in pairs(Important.Players:GetChildren()) do
  81.         v.CharacterAdded:Connect(function()
  82.             for i,v in pairs(Important.Players:GetChildren()) do
  83.                 v:GetPropertyChangedSignal("Team"):Connect(function()
  84.                     for i,x in pairs(Important.CoreGui.BillBoard.DisplayFrame:GetChildren()) do
  85.                         if x.Text == v.Name then
  86.                             x:Destroy()
  87.                             wait()
  88.                             CreateESP(v)
  89.                         end
  90.                     end
  91.                 end)
  92.             end
  93.         end)
  94.     end
  95. end
  96.  
  97. function ReESP()
  98.     for i,v in pairs(Important.Players:GetChildren()) do
  99.         v.CharacterAdded:Connect(function()
  100.             wait()
  101.             Color = v.TeamColor.Color
  102.             CreateESP(v)
  103.         end)
  104.     end
  105. end
  106.  
  107. function ClearESP()
  108.     for i,v in pairs(Important.Players:GetChildren()) do
  109.         for i,x in pairs(Important.CoreGui.BillBoard.DisplayFrame:GetChildren()) do
  110.             if x.Text == v.Name then
  111.                 x:Destroy()
  112.             end
  113.         end
  114.     end
  115. end
  116.  
  117. Important.Players.PlayerAdded:Connect(function(Player)
  118.     ClearESP()
  119.     Color = v.TeamColor.Color
  120.     CreateESP(Player)
  121.     ReClearESP()
  122.     ReESP()
  123.     for i,v in pairs(Important.Players:GetChildren()) do
  124.         v:GetPropertyChangedSignal("Team"):Connect(function()
  125.             for i,x in pairs(Important.CoreGui.BillBoard.DisplayFrame:GetChildren()) do
  126.                 if x.Text == v.Name then
  127.                     x:Destroy()
  128.                     wait()
  129.                     CreateESP(v)
  130.                 end
  131.             end
  132.         end)
  133.     end
  134. end)
  135.  
  136. game:GetService("RunService").RenderStepped:Connect(function()
  137.     if _G.NameChamsEnabled == false then
  138.         for i,v in pairs(Important.CoreGui:GetChildren()) do
  139.             if v:IsA("BillboardGui") then
  140.                 v:Destroy()
  141.             end
  142.         end
  143.     end
  144. end)
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top