Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local murderweapon = "Knife"
- local sheriffweapon = "Revolver"
- if game.PlaceId == 177052655 then -- renamer for twisted murderer
- sheriffweapon = "Gun"
- end
- workspace.ChildAdded:connect(function(child)
- if child.Name == "GunDrop" then
- local cb = Instance.new("BindableFunction")
- cb.OnInvoke = function(arg)
- if arg == "Get gun!" then
- workspace.GunDrop.CFrame = CFrame.new(game.Players.LocalPlayer.Character.Head.CFrame.X, game.Players.LocalPlayer.Character.Head.CFrame.Y, game.Players.LocalPlayer.Character.Head.CFrame.Z)
- end
- end
- game:GetService("StarterGui"):SetCore("SendNotification",{
- Title = "The sheriff has died!",
- Text = "Grab their gun?",
- Duration = 5,
- Button1 = "Dismiss",
- Button2 = "Get gun!",
- Callback = cb
- })
- end
- end)
- function CreateESPPart(BodyPart,r,g,b)
- local ESPPartparent = BodyPart
- local Box = Instance.new("BoxHandleAdornment")
- Box.Size = BodyPart.Size + Vector3.new(0.1, 0.1, 0.1)
- Box.Name = "ESPPart"
- Box.Adornee = ESPPartparent
- Box.Color3 = Color3.fromRGB(r,g,b)
- Box.AlwaysOnTop = true
- Box.ZIndex = 5
- Box.Transparency = 0.8
- Box.Parent = BodyPart
- end
- function loadCheck(plr,chr)
- if chr:findFirstChild("Humanoid") then
- local part = chr:getChildren()
- for i=1,#part do
- if part[i].ClassName == "Part" then
- CreateESPPart(part[i], 0,255,0)
- spawn(function()
- while true do
- wait(0.1)
- if chr:findFirstChild(murderweapon) or plr.Backpack:findFirstChild(murderweapon) then
- if part[i]:findFirstChild("ESPPart") then
- part[i].ESPPart:remove()
- end
- CreateESPPart(part[i], 255,0,0)
- end
- if chr:findFirstChild(sheriffweapon) or plr.Backpack:findFirstChild(sheriffweapon) then
- if part[i]:findFirstChild("ESPPart") then
- part[i].ESPPart:remove()
- end
- CreateESPPart(part[i], 0,0,255)
- end
- end
- end)
- end
- end
- end
- end
- local player = game.Players:GetChildren()
- for i=1,#player do
- if player[i].Name == game.Players.LocalPlayer.Name then
- else
- player[i].CharacterAdded:Connect(function(character)
- wait(0.5)
- loadCheck(player[i],player[i].Character)
- end)
- loadCheck(player[i],player[i].Character)
- end
- end
- game.Players.PlayerAdded:Connect(function(player)
- player.CharacterAdded:Connect(function(character)
- wait(0.5)
- loadCheck(player,character)
- end)
- end)
Add Comment
Please, Sign In to add comment