0% found this document useful (0 votes)
465 views8 pages

Roblox FPS Script Guide

The document contains code for a script that creates a GUI for an FPS game. It defines variables and functions for ESP, aimbot, and other features. The GUI is created with UI elements like frames and labels to display instructions and status updates. Player objects are accessed to get information and apply effects like ESP boxes and aim locking.

Uploaded by

Adrian Maulana
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
465 views8 pages

Roblox FPS Script Guide

The document contains code for a script that creates a GUI for an FPS game. It defines variables and functions for ESP, aimbot, and other features. The GUI is created with UI elements like frames and labels to display instructions and status updates. Player objects are accessed to get information and apply effects like ESP boxes and aim locking.

Uploaded by

Adrian Maulana
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd

local plrs = game:GetService("Players")

local TeamBased = true ; local teambasedswitch = "o"


local presskeytoaim = true; local aimkey = "e"
local raycast = false

local espupdatetime = 5; autoesp = false

local lockaim = true; local lockangle = 5

--function findwat(folder, what)


-- for i, smth in pairs(folder:GetChildren()) do
-- if [Link]([Link](tostring(smth)), [Link](what)) then
-- return smth
-- end
-- end
--end
--
--local plrs = findwat(game, "Players")

local Gui = [Link]("ScreenGui")


local Move = [Link]("Frame")
local Main = [Link]("Frame")
local EspStatus = [Link]("TextLabel")
local st1 = [Link]("TextLabel")
local st1_2 = [Link]("TextLabel")
local st1_3 = [Link]("TextLabel")
local Name = [Link]("TextLabel")
--Properties:
[Link] = "Gui"
[Link] = [Link]:WaitForChild("PlayerGui")

[Link] = "Move"
[Link] = Gui
Move.BackgroundColor3 = [Link](0.0431373, 1, 0.0745098)
[Link] = 0.40000000596046
[Link] = 0
[Link] = [Link](0.005, 0,0.018, 0)
[Link] = [Link](0.28141585, 0, 0.0320388414, 0)

[Link] = "Main"
[Link] = Move
Main.BackgroundColor3 = [Link](0.176471, 0.176471, 0.176471)
[Link] = 0.69999998807907
[Link] = [Link](0, 0, 0.995670795, 0)
[Link] = [Link](1.0000006, 0, 9.79697132, 0)

[Link] = "EspStatus"
[Link] = Main
EspStatus.BackgroundColor3 = [Link](1, 1, 1)
[Link] = 1
[Link] = [Link](0.272955924, 0, 0.161862016, 0)
[Link] = [Link]
[Link] = "Press T to update Esp"
EspStatus.TextColor3 = [Link](0.0431373, 1, 0.0745098)
[Link] = true
[Link] = 14
[Link] = true

[Link] = "st1"
[Link] = Main
st1.BackgroundColor3 = [Link](1, 1, 1)
[Link] = 1
[Link] = [Link](0.271787882, 0, 0, 0)
[Link] = [Link](0.728211343, 0, 0.161862016, 0)
[Link] = [Link]
[Link] = "Press "..aimkey.." to lock on a person inside ur view"
st1.TextColor3 = [Link](0.0431373, 1, 0.0745098)
[Link] = true
[Link] = 14
[Link] = true

st1_2.Name = "st1"
st1_2.Parent = Main
st1_2.BackgroundColor3 = [Link](1, 1, 1)
st1_2.BackgroundTransparency = 1
st1_2.Position = [Link](0, 0, 0.375590861, 0)
st1_2.Size = [Link](0.999999881, 0, 0.161862016, 0)
st1_2.Font = [Link]
st1_2.Text = "Press L to enable esp loop"
st1_2.TextColor3 = [Link](0.0431373, 1, 0.0745098)
st1_2.TextScaled = true
st1_2.TextSize = 14
st1_2.TextWrapped = true

st1_3.Name = "st1"
st1_3.Parent = Main
st1_3.BackgroundColor3 = [Link](1, 1, 1)
st1_3.BackgroundTransparency = 1
st1_3.Position = [Link](0, 0, 0.18558608, 0)
st1_3.Size = [Link](0.999999881, 0, 0.161862016, 0)
st1_3.Font = [Link]
st1_3.Text = "Press O to change team based mode"
st1_3.TextColor3 = [Link](0.0431373, 1, 0.0745098)
st1_3.TextScaled = true
st1_3.TextSize = 14
st1_3.TextWrapped = true
local teambasedstatus = st1_3:Clone()
[Link] = st1_3
[Link] = true
[Link] = [Link](0, 0,0.694, 0)
[Link] = tostring(TeamBased)

[Link] = "Name"
[Link] = Move
Name.BackgroundColor3 = [Link](1, 1, 1)
[Link] = 1
[Link] = [Link](0.838, 0, 0.980000019, 0)
[Link] = [Link]
[Link] = "FPS gui v1.0"
Name.TextColor3 = [Link](0, 0, 0)
[Link] = true
[Link] = 14
[Link] = true
[Link] = [Link]
-- Scripts:

local plrsforaim = {}

local lplr = game:GetService("Players").LocalPlayer


[Link] = true
[Link] = false
[Link] = "Chat"
[Link] = 999

[Link] = [Link]

f = {}
local espforlder

[Link] = function()
--print("ESP ran")
if espforlder then
else
espforlder = [Link]("Folder")
[Link] = [Link]
end
for i, v in pairs(espforlder:GetChildren()) do
v:Destroy()
end
for _, plr in pairs(plrs:GetChildren()) do
if [Link] and [Link] > 0 and [Link] ~=
[Link] then
if TeamBased == true then
if [Link] ~= [Link] then
local e = espforlder:FindFirstChild([Link])
if not e then
--print("Added esp for team based")
local bill = [Link]("BillboardGui",
espforlder)
[Link] = [Link]
[Link] = true
[Link] = [Link](1,0,1,0)
[Link] = [Link]
local Frame = [Link]('Frame',bill)
[Link] = true
Frame.BackgroundColor3 =
[Link](0/255,255/255,0/255)
[Link] = 0
[Link] = 0
[Link] = [Link](.5, .5)
[Link] = [Link] (0.5,0,0.5,0)
[Link] = [Link] (1,0,1,0)
[Link] = 0
[Link]:Connect(function()
bill:Destroy()
end)
end
end
else
local e = espforlder:FindFirstChild([Link])
if not e then
--print("Added esp")
local bill = [Link]("BillboardGui", espforlder)
[Link] = [Link]
[Link] = true
[Link] = [Link](1,0,1,0)
[Link] = [Link]
local Frame = [Link]('Frame',bill)
[Link] = true
Frame.BackgroundColor3 =
[Link](0/255,255/255,0/255)
[Link] = 0
[Link] = 0
[Link] = [Link](.5, .5)
[Link] = [Link] (0.5,0,0.5,0)
[Link] = [Link] (1,0,1,0)
[Link] = 0
[Link]:Connect(function()
bill:Destroy()
end)
end
end

end
end
end
local cam = [Link]

local mouse = lplr:GetMouse()


local switch = false
local key = "k"
local aimatpart = nil
[Link]:Connect(function(a)
if a == "t" then
print("worked1")
[Link]()
elseif a == "u" then
if raycast == true then
raycast = false
else
raycast = true
end
elseif a == "l" then
if autoesp == false then
autoesp = true
else
autoesp = false
end
end
if a == "j" then
if [Link] then
[Link]:Destroy()
end
end
if a == key then
if switch == false then
switch = true
else
switch = false
if aimatpart ~= nil then
aimatpart = nil
end
end
elseif a == teambasedswitch then
if TeamBased == true then
TeamBased = false
[Link] = tostring(TeamBased)
else
TeamBased = true
[Link] = tostring(TeamBased)
end
elseif a == aimkey then
if not aimatpart then
local maxangle = [Link](20)
for i, plr in pairs(plrs:GetChildren()) do
if [Link] ~= [Link] and [Link] and
[Link] and [Link] and [Link] > 1
then
if TeamBased == true then
if [Link] ~= [Link] then
local an = checkfov([Link])
if an < maxangle then
maxangle = an
aimatpart = [Link]
end
end
else
local an = checkfov([Link])
if an < maxangle then
maxangle = an
aimatpart = [Link]
end
print(plr)
end
[Link]:Connect(function()
if [Link] == [Link] or
aimatpart == nil then
aimatpart = nil
end
end)
end
end
else
aimatpart = nil
end
end
end)

function getfovxyz (p0, p1, deg)


local x1, y1, z1 = p0:ToOrientation()
local cf = [Link](p0.p, p1.p)
local x2, y2, z2 = cf:ToOrientation()
--local d = [Link]
if deg then
--return [Link](d(x1-x2), d(y1-y2), d(z1-z2))
else
return [Link]((x1-x2), (y1-y2), (z1-z2))
end
end

function getaimbotplrs()
plrsforaim = {}
for i, plr in pairs(plrs:GetChildren()) do
if [Link] and [Link] and
[Link] > 0 and [Link] ~= [Link] and [Link]
then

if TeamBased == true then


if [Link] ~= [Link] then
local cf =
[Link]([Link].p, [Link].p)
local r = [Link](cf, [Link] * 10000)
local ign = {}
for i, v in
pairs([Link]:GetChildren()) do
if v:IsA("BasePart") then
[Link](ign , v)
end
end
local obj =
[Link]:FindPartOnRayWithIgnoreList(r, ign)
if [Link] == [Link] and [Link] ~=
[Link] then
[Link](plrsforaim, obj)
end
end
else
local cf =
[Link]([Link].p, [Link].p)
local r = [Link](cf, [Link] * 10000)
local ign = {}
for i, v in pairs([Link]:GetChildren())
do
if v:IsA("BasePart") then
[Link](ign , v)
end
end
local obj = [Link]:FindPartOnRayWithIgnoreList(r,
ign)
if [Link] == [Link] and [Link] ~=
[Link] then
[Link](plrsforaim, obj)
end
end

end
end
end

function aimat(part)
[Link] = [Link]([Link].p, [Link].p)
end
function checkfov (part)
local fov = getfovxyz([Link], [Link])
local angle = [Link](fov.X) + [Link](fov.Y)
return angle
end

game:GetService("RunService").RenderStepped:Connect(function()
if aimatpart then
aimat(aimatpart)
if [Link] == [Link] then
aimatpart = nil
end
end

-- if switch == true then


-- local maxangle = 99999
--
-- --print("Loop")
-- if true and raycast == false then
-- for i, plr in pairs(plrs:GetChildren()) do
-- if [Link] ~= [Link] and [Link] and
[Link] and [Link] and [Link] > 1
then
-- if TeamBased then
-- if [Link] ~= [Link] or
[Link] ~= [Link] then
-- local an = checkfov([Link])
-- if an < maxangle then
-- maxangle = an
-- aimatpart = [Link]
-- if an < lockangle then
-- break
-- end
-- end
-- end
-- else
-- local an = checkfov([Link])
-- if an < maxangle then
-- maxangle = an
-- aimatpart = [Link]
-- if an < lockangle then
-- break
-- end
-- end
-- end
--
--
--
--
-- end
-- end
-- elseif raycast == true then
--
-- end

if raycast == true and switch == false and not aimatpart then


getaimbotplrs()
aimatpart = nil
local maxangle = 999
for i, v in ipairs(plrsforaim) do
if [Link] ~= [Link] then
local an = checkfov(v)
if an < maxangle and v ~= [Link] then
maxangle = an
aimatpart = v
print(v:GetFullName())
[Link]:connect(function()
aimatpart = nil
end)
end
end
end

end
end)
delay(0, function()
while wait(espupdatetime) do
if autoesp == true then
pcall(function()
[Link]()
end)
end
end
end)
warn("loaded")

You might also like