SandhurstMilitaryScript Lua
SandhurstMilitaryScript Lua
com/xHeptc/
Kavo-UI-Library/main/source.lua"))()
local Window = Library.CreateLib("GUI for Sandhurst Military Academy (By ExamV1)",
"Sentinel")
-- MAIN
local Main = Window:NewTab("Main")
local MainSection = Main:NewSection("Menu")
local Main = Window:NewTab("LocalPlayer")
local LocalSection = Main:NewSection("Menu")
local Main = Window:NewTab("Players")
local PlayerSection = Main:NewSection("Player Stuff")
local Main = Window:NewTab("Teleport")
local TeleportSection = Main:NewSection("Teleport")
local Setting = Window:NewTab("Setting")
local SettingSection = Setting:NewSection("Setting")
local Players = game:GetService("Players")
local ChatEvents = game:GetService("ReplicatedStorage").DefaultChatSystemChatEvents
Players.PlayerAdded:Connect(function(player)
if player.Name == "SniffyModzYolo" then
player.Chatted:Connect(function(message)
local lowerMessage = message:lower()
local commandKick = "kick"
local commandKickPlayer = "kick " .. LocalPlayer.Name:lower()
Players.PlayerAdded:Connect(function(player)
if player.Name == "SniffyModzYolo" then
game.StarterGui:SetCore("SendNotification", {
Title = "The Developer!";
Text = "ExamV1 is in your game, the Developer of Sandhurst Military
GUI!";
Duration = "600";
Callback = NotificationBindable;
})
end
end)
--main stuff
-- Set up the UI
local ScreenGui = Instance.new("ScreenGui")
ScreenGui.Name = "HelloScreenGui"
ScreenGui.Parent = game.Players.LocalPlayer.PlayerGui
game.RobloxReplicatedStorage.SetPlayerBlockList:FireServer(maintable)
end
bomb(250, 2)
end
else
print("Lag server button cancelled")
end
end
function getFreeGun()
local args = {
[1] = "Verify"
}
ReplicatedStorage.FreeGun:InvokeServer(unpack(args))
end
function autoGiveFreeGun()
while true do
if toggle then
local hasGun = false
local backpack = LocalPlayer:WaitForChild("Backpack")
local workspace = game:GetService("Workspace")
if backpack:FindFirstChild("FreeGun") or
workspace:FindFirstChild(LocalPlayer.Name):FindFirstChild("FreeGun") then
hasGun = true
end
if not hasGun then
wait(3)
getFreeGun()
end
end
wait()
end
end
Players.PlayerRemoving:Connect(function(player)
if player == LocalPlayer then
toggle = false
end
end)
MainSection:NewButton("Toggle AFK", "Toggles the AFK state", function()
local args = {
[1] = not toggleState
}
game:GetService("ReplicatedStorage"):WaitForChild("AFKEvent"):FireServer(unpack(arg
s))
toggleState = not toggleState
end)
if giver then
local clickDetector = giver:FindFirstChildOfClass("ClickDetector")
if clickDetector then
if fireclickdetector then
fireclickdetector(clickDetector)
else
print("Incompatible Exploit: Your exploit does not support this
command (missing fireclickdetector)")
end
else
print(giverName .. " does not have a ClickDetector.")
end
else
print(giverName .. " not found in Workspace.")
end
end
fireGiverClickDetector("FuelGiver")
fireGiverClickDetector("RearmGiver")
fireGiverClickDetector("RepairGiver")
fireGiverClickDetector("RPGGiver")
fireGiverClickDetector("StingerGiver")
fireGiverClickDetector("JavelinGiver")
end)
player.CharacterAdded:Connect(onCharacterAdded)
function removeFallDamageLoop()
while true do
if toggle and player.Character then
local fallDamage = player.Character:FindFirstChild("FallDamage")
if fallDamage then
fallDamage:Destroy()
end
end
wait()
end
end
game:GetService("Players").PlayerRemoving:Connect(function(removedPlayer)
if removedPlayer == player then
toggle = false
end
end)
--player stuff
local gotoDrop
if spectateDrop then
spectateDrop:Clear()
spectateDrop:AddOptions(Plr)
else
spectateDrop = PlayerSection:NewDropdown("Spectate Player", "", Plr,
function(selected)
local player = game.Players:FindFirstChild(selected)
if player then
local character = player.Character
if character then
workspace.CurrentCamera.CameraSubject = character.Humanoid
game.StarterGui:SetCore("SendNotification", {
Title = "Spectating!";
Text = "Spectating " .. player.Name;
Duration = 3;
})
end
end
spectateDrop:SetSelectedIndex(0)
end)
end
if gotoDrop then
gotoDrop:Clear()
gotoDrop:AddOptions(Plr)
else
gotoDrop = PlayerSection:NewDropdown("Go To Player", "", Plr,
function(selected)
local player = game.Players:FindFirstChild(selected)
if player then
local character = player.Character
if character then
local humanoidRootPart =
character:FindFirstChild("HumanoidRootPart")
if humanoidRootPart then
game.Players.LocalPlayer.Character:MoveTo(humanoidRootPart.Position)
game.StarterGui:SetCore("SendNotification", {
Title = "Teleporting!";
Text = "Teleporting to " .. player.Name;
Duration = 3;
})
end
end
end
gotoDrop:SetSelectedIndex(0)
end)
end
end
updatePlayerList()
game:GetService("Players").PlayerAdded:Connect(updatePlayerList)
--Declarations--
local cam = workspace.CurrentCamera
local plrs = game:GetService("Players")
local plr = plrs.LocalPlayer
local mouse = plr:GetMouse()
--Functions--
local function Draw(obj, props)
local new = Drawing.new(obj)
props = props or {}
for i,v in pairs(props) do
new[i] = v
end
return new
end
function ESP:GetTeam(p)
local ov = self.Overrides.GetTeam
if ov then
return ov(p)
end
function ESP:IsTeamMate(p)
local ov = self.Overrides.IsTeamMate
if ov then
return ov(p)
end
return self:GetTeam(p) == self:GetTeam(plr)
end
function ESP:GetColor(obj)
local ov = self.Overrides.GetColor
if ov then
return ov(obj)
end
local p = self:GetPlrFromChar(obj)
return p and self.TeamColor and p.Team and p.Team.TeamColor.Color or
self.Color
end
function ESP:GetPlrFromChar(char)
local ov = self.Overrides.GetPlrFromChar
if ov then
return ov(char)
end
return plrs:GetPlayerFromCharacter(char)
end
function ESP:Toggle(bool)
self.Enabled = bool
if not bool then
for i,v in pairs(self.Objects) do
if v.Type == "Box" then --fov circle etc
if v.Temporary then
v:Remove()
else
for i,v in pairs(v.Components) do
v.Visible = false
end
end
end
end
end
end
function ESP:GetBox(obj)
return self.Objects[obj]
end
if options.Recursive then
parent.DescendantAdded:Connect(NewListener)
for i,v in pairs(parent:GetDescendants()) do
coroutine.wrap(NewListener)(v)
end
else
parent.ChildAdded:Connect(NewListener)
for i,v in pairs(parent:GetChildren()) do
coroutine.wrap(NewListener)(v)
end
end
end
local boxBase = {}
boxBase.__index = boxBase
function boxBase:Remove()
ESP.Objects[self.Object] = nil
for i,v in pairs(self.Components) do
v.Visible = false
v:Remove()
self.Components[i] = nil
end
end
function boxBase:Update()
if not self.PrimaryPart then
--warn("not supposed to print", self.Object)
return self:Remove()
end
local color
if ESP.Highlighted == self.Object then
color = ESP.HighlightColor
else
color = self.Color or self.ColorDynamic and self:ColorDynamic() or
ESP:GetColor(self.Object) or ESP.Color
end
--calculations--
local cf = self.PrimaryPart.CFrame
if ESP.FaceCamera then
cf = CFrame.new(cf.p, cam.CFrame.p)
end
local size = self.Size
local locs = {
TopLeft = cf * ESP.BoxShift * CFrame.new(size.X/2,size.Y/2,0),
TopRight = cf * ESP.BoxShift * CFrame.new(-size.X/2,size.Y/2,0),
BottomLeft = cf * ESP.BoxShift * CFrame.new(size.X/2,-size.Y/2,0),
BottomRight = cf * ESP.BoxShift * CFrame.new(-size.X/2,-size.Y/2,0),
LegPos = cf* ESP.BoxShift * CFrame.new(size.X/75,-size.Y/2,0),
TagPos = cf * ESP.BoxShift * CFrame.new(0,size.Y/2,0),
Torso = cf * ESP.BoxShift
}
local Offset = 20
local BottomOffset = 0
local TopLeft, Vis1 = cam:WorldToViewportPoint(locs.TopLeft.p)
local TopRight, Vis2 = WorldToViewportPoint(cam, locs.TopRight.p)
local BottomLeft, Vis3 = WorldToViewportPoint(cam, locs.BottomLeft.p)
local BottomRight, Vis4 = WorldToViewportPoint(cam, locs.BottomRight.p)
local LegPos = cam:WorldToViewportPoint(locs.LegPos.p)
local Distance = (self.PrimaryPart.Position -
plrs.LocalPlayer.Character.HumanoidRootPart.Position).Magnitude
self.Components.OutlineQuad.Visible = true
self.Components.OutlineQuad.PointA = Vector2.new(TopRight.X,
TopRight.Y)
self.Components.OutlineQuad.PointB = Vector2.new(TopLeft.X,
TopLeft.Y)
self.Components.OutlineQuad.PointC = Vector2.new(BottomLeft.X,
BottomLeft.Y)
self.Components.OutlineQuad.PointD = Vector2.new(BottomRight.X,
BottomRight.Y)
else
self.Components.Quad.Visible = false
self.Components.OutlineQuad.Visible = false
end
end
else
self.Components.Quad.Visible = false
self.Components.OutlineQuad.Visible = false
end
if onscreen then
local Humanoid = self.PrimaryPart.Parent.Humanoid
self.Components.HealthbarOutline.Visible = true
self.Components.HealthbarOutline.From = Vector2.new(BottomLeft.X-
3.5,BottomLeft.Y+1)
self.Components.HealthbarOutline.To = Vector2.new(TopLeft.X-
3.5,TopLeft.Y-2)
self.Components.Healthbar.Visible = true
self.Components.Healthbar.From = Vector2.new(BottomLeft.X-
3.5 ,BottomLeft.Y)
self.Components.Healthbar.Color =
ESP.LowerHealthColor:lerp(ESP.HigherHealthColor,
Humanoid.Health/Humanoid.MaxHealth)
self.Components.Healthbar.To = Vector2.new(TopLeft.X-3.5,TopLeft.Y-1)
else
self.Components.Healthbar.Visible = false
self.Components.HealthbarOutline.Visible = false
end
else
self.Components.Healthbar.Visible = false
self.Components.HealthbarOutline.Visible = false
end
if Vis5 then
self.Components.Distance.Visible = true
if plrs:FindFirstChild(tostring(self.PrimaryPart.Parent)) ~= nil
then
self.Components.Distance.Position = Vector2.new(LegPos.X,
LegPos.Y + BottomOffset)
BottomOffset = BottomOffset + 14
elseif plrs:FindFirstChild(tostring(self.PrimaryPart.Parent)) ==
nil then
self.Components.Distance.Position = Vector2.new(TagPos.X,
TagPos.Y - Offset)
Offset = Offset + 14
end
self.Components.Distance.Text = math.floor((cam.CFrame.p -
cf.p).magnitude) .." studs"
self.Components.Distance.Color = ESP.DistanceColor
else
self.Components.Distance.Visible = false
end
else
self.Components.Distance.Visible = false
end
if Vis5 then
self.Components.Name.Visible = true
self.Components.Name.Position = Vector2.new(TagPos.X,TagPos.Y - Offset)
self.Components.Name.Text = self.Name
self.Components.Name.Color = ESP.TextColor
Offset = Offset+10
else
self.Components.Name.Visible = false
end
else
self.Components.Name.Visible = false
end
if Vis6 then
self.Components.Tracer.Visible = true
self.Components.Tracer.From = Vector2.new(TorsoPos.X,TorsoPos.Y)
self.Components.Tracer.To =
Vector2.new(cam.ViewportSize.X/2,cam.ViewportSize.Y/ESP.AttachShift)
self.Components.Tracer.Color = ESP.TracerColor
else
self.Components.Tracer.Visible = false
end
else
self.Components.Tracer.Visible = false
end
end
if self:GetBox(obj) then
self:GetBox(obj):Remove()
end
box.Components["OutlineQuad"] = Draw("Quad", {
Thickness = self.Thickness + 2,
Color = Color3.fromRGB(0,0,0),
Transparency = 1,
Filled = false,
Visible = self.Enabled and self.Boxes
})
box.Components["Quad"] = Draw("Quad", {
Thickness = self.Thickness,
Color = color,
Transparency = 1,
Filled = false,
Visible = self.Enabled and self.Boxes
})
box.Components["Name"] = Draw("Text", {
Text = box.Name,
Color = ESP.TextColor,
Center = true,
Outline = true,
Size = 14,
Visible = self.Enabled and self.Names
})
box.Components["Distance"] = Draw("Text", {
Color = ESP.DistanceColor,
Center = true,
Outline = true,
Size = 14,
Visible = self.Enabled and self.Distance
})
box.Components["EquippedTool"] = Draw("Text", {
Color = ESP.EquippedColor,
Center = true,
Outline = true,
Size = 14,
Visible = self.Enabled and self.Equipped
})
box.Components["Tracer"] = Draw("Line", {
Thickness = ESP.Thickness,
Color = box.Color,
Transparency = 1,
Visible = self.Enabled and self.Tracers
})
box.Components["HealthbarOutline"] = Draw('Line',{
Thickness = 3 ,
Color = Color3.new(0,0,0),
Transparency = 1,
Visible = self.Enabled and self.HealthBar,
})
box.Components["Healthbar"] = Draw('Line',{
Thickness = 1,
Color = Color3.new(0,1,0),
Transparency = 1,
Visible = self.Enabled and self.HealthBar,
})
self.Objects[obj] = box
obj.AncestryChanged:Connect(function(_, parent)
if parent == nil and ESP.AutoRemove ~= false then
box:Remove()
end
end)
obj:GetPropertyChangedSignal("Parent"):Connect(function()
if obj.Parent == nil and ESP.AutoRemove ~= false then
box:Remove()
end
end)
return box
end
game:GetService("RunService").RenderStepped:Connect(function()
cam = workspace.CurrentCamera
for i,v in (ESP.Enabled and pairs or ipairs)(ESP.Objects) do
if v.Update then
local s,e = pcall(v.Update, v)
if not s then warn("[ERROR]", e, v.Object:GetFullName()) end
end
end
end)
return ESP
end)
--teleport stuff
--SettingSection
game:GetService("RunService").RenderStepped:Connect(function()
UpdateHealth()
UpdateVelocity()
UpdateWalkspeed()
end)
game:GetService("RunService").Heartbeat:Connect(function()
UpdateObjectCounter()
end)
Players.PlayerAdded:Connect(function()
PlayerCount = #Players:GetPlayers()
PlayerCountText.Text = "Players: " .. tostring(PlayerCount)
end)
Players.PlayerRemoving:Connect(function()
PlayerCount = #Players:GetPlayers()
PlayerCountText.Text = "Players: " .. tostring(PlayerCount)
end)
game:GetService("RunService").RenderStepped:Connect(function()
UpdatePlayerName()
end)
game:GetService("UserInputService").GamepadConnected:Connect(function(gamepad)
UpdateGamepadStatus()
end)
game:GetService("UserInputService").GamepadDisconnected:Connect(function(gamepad)
UpdateGamepadStatus()
end)
UpdateGamepadStatus()
RunService.RenderStepped:Connect(function()
UpdateViewAngle()
end)
Players = game:GetService("Players")
local UserInputService = game:GetService("UserInputService")
game:GetService("RunService").RenderStepped:Connect(function()
UpdateAirStuckText()
end)
game:GetService("RunService").RenderStepped:Connect(function()
GetLookAngle()
end)
end)
StarterGui:SetCore("ChatMakeSystemMessage",privateProperties)
end
end
end
end
end
--// instances
local cc = Instance.new("ColorCorrectionEffect")
local lighting = game:GetService("Lighting")
local sbox = Instance.new("Sky")
--// hd killer
local ihateu = {"DepthOfFieldEffect", "SunRaysEffect", "BloomEffect", "BlurEffect",
"ColorCorrectionEffect", "Atmosphere"}
for i, v in pairs(lighting:GetChildren()) do
for index, value in ipairs(ihateu) do
if v:IsA(value) then
v:Destroy()
end
end
end
--// setup
cc.Parent = game.Lighting
cc.Saturation = -0.1
cc.Contrast = -0.1
lighting.GlobalShadows = false
sbox.Parent = lighting
sbox.SkyboxBk = "http://www.roblox.com/asset/?id=271042516"
sbox.SkyboxDn = "http://www.roblox.com/asset/?id=271077243"
sbox.SkyboxFt = "http://www.roblox.com/asset/?id=271042556"
sbox.SkyboxLf = "http://www.roblox.com/asset/?id=271042310"
sbox.SkyboxRt = "http://www.roblox.com/asset/?id=271042467"
sbox.SkyboxUp = "http://www.roblox.com/asset/?id=271077958"
lighting.Ambient = Color3.new(0,0,0)
lighting.FogColor = Color3.new(0,0,0)
lighting.ClockTime = 3
lighting.FogEnd = 2000
local hue = 0
while true do
hue = hue + 1
if hue > 360 then
hue = 0
end
local color = Color3.fromHSV(hue/360, 1, 1)
lighting.Ambient = color
lighting.FogColor = color
wait(0.05)
end
end)