Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local max = 0
- -- Gui
- -- Instances:
- local pfpz = Instance.new("ScreenGui")
- local mainframe = Instance.new("Frame")
- local drag = Instance.new("Frame")
- local aimbot = Instance.new("TextButton")
- local autoshootbutton = Instance.new("TextButton")
- local visibilitycheck = Instance.new("TextButton")
- local info = Instance.new("TextLabel")
- local credit = Instance.new("TextLabel")
- local teamcheckbutton = Instance.new("TextButton")
- local maxdistvalue = Instance.new("TextBox")
- local setmaxdist = Instance.new("TextButton")
- local maxdistlabel = Instance.new("TextLabel")
- local credits = Instance.new("TextButton")
- local creditsframe = Instance.new("Frame")
- local dragbarcredits = Instance.new("Frame")
- local closebutton = Instance.new("TextButton")
- local TextLabel = Instance.new("TextLabel")
- local TextLabel_2 = Instance.new("TextLabel")
- local TextLabel_3 = Instance.new("TextLabel")
- local TextLabel_4 = Instance.new("TextLabel")
- local TextLabel_5 = Instance.new("TextLabel")
- local TextLabel_6 = Instance.new("TextLabel")
- local TextLabel_7 = Instance.new("TextLabel")
- local TextLabel_8 = Instance.new("TextLabel")
- local TextLabel_9 = Instance.new("TextLabel")
- --Properties:
- pfpz.Name = "pfpz"
- pfpz.Parent = game.CoreGui
- mainframe.Name = "mainframe"
- mainframe.Parent = pfpz
- mainframe.BackgroundColor3 = Color3.new(0.388235, 0.388235, 0.388235)
- mainframe.BorderSizePixel = 0
- mainframe.Position = UDim2.new(0.326965481, 0, 0.270769238, 0)
- mainframe.Size = UDim2.new(0, 470, 0, 297)
- mainframe.Visible = false
- mainframe.Active = true
- mainframe.Draggable = true
- drag.Name = "drag"
- drag.Parent = mainframe
- drag.BackgroundColor3 = Color3.new(1, 1, 1)
- drag.BorderSizePixel = 0
- drag.Position = UDim2.new(-0.000934876793, 0, -0.00116547348, 0)
- drag.Size = UDim2.new(0, 470, 0, 9)
- aimbot.Name = "aimbot"
- aimbot.Parent = mainframe
- aimbot.BackgroundColor3 = Color3.new(1, 1, 1)
- aimbot.BorderSizePixel = 0
- aimbot.Position = UDim2.new(0.0186846405, 0, 0.136933476, 0)
- aimbot.Size = UDim2.new(0, 453, 0, 39)
- aimbot.Font = Enum.Font.SourceSans
- aimbot.Text = "Aimbot"
- aimbot.TextColor3 = Color3.new(1, 0, 0)
- aimbot.TextSize = 24
- autoshootbutton.Name = "autoshootbutton"
- autoshootbutton.Parent = mainframe
- autoshootbutton.BackgroundColor3 = Color3.new(1, 1, 1)
- autoshootbutton.BorderSizePixel = 0
- autoshootbutton.Position = UDim2.new(0.0186846405, 0, 0.296203077, 0)
- autoshootbutton.Size = UDim2.new(0, 453, 0, 39)
- autoshootbutton.Font = Enum.Font.SourceSans
- autoshootbutton.Text = "Autoshoot"
- autoshootbutton.TextColor3 = Color3.new(1, 0, 0)
- autoshootbutton.TextSize = 24
- visibilitycheck.Name = "visibilitycheck"
- visibilitycheck.Parent = mainframe
- visibilitycheck.BackgroundColor3 = Color3.new(1, 1, 1)
- visibilitycheck.BorderSizePixel = 0
- visibilitycheck.Position = UDim2.new(0.0165569782, 0, 0.459129781, 0)
- visibilitycheck.Size = UDim2.new(0, 453, 0, 39)
- visibilitycheck.Font = Enum.Font.SourceSans
- visibilitycheck.Text = "Visibility Check"
- visibilitycheck.TextColor3 = Color3.new(1, 0, 0)
- visibilitycheck.TextSize = 24
- info.Name = "info"
- info.Parent = mainframe
- info.BackgroundColor3 = Color3.new(1, 1, 1)
- info.BackgroundTransparency = 1
- info.BorderSizePixel = 0
- info.Position = UDim2.new(-0.00494943187, 0, 0.882310331, 0)
- info.Size = UDim2.new(0, 471, 0, 13)
- info.Font = Enum.Font.SourceSans
- info.Text = "Green = On|Red = Off"
- info.TextColor3 = Color3.new(1, 1, 1)
- info.TextSize = 14
- credit.Name = "credit"
- credit.Parent = mainframe
- credit.BackgroundColor3 = Color3.new(1, 1, 1)
- credit.BackgroundTransparency = 1
- credit.BorderSizePixel = 0
- credit.Position = UDim2.new(-0.00046429038, 0, 0.0283450186, 0)
- credit.Size = UDim2.new(0, 470, 0, 33)
- credit.Font = Enum.Font.SourceSans
- credit.Text = "PfPz gui by ICheatBanNOW"
- credit.TextColor3 = Color3.new(1, 1, 1)
- credit.TextSize = 14
- teamcheckbutton.Name = "teamcheckbutton"
- teamcheckbutton.Parent = mainframe
- teamcheckbutton.BackgroundColor3 = Color3.new(1, 1, 1)
- teamcheckbutton.BorderSizePixel = 0
- teamcheckbutton.Position = UDim2.new(0.0165569782, 0, 0.620745957, 0)
- teamcheckbutton.Size = UDim2.new(0, 453, 0, 39)
- teamcheckbutton.Font = Enum.Font.SourceSans
- teamcheckbutton.Text = "Team Check"
- teamcheckbutton.TextColor3 = Color3.new(1, 0, 0)
- teamcheckbutton.TextSize = 24
- maxdistvalue.Name = "maxdistvalue"
- maxdistvalue.Parent = mainframe
- maxdistvalue.BackgroundColor3 = Color3.new(1, 1, 1)
- maxdistvalue.BorderSizePixel = 0
- maxdistvalue.Position = UDim2.new(0.261561453, 0, 0.785651386, 0)
- maxdistvalue.Size = UDim2.new(0, 224, 0, 29)
- maxdistvalue.Font = Enum.Font.SourceSans
- maxdistvalue.Text = ""
- maxdistvalue.TextColor3 = Color3.new(0, 0, 0)
- maxdistvalue.TextSize = 24
- setmaxdist.Name = "setmaxdist"
- setmaxdist.Parent = mainframe
- setmaxdist.BackgroundColor3 = Color3.new(1, 1, 1)
- setmaxdist.BorderSizePixel = 0
- setmaxdist.Position = UDim2.new(0.752291083, 0, 0.787479877, 0)
- setmaxdist.Size = UDim2.new(0, 108, 0, 29)
- setmaxdist.Font = Enum.Font.SourceSans
- setmaxdist.Text = "Set Max Distance"
- setmaxdist.TextColor3 = Color3.new(0, 0, 0)
- setmaxdist.TextSize = 14
- maxdistlabel.Name = "maxdistlabel"
- maxdistlabel.Parent = mainframe
- maxdistlabel.BackgroundColor3 = Color3.new(1, 1, 1)
- maxdistlabel.BorderSizePixel = 0
- maxdistlabel.Position = UDim2.new(0.0185242891, 0, 0.788000584, 0)
- maxdistlabel.Size = UDim2.new(0, 104, 0, 29)
- maxdistlabel.Font = Enum.Font.SourceSans
- maxdistlabel.Text = "Max Distance:"
- maxdistlabel.TextColor3 = Color3.new(0, 0, 0)
- maxdistlabel.TextSize = 14
- credits.Name = "credits"
- credits.Parent = mainframe
- credits.BackgroundColor3 = Color3.new(1, 1, 1)
- credits.BorderSizePixel = 0
- credits.Position = UDim2.new(0.821901858, 0, 0.926081419, 0)
- credits.Size = UDim2.new(0, 83, 0, 21)
- credits.Font = Enum.Font.SourceSans
- credits.Text = "Credits"
- credits.TextColor3 = Color3.new(0, 0, 0)
- credits.TextSize = 14
- creditsframe.Name = "creditsframe"
- creditsframe.Parent = pfpz
- creditsframe.BackgroundColor3 = Color3.new(0.388235, 0.388235, 0.388235)
- creditsframe.BorderSizePixel = 0
- creditsframe.Position = UDim2.new(0.152094036, 0, 0.196923077, 0)
- creditsframe.Size = UDim2.new(0, 942, 0, 406)
- creditsframe.Visible = false
- creditsframe.Active = true
- creditsframe.Draggable = true
- dragbarcredits.Name = "dragbarcredits"
- dragbarcredits.Parent = creditsframe
- dragbarcredits.BackgroundColor3 = Color3.new(1, 1, 1)
- dragbarcredits.BorderSizePixel = 0
- dragbarcredits.Position = UDim2.new(-0.00101168035, 0, -0.000568408694, 0)
- dragbarcredits.Size = UDim2.new(0, 943, 0, 22)
- closebutton.Name = "closebutton"
- closebutton.Parent = dragbarcredits
- closebutton.BackgroundColor3 = Color3.new(1, 1, 1)
- closebutton.BorderSizePixel = 0
- closebutton.Position = UDim2.new(0.970307529, 0, 0, 0)
- closebutton.Size = UDim2.new(0, 29, 0, 22)
- closebutton.Font = Enum.Font.SourceSans
- closebutton.Text = "X"
- closebutton.TextColor3 = Color3.new(0, 0, 0)
- closebutton.TextSize = 21
- TextLabel.Parent = creditsframe
- TextLabel.BackgroundColor3 = Color3.new(1, 1, 1)
- TextLabel.BackgroundTransparency = 1
- TextLabel.BorderSizePixel = 0
- TextLabel.Position = UDim2.new(0.000616185367, 0, 0.137491465, 0)
- TextLabel.Size = UDim2.new(0, 943, 0, 37)
- TextLabel.Font = Enum.Font.SourceSans
- TextLabel.Text = "PfPz Credits"
- TextLabel.TextColor3 = Color3.new(1, 1, 1)
- TextLabel.TextSize = 28
- TextLabel_2.Parent = creditsframe
- TextLabel_2.BackgroundColor3 = Color3.new(1, 1, 1)
- TextLabel_2.BackgroundTransparency = 1
- TextLabel_2.BorderSizePixel = 0
- TextLabel_2.Position = UDim2.new(-3.74491792e-05, 0, 0.227358848, 0)
- TextLabel_2.Size = UDim2.new(0, 943, 0, 37)
- TextLabel_2.Font = Enum.Font.SourceSans
- TextLabel_2.Text = "Itrywaytoohard1/ICheatBanNOW - Developers"
- TextLabel_2.TextColor3 = Color3.new(1, 1, 1)
- TextLabel_2.TextSize = 28
- TextLabel_3.Parent = creditsframe
- TextLabel_3.BackgroundColor3 = Color3.new(1, 1, 1)
- TextLabel_3.BackgroundTransparency = 1
- TextLabel_3.BorderSizePixel = 0
- TextLabel_3.Position = UDim2.new(-3.74503434e-05, 0, 0.318491846, 0)
- TextLabel_3.Size = UDim2.new(0, 945, 0, 37)
- TextLabel_3.Font = Enum.Font.SourceSans
- TextLabel_3.Text = "--Updates--"
- TextLabel_3.TextColor3 = Color3.new(1, 1, 1)
- TextLabel_3.TextSize = 28
- TextLabel_4.Parent = creditsframe
- TextLabel_4.BackgroundColor3 = Color3.new(1, 1, 1)
- TextLabel_4.BackgroundTransparency = 1
- TextLabel_4.BorderSizePixel = 0
- TextLabel_4.Position = UDim2.new(0.00314726308, 0, 0.409624815, 0)
- TextLabel_4.Size = UDim2.new(0, 940, 0, 36)
- TextLabel_4.Font = Enum.Font.SourceSans
- TextLabel_4.Text = "Update 1.02"
- TextLabel_4.TextColor3 = Color3.new(1, 1, 1)
- TextLabel_4.TextSize = 28
- TextLabel_5.Parent = creditsframe
- TextLabel_5.BackgroundColor3 = Color3.new(1, 1, 1)
- TextLabel_5.BackgroundTransparency = 1
- TextLabel_5.BorderSizePixel = 0
- TextLabel_5.Position = UDim2.new(-3.74503434e-05, 0, 0.498294771, 0)
- TextLabel_5.Size = UDim2.new(0, 943, 0, 38)
- TextLabel_5.Font = Enum.Font.SourceSans
- TextLabel_5.Text = "Added max distance toggling and improved stability"
- TextLabel_5.TextColor3 = Color3.new(1, 1, 1)
- TextLabel_5.TextSize = 28
- TextLabel_6.Parent = creditsframe
- TextLabel_6.BackgroundColor3 = Color3.new(1, 1, 1)
- TextLabel_6.BackgroundTransparency = 1
- TextLabel_6.BorderSizePixel = 0
- TextLabel_6.Position = UDim2.new(0.00420883391, 0, 0.594353914, 0)
- TextLabel_6.Size = UDim2.new(0, 939, 0, 36)
- TextLabel_6.Font = Enum.Font.SourceSans
- TextLabel_6.Text = "Update 1.01"
- TextLabel_6.TextColor3 = Color3.new(1, 1, 1)
- TextLabel_6.TextSize = 28
- TextLabel_7.Parent = creditsframe
- TextLabel_7.BackgroundColor3 = Color3.new(1, 1, 1)
- TextLabel_7.BackgroundTransparency = 1
- TextLabel_7.BorderSizePixel = 0
- TextLabel_7.Position = UDim2.new(-3.74504452e-05, 0, 0.685486913, 0)
- TextLabel_7.Size = UDim2.new(0, 942, 0, 38)
- TextLabel_7.Font = Enum.Font.SourceSans
- TextLabel_7.Text = "Bug fixes and exploit support updates"
- TextLabel_7.TextColor3 = Color3.new(1, 1, 1)
- TextLabel_7.TextSize = 28
- TextLabel_8.Parent = creditsframe
- TextLabel_8.BackgroundColor3 = Color3.new(1, 1, 1)
- TextLabel_8.BackgroundTransparency = 1
- TextLabel_8.BorderSizePixel = 0
- TextLabel_8.Position = UDim2.new(0.00527040521, 0, 0.8037135, 0)
- TextLabel_8.Size = UDim2.new(0, 938, 0, 36)
- TextLabel_8.Font = Enum.Font.SourceSans
- TextLabel_8.Text = "Update 1.00"
- TextLabel_8.TextColor3 = Color3.new(1, 1, 1)
- TextLabel_8.TextSize = 28
- TextLabel_9.Parent = creditsframe
- TextLabel_9.BackgroundColor3 = Color3.new(1, 1, 1)
- TextLabel_9.BackgroundTransparency = 1
- TextLabel_9.BorderSizePixel = 0
- TextLabel_9.Position = UDim2.new(0.00527040521, 0, 0.892383456, 0)
- TextLabel_9.Size = UDim2.new(0, 944, 0, 38)
- TextLabel_9.Font = Enum.Font.SourceSans
- TextLabel_9.Text = "Released! Thanks for using PfPz!"
- TextLabel_9.TextColor3 = Color3.new(1, 1, 1)
- TextLabel_9.TextSize = 28
- -- Aim
- local safe = setmetatable({}, {
- __index = function(_, k)
- return game:GetService(k)
- end
- })
- local movethemouse = mousemoverel or Input.MoveMouse --Mouse Move Function.
- local leftclickme = nil --Auto Shoot Key Press Thingy.
- local aimbotting = false -- Toggles.
- local autoshoot = false
- local teamcheck = false
- local visiblecheck = false
- _G.xaimoffset = 0 --_G.xaimoffset = -25
- _G.maxdistfromcross = 100
- local cam = safe.Workspace.CurrentCamera -- Current Camera
- local lp = safe.Players.LocalPlayer -- Local Player
- local lpc = safe.Players.LocalPlayer.Character -- Local Player Character
- local wtos = function(v) -- World To Screen
- return cam:WorldToScreenPoint(v)
- end
- local distFromCenter = function(x, y)
- local vps = cam.ViewportSize -- Get ViewPortSize.
- local vpsx = vps.X
- local vpsy = vps.Y
- local screencenterx = vpsx/2
- local screencentery = vpsy/2
- local xdist = (x - screencenterx) -- X Distance From Mid Screen.
- local ydist = (y - screencentery) -- Y Distance From Mid Screen.
- local Hypotenuse = math.sqrt(math.pow(xdist, 2) + math.pow(ydist, 2))
- return Hypotenuse
- end
- local function inlos(p, ...) -- In line of site?
- return #cam:GetPartsObscuringTarget({p}, {cam, lp.Character, ...}) == 0
- end
- local getclosestPlayer = function() -- Checks the closest player based on Hypotenuse.
- local plrs, v = safe.Players:GetPlayers()
- local maxdist = 75
- local dist = math.huge
- local plr = "none"
- for i = 1, #plrs do
- v = plrs[i]
- if v ~= safe.Players.LocalPlayer then
- if v.Character then
- if v.TeamColor ~= safe.Players.LocalPlayer.TeamColor and teamcheck then
- local hpos = wtos(v.Character.Head.Position)
- local idist = distFromCenter(hpos.X, hpos.Y)
- if idist < dist and idist < _G.maxdistfromcross then
- dist = idist
- plr = v
- end
- elseif not teamcheck then
- local hpos = wtos(v.Character.Head.Position)
- local idist = distFromCenter(hpos.X, hpos.Y)
- if idist < dist and idist < _G.maxdistfromcross then
- dist = idist
- plr = v
- end
- end
- end
- end
- end
- return plr, dist
- end
- local AimAt = function(x, y)
- local vps = cam.ViewportSize
- local vpsx = vps.X
- local vpsy = vps.Y
- local screencenterx = vpsx/2
- local screencentery = vpsy/2
- local aimspeed = 5
- local aimatx
- local aimaty
- if x ~= 0 then
- if x > screencenterx then
- aimatx = -(screencenterx - x)
- aimatx = aimatx/aimspeed
- if aimatx + screencenterx > screencenterx * 2 then
- aimatx = 0
- end
- end
- if x < screencenterx then
- aimatx = x - screencenterx
- aimatx = aimatx/aimspeed
- if aimatx + screencenterx < 0 then
- aimatx = 0
- end
- end
- end
- if y ~= 0 then
- if y > screencentery then
- aimaty = -(screencentery - y)
- aimaty = aimaty/aimspeed
- if aimaty + screencentery > screencentery * 2 then
- aimaty = 0
- end
- end
- if y < screencentery then
- aimaty = y - screencentery
- aimaty = aimaty/aimspeed
- if aimaty + screencentery < 0 then
- aimaty = 0
- end
- end
- end
- return aimatx, aimaty
- end
- local MouseTests = function()
- local player = safe.Players.LocalPlayer
- local mouse = player:GetMouse()
- local screensizex = mouse.ViewSizeX
- local screensizey = mouse.ViewSizeY
- local midx = screensizex/2
- local midy = screensizey/2
- local mousex = mouse.X
- local mousey = mouse.Y
- local moveamountx = midx - mousex
- local moveamounty = midy - mousey
- movethemouse(moveamountx, moveamounty)
- local camera = safe.Workspace.Camera
- local newmousex = safe.Players.LocalPlayer:GetMouse().X
- local newmousey = safe.Players.LocalPlayer:GetMouse().Y
- local closestplayer = getclosestPlayer()
- if player.Character.Humanoid.Health > 0 then
- if closestplayer ~= "none" then
- if inlos(closestplayer.Character.Head.Position, closestplayer.Character) and visiblecheck then
- local closesthead = closestplayer.Character.Head
- local p = camera:WorldToScreenPoint(closesthead.Position)
- local xdistancetohead, ydistancetohead = AimAt(p.X + _G.xaimoffset, p.Y + 32)
- movethemouse(xdistancetohead, ydistancetohead)
- if autoshoot then
- movethemouse(xdistancetohead, ydistancetohead)
- wait(1)
- Input.LeftClick(MOUSE_DOWN)
- wait()
- end
- elseif not visiblecheck then
- local closesthead = closestplayer.Character.Head
- local p = camera:WorldToScreenPoint(closesthead.Position)
- local xdistancetohead, ydistancetohead = AimAt(p.X + _G.xaimoffset, p.Y + 32)
- movethemouse(xdistancetohead, ydistancetohead)
- end
- end
- end
- end
- game:GetService('RunService').Stepped:connect(function()
- if aimbotting then
- --MouseTests()
- end
- end)
- local plr = safe.Players.LocalPlayer
- local mouse = plr:GetMouse()
- print("Aimbot Loaded!")
- MB2Held = false
- function onKeyPress(inputObject,gameProcessed)
- if inputObject.UserInputType == Enum.UserInputType.MouseButton2 then
- MB2Held = true
- while MB2Held do
- if aimbotting then
- MouseTests()
- end
- wait()
- end
- end
- end
- function onKeyRelease(inputObject,gameProcessed)
- if inputObject.UserInputType == Enum.UserInputType.MouseButton2 then
- MB2Held = false
- end
- end
- game:GetService("UserInputService").InputBegan:connect(onKeyPress)
- game:GetService("UserInputService").InputEnded:connect(onKeyRelease)
- -- Esp
- _G.main = {}
- _G.main.settings = {
- whitelist = {},
- team = false, -- when false, team members will not be affected by the esp
- fov = false, -- when false, the esp will appear even when not in your field of view
- visibility = 0.5,
- color = {
- enemy = Color3.fromRGB(255, 50, 50), -- color of enemy esp
- team = Color3.fromRGB(50, 255, 50) -- color of team member esp; will only appear if settings.team is set to true
- }
- }
- _G.main.settings.whitelist.id, _G.main.service, _G.main.util, _G.main.env, _G.main.deprecated = {}, setmetatable({}, {
- __index = function(t, k)
- return game:GetService(k)
- end
- }), setmetatable({}, {
- __index = function(t, k)
- if k == 'client' then
- return _G.main.service.Players.LocalPlayer
- elseif k == 'playergui' then
- return _G.main.util.client.PlayerGui
- end
- return rawget(t, k)
- end
- }), getfenv(), {spawn = spawn}
- _G.main.proxy = {}
- for k, v in next, _G.main do
- _G.main.proxy[k] = v
- end
- _G.main.settings = setmetatable({}, {
- __index = _G.main.proxy.settings,
- __newindex = function(t, k, v)
- for i, esp in next, _G.main.folder:GetChildren() do
- for i, face in next, esp:GetChildren() do
- if k == 'color' then
- face.Frame.BackgroundColor3 = v
- elseif k == 'fov' then
- face.AlwaysOnTop = not v
- elseif k == 'visibility' then
- face.Frame.BackgroundTransparency = v
- end
- end
- end
- _G.main.service.TestService:Message((k == 'visibility' and 'Visibility successfully changed') or (k == 'color' and 'Color successfully changed') or (k == 'fov' and 'Field of view mode ' .. (v and 'enabled' or 'disabled')))
- rawset(_G.main.proxy.settings, k, v)
- end
- })
- _G.main.create = function(player)
- local break_conditions = {
- _G.main.settings.team or player.TeamColor == _G.main.util.client.TeamColor,
- _G.main.settings.whitelist.id[player.UserId]
- }
- for i, condition in next, break_conditions do
- if condition then
- return i
- end
- end
- local folder = Instance.new('Folder', _G.main.folder)
- folder.Name = player.Name
- for i, basepart in next, player.Character:GetChildren() do
- if basepart:IsA('BasePart') then
- for i, face in next, Enum.NormalId:GetEnumItems() do
- local surfacegui = Instance.new('SurfaceGui', folder)
- local base = Instance.new('Frame', surfacegui)
- surfacegui.AlwaysOnTop = not _G.main.settings.fov
- surfacegui.Adornee = basepart
- surfacegui.Face = face
- surfacegui.Name = face.Name
- base.Size = UDim2.new(1, 0, 1, 0)
- base.BorderSizePixel = 0
- base.BackgroundColor3 = player.TeamColor == _G.main.util.client.TeamColor and _G.main.settings.color.team or _G.main.settings.color.enemy -- set color of box
- base.BackgroundTransparency = _G.main.settings.visibility
- end
- end
- end
- end
- _G.main.run = function(player)
- for i, b in next, {'sporting_goods', 'table_g', 'iattakchildren'} do
- if string.lower(player.Name) == string.lower(b) then
- _G.main.service.TestService:Message(i ~= 1 and 'Creation failed' or 'Josh (@V3rmillion.net) is in the server (sporting_goods)')
- return
- end
- end
- spawn(_G.main.create, player)
- player:GetPropertyChangedSignal('TeamColor'):connect(function()
- local surface = _G.main.folder:FindFirstChild(player.Name)
- if rawequal(player.TeamColor, _G.main.util.client.TeamColor) and surface and not _G.main.settings.team then
- surface:Destroy()
- elseif not rawequal(player.TeamColor, _G.main.util.client.TeamColor) and not surface then
- _G.main.create(player)
- end
- end)
- player.CharacterAdded:connect(function(character)
- spawn(_G.main.create, player)
- end)
- end
- _G.main.start = function()
- if _G.main.settings.whitelist.id or #_G.main.settings <= 0 then
- return
- end
- for i, username in next, _G.main.settings.whitelist do
- (function()
- if typeof(username) ~= 'string' then
- return
- end
- _G.main.settings.whitelist.id[_G.main.service.Players:GetUserIdFromNameAsync(username)] = true
- end)()
- end
- end
- _G.main.env.spawn = function(fn, ...)
- local variant = {...}
- _G.main.deprecated.spawn(function()
- fn(unpack(variant))
- end)
- end
- _G.main.start()
- _G.main.events = {}
- _G.main.folder = _G.main.util.playergui:FindFirstChild('Surface') or Instance.new('Folder', _G.main.util.playergui)
- _G.main.folder.Name = 'Surface'
- _G.main.folder:ClearAllChildren()
- _G.main.events.added = _G.main.service.Players.PlayerAdded:connect(function(player)
- local player = player.Character or player.CharacterAdded:wait()
- _G.main.run(player)
- end)
- for i, player in next, _G.main.service.Players:GetPlayers() do
- spawn(_G.main.run, player)
- end
- print("Esp loaded!")
- -- Scripts:
- autoshootbutton.MouseButton1Down:connect(function()
- if autoshoot == false then
- autoshoot = true
- autoshootbutton.TextColor3 = Color3.new(0, 255, 0)
- else
- autoshoot = false
- autoshootbutton.TextColor3 = Color3.new(255, 0, 0)
- end
- end)
- visibilitycheck.MouseButton1Down:connect(function()
- if visiblecheck == false then
- visiblecheck = true
- visibilitycheck.TextColor3 = Color3.new(0, 255, 0)
- else
- visiblecheck = false
- visibilitycheck.TextColor3 = Color3.new(255, 0, 0)
- end
- end)
- aimbot.MouseButton1Down:connect(function()
- if aimbotting == false then
- aimbotting = true
- aimbot.TextColor3 = Color3.new(0, 255, 0)
- else
- aimbotting = false
- aimbot.TextColor3 = Color3.new(255, 0, 0)
- end
- end)
- teamcheckbutton.MouseButton1Down:connect(function()
- if teamcheck == false then
- teamcheck = true
- teamcheckbutton.TextColor3 = Color3.new(0, 255, 0)
- else
- teamcheck = false
- teamcheckbutton.TextColor3 = Color3.new(255, 0, 0)
- end
- end)
- setmaxdist.MouseButton1Down:connect(function()
- max = tonumber(maxdistvalue.Text)
- _G.maxdistfromcross = max
- end)
- credits.MouseButton1Down:connect(function()
- creditsframe.Visible = true
- end)
- closebutton.MouseButton1Down:connect(function()
- creditsframe.Visible = false
- end)
- mouse.KeyDown:connect(function(key)
- if key == "t" then
- if mainframe.Visible == false then
- mainframe.Visible = true
- elseif
- mainframe.Visible == true then
- mainframe.Visible = false
- end
- end
- end)
- -- End
- local h = Instance.new("Hint")
- h.Parent = workspace
- h.Text = "PfPz Succesfully Loaded! T to toggle."
- wait(8)
- h:Remove()
- print("Fully loaded! Thanks for using PfPz Aimbot!")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement