Advertisement
BEAM21

murder esp script

Jan 25th, 2023
1,180
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 2.10 KB | None | 0 0
  1. function Create(base, team, role, fakedname)
  2.   local bb = Instance.new('BillboardGui', game.CoreGui)
  3.   bb.Adornee = base
  4.   bb.ExtentsOffset = Vector3.new(0,1,0)
  5.   bb.AlwaysOnTop = true
  6.   bb.Size = UDim2.new(0,5,0,5)
  7.   bb.StudsOffset = Vector3.new(0,1,0)
  8.   bb.Name = 'tracker'
  9.   local frame = Instance.new('Frame',bb)
  10.   frame.ZIndex = 10
  11.   frame.BackgroundTransparency = 0.3
  12.   frame.Size = UDim2.new(1,0,1,0)
  13.   local txtlbl = Instance.new('TextLabel',bb)
  14.   txtlbl.ZIndex = 10
  15.   txtlbl.BackgroundTransparency = 1
  16.   txtlbl.Position = UDim2.new(0,0,0,-35)
  17.   txtlbl.Size = UDim2.new(1,0,10,0)
  18.   txtlbl.Font = 'ArialBold'
  19.   txtlbl.FontSize = 'Size12'
  20.   txtlbl.Text = fakedname .. " - " .. role -- Add Role to Name
  21.   txtlbl.TextStrokeTransparency = 0.5
  22.  
  23.   -- Change Color Via Role/Job
  24.   if role == "Murderer" then
  25.     txtlbl.TextColor3 = Color3.new(250,0,0)
  26.     frame.BackgroundColor3 = Color3.new(250,0,0)
  27.   else if role == "Sheriff" then
  28.     txtlbl.TextColor3 = Color3.new(0,0,250)
  29.     frame.BackgroundColor3 = Color3.new(0,0,250)
  30.   end
  31. end
  32.  
  33. end
  34.  
  35. -- Clear our ESP out
  36. function Clear()
  37. for _,v in pairs(game.CoreGui:GetChildren()) do
  38.   if v.Name == 'tracker' and v:isA('BillboardGui') then
  39.     v:Destroy()
  40.   end
  41. end
  42. end
  43.  
  44. -- User checking function
  45. function Find()
  46. Clear()
  47. track = true
  48. spawn(function()
  49. while wait(1) do
  50.   pcall(function() -- Error Catch
  51.   local Players = game.Players:GetChildren() -- Get Current Players
  52.   if track then
  53.     Clear()
  54.     for _,v in pairs(Players) do
  55.       if v.Status.Role.Value == "Murderer" then
  56.         if v and v.Character.Head then
  57.           Create(v.Character.Head, false, "Murderer", v.Status.FakeName.Value)
  58.         end
  59.       else if v.Status.HasRevolver.Value == true then
  60.  
  61.         if v.Character and v.Character.Head then
  62.           Create(v.Character.Head, false, "Sheriff", v.Status.FakeName.Value)
  63.         end
  64.  
  65.       else if v.Character and v.Character.Head then
  66.         Create(v.Character.Head, false, "Bystander", v.Status.FakeName.Value)
  67.       end
  68.     end
  69.   end
  70. end
  71. end
  72. wait(1)
  73. end)
  74. end
  75. end)
  76. end
  77.  
  78. -- Start everything
  79. Clear()
  80. Find()
  81.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement