Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local PlaceId = 142823291
- local ScriptVersion = "BETA"
- if game.PlaceId ~= PlaceId then
- game:GetService("TeleportService"):Teleport(PlaceId,game:GetService("Players").LocalPlayer)
- return game:GetService("Players").LocalPlayer:Kick("\nJoining MM2 ...")
- end
- local cloneref = cloneref or function(o) return o end
- local StarterGui = cloneref(game:GetService("StarterGui"))
- local function LegacyNotif(Title, Message, Time)
- StarterGui:SetCore("SendNotification", {
- Title = Title,
- Text = Message,
- Duration = Time or 5
- })
- end
- if not game:IsLoaded() then
- LegacyNotif("Waiting game to Load.","Please Wait.")
- print("Waiting game to Load. Please Wait!")
- game.Loaded:Wait()
- end
- if _G.MurderMystery2ScriptLoaded then
- return LegacyNotif("Already Loaded","Please re-Join if needed.")
- end
- warn("Loaded : 1 / 2")
- -- Locals
- _G.MurderMystery2ScriptLoaded = true
- local HiddenUI = cloneref(gethui() or game:GetService("CoreGui"))
- local Players = cloneref(game:GetService("Players"))
- local LocalPlayer = Players.LocalPlayer
- local Mouse = LocalPlayer:GetMouse()
- local ReplicatedStorage = cloneref(game:GetService("ReplicatedStorage"))
- local Workspace = cloneref(game:GetService("Workspace"))
- local RunService = cloneref(game:GetService("RunService"))
- local TeleportService = cloneref(game:GetService("TeleportService"))
- local UserInputService = cloneref(game:GetService("UserInputService"))
- local HttpService = cloneref(game:GetService("HttpService"))
- local MarketplaceService = cloneref(game:GetService("MarketplaceService"))
- local CollectionService = cloneref(game:GetService("CollectionService"))
- local LocalPlayerData = {
- CollectedCoins = {}
- }
- local function RandomStrings()
- local length = math.random(10,20)
- local array = {}
- for i = 1, length do
- array[i] = string.char(math.random(32, 126))
- end
- return table.concat(array)
- end
- local VisualGUI = Instance.new("ScreenGui",HiddenUI)
- VisualGUI.ResetOnSpawn = false
- VisualGUI.DisplayOrder = 999999999
- VisualGUI.Name = RandomStrings()
- local VisualHolder = Instance.new("Folder",VisualGUI)
- VisualHolder.Name = "VisualHolder"
- local EspHolder = Instance.new("Folder",VisualHolder)
- EspHolder.Name = "Esp"
- local GunHolder = Instance.new("Folder",EspHolder)
- GunHolder.Name = "Gun"
- local PlayerHolder = Instance.new("Folder",EspHolder)
- PlayerHolder.Name = "Player"
- local NameHolder = Instance.new("Folder",PlayerHolder)
- NameHolder.Name = "Name"
- local ChamHolder = Instance.new("Folder",PlayerHolder)
- ChamHolder.Name = "Cham"
- local PartHolder = Instance.new("Folder",Workspace)
- PartHolder.Name = RandomStrings()
- --[[
- local PredictionBox = Instance.new("Part",PartHolder)
- PredictionBox.Name = RandomStrings()
- PredictionBox.Transparency = 1
- PredictionBox.Size = Vector3.new(.5,.5,.5)
- PredictionBox.Anchored = true
- PredictionBox.CanCollide = false
- PredictionBox.CastShadow = false
- PredictionBox.Shape = Enum.PartType.Ball
- PredictionBox.Massless = true
- PredictionBox.Position = Vector3.zero
- local Highlight = Instance.new("Highlight",PredictionBox)
- Highlight.Adornee = PredictionBox
- Highlight.FillTransparency = 0
- Highlight.FillColor = Color3.new(1,0,0)
- Highlight.OutlineTransparency = 0.5
- Highlight.Enabled = true
- ]]
- local OrionLib
- local IconsTable = {}
- -- Library & Icons
- local Success, Error = pcall(function()
- OrionLib, IconsTable = loadstring(game:HttpGet(('https://pastebin.com/raw/zR2ainN8')))(), HttpService:JSONDecode(game:HttpGetAsync("https://raw.githubusercontent.com/evoincorp/lucideblox/master/src/modules/util/icons.json")).icons
- end)
- if Error then
- warn("\nOrion Library - Failed to load GUI. Error code: " .. Error .. "\n")
- VisualGUI:Destroy()
- PartHolder:Destroy()
- return LegacyNotif("Script Error", "Try to Execute it again.")
- end
- local function GetIcon(IconName)
- if IconName and tostring(IconName) then
- return IconsTable[IconName]
- end
- return nil
- end
- local function Notify(Title, Message, Time, Icon)
- OrionLib:MakeNotification({
- Name = Title,
- Content = Message,
- Image = Icon or "rbxassetid://4483345998",
- Time = Time
- })
- end
- local function GetPlaceName()
- local GameInfo
- pcall(function()
- GameInfo = MarketplaceService:GetProductInfo(game.PlaceId, Enum.InfoType.Asset)
- end)
- return GameInfo and GameInfo.Name or "Murder Mystery 2"
- end
- local Window = OrionLib:MakeWindow({Name = GetPlaceName().." ["..ScriptVersion.."]", HidePremium = true, SaveConfig = true, ConfigFolder = "MurderMystery2BETA", IntroEnabled = false})
- -- ICONS --
- local Icons = {
- Cross = GetIcon("x-circle"),
- Check = GetIcon("check-circle"),
- Info = GetIcon("info"),
- Alert = GetIcon("alert-circle"),
- ThumbsUp = GetIcon("thumbs-up")
- }
- local function GetPlayer(String)
- local Found = {}
- local strl = String:lower()
- for i,v in pairs(Players:GetPlayers()) do
- if v ~= LocalPlayer and v.Name:lower():sub(1, #String) == strl or v.DisplayName:lower():sub(1, #String) == strl then
- table.insert(Found,v)
- end
- end
- return Found
- end
- local function FindChildsInWorkspace(string)
- if string and not tostring(string) then return nil end
- local Results = {}
- local Childrens = Workspace:GetChildren()
- if string then
- for _, Child in pairs(Childrens) do
- if string and Child.Name:lower() == string:lower() then
- table.insert(Results, Child)
- end
- end
- end
- return string and Results ~= {} and Results or not string and Childrens or nil
- end
- -- TOGGLES --
- local Toggles = {
- EnableESP,
- EnableChams,
- GunESP,
- EnableWalkSpeed,
- EnableJumpPower,
- EnableGravity,
- TeleportTool,
- AntiLag,
- AntiTrap,
- AntiLock,
- MuteRadios,
- AntiFling,
- SecondLife,
- AutoGrabGun,
- AutoBreakGun,
- AutoBreakGunWhenMurder,
- Noclip,
- AntiVoid,
- InfiniteJump
- }
- -- SAVED LOCALS --
- local SavedLocals = {}
- local Data = OrionLib:GetSavedLocals()
- if Data then
- SavedLocals = Data
- end
- -- TIMER --
- local DontDisturb = false
- local Timer = {
- TimePassed = 0,
- StopTimer = false
- }
- function Timer:Start()
- self.StopTimer = false
- task.spawn(function()
- while not self.StopTimer do
- task.wait(1)
- self.TimePassed = self.TimePassed + 1
- if self.StopTimer then
- break
- end
- end
- end)
- end
- function Timer:Stop()
- self.StopTimer = true
- self.TimePassed = 0
- end
- -- COLORS --
- local Colors = {
- ChromaTexture = "rbxassetid://18364488166"
- }
- function Colors:GetColor(Object, Type)
- local colors = {
- Innocent = {
- Solid = Color3.new(0, 255, 0),
- Cham = Color3.fromRGB(75, 151, 75),
- ESP = Color3.fromRGB(75, 255, 75)
- },
- Sheriff = {
- Solid = Color3.new(0, 0, 255),
- Cham = Color3.fromRGB(98, 37, 209),
- ESP = Color3.fromRGB(75, 75, 255)
- },
- Murderer = {
- Solid = Color3.new(255, 0, 0),
- Cham = Color3.fromRGB(196, 40, 28),
- ESP = Color3.fromRGB(255, 40, 29)
- },
- Hero = {
- Solid = Color3.new(255, 255, 0),
- Cham = Color3.fromRGB(245, 205, 48),
- ESP = Color3.fromRGB(245, 205, 48)
- },
- Gun = {
- Cham = Color3.fromRGB(121, 39, 176),
- ESP = Color3.fromRGB(98, 37, 209)
- }
- }
- return Object and Type and colors[Object][Type] or Object and not Type and colors[Object] or colors or nil
- end
- -- ROLES --
- local Roles = {
- RoleTable = nil,
- Murderer = "",
- Sheriff = "",
- Hero = "",
- CurrentGameMode = ""
- }
- local BreakedGun = nil
- function Roles:GetRole(Player)
- if not Player or not self.RoleTable then return "none" end
- local roleData = self.RoleTable[Player.Name]
- return roleData and roleData.Role or "none"
- end
- function Roles:IsAlive(Player)
- for i, v in pairs(self.RoleTable or {}) do
- if Player.Name == i then
- return not v.Dead
- end
- end
- return nil
- end
- function Roles:SetRoleTable()
- local GetPlayerData = ReplicatedStorage:FindFirstChild("Remotes") and ReplicatedStorage.Remotes:FindFirstChild("Extras") and ReplicatedStorage.Remotes.Extras:FindFirstChild("GetPlayerData")
- if not GetPlayerData then return end
- pcall(function()
- self.RoleTable = GetPlayerData:InvokeServer()
- end)
- end
- function Roles:UpdateRole()
- task.spawn(function() self:SetRoleTable() end)
- if not self.RoleTable then print("Waiting for Role Table.") end
- local function UpdateVisual(PlayerName, Role)
- local TextLabel = NameHolder:FindFirstChild(PlayerName) and NameHolder[PlayerName]:FindFirstChildOfClass("BillboardGui") and NameHolder[PlayerName]:FindFirstChildOfClass("BillboardGui"):FindFirstChild(PlayerName)
- if TextLabel then
- TextLabel.TextColor3 = Colors:GetColor(Role, "ESP")
- end
- local ChamFolder = ChamHolder:FindFirstChild(PlayerName .. "_CHM")
- if ChamFolder then
- for _, Cham in pairs(ChamFolder:GetChildren()) do
- Cham.Color3 = Colors:GetColor(Role, "Cham")
- end
- end
- end
- for i, v in pairs(self.RoleTable or {}) do
- local thePlayer = Players:FindFirstChild(i)
- if not thePlayer then break end
- if v.Role == "Murderer" and self:IsAlive(thePlayer) then
- self.Murderer = thePlayer.Name
- if i ~= LocalPlayer.Name then
- UpdateVisual(i, v.Role)
- end
- elseif v.Role == "Sheriff" and self:IsAlive(thePlayer) then
- self.Sheriff = thePlayer.Name
- if i ~= LocalPlayer.Name then
- UpdateVisual(i, v.Role)
- end
- elseif thePlayer.Name == self.Hero and self:IsAlive(thePlayer) and not Players:FindFirstChild(self.Sheriff) then
- if i ~= LocalPlayer.Name then
- UpdateVisual(i, "Hero")
- end
- else
- for Role, Player in pairs(self) do
- if Player == thePlayer.Name then
- warn("[Reset Role] : ("..thePlayer.Name..")")
- if Player == self.Sheriff or Player == self.Hero then
- warn("[Reset BreakedGun] : ("..thePlayer.Name..")")
- BreakedGun = nil
- end
- self[Role] = ""
- break
- end
- end
- if i ~= LocalPlayer.Name then
- UpdateVisual(i, "Innocent")
- end
- end
- end
- end
- function Roles:FindKnife(Player, GetInstance)
- local function CheckKnife(Knife)
- if Knife and Knife:IsA("Tool") then
- local Handle = Knife:FindFirstChild("Handle")
- local KnifeServer = Knife:FindFirstChild("KnifeServer")
- local Stab = Knife:FindFirstChild("Stab")
- local Throw = Knife:FindFirstChild("Throw")
- if not (Handle and KnifeServer and Stab and Throw) then return end
- return GetInstance and {KnifeServer = KnifeServer, Stab = Stab, Throw = Throw, Handle = Handle} or true
- end
- end
- local Parents = {
- Player.Character,
- Player:FindFirstChildOfClass("Backpack")
- }
- for _,Parent in pairs(Parents) do
- if Parent then
- local Knife = Parent:FindFirstChild("Knife")
- local Result = Knife and CheckKnife(Knife)
- if Result then return Result end
- end
- end
- return false
- end
- function Roles:FindGun(Player, GetInstance)
- local function CheckGun(Gun, IsLocal)
- if Gun and Gun:IsA("Tool") then
- local Handle = Gun:FindFirstChild("Handle")
- local IsGun = Gun:FindFirstChild("IsGun")
- local KnifeServer = Gun:FindFirstChild("KnifeServer")
- if not (Handle and IsGun and KnifeServer) then return end
- local ShootGun = IsLocal and Gun:FindFirstChild("KnifeLocal") and Gun.KnifeLocal:FindFirstChild("CreateBeam") and Gun.KnifeLocal.CreateBeam.RemoteFunction or KnifeServer:FindFirstChild("ShootGun")
- return ShootGun and (GetInstance and {KnifeServer = KnifeServer, ShootGun = ShootGun, Handle = Handle} or true)
- end
- return false
- end
- local Parents = {
- Player.Character,
- Player:FindFirstChildOfClass("Backpack")
- }
- for _,Parent in pairs(Parents) do
- if Parent then
- local Gun = Parent:FindFirstChild("Gun")
- local Result = Gun and CheckGun(Gun, Player == LocalPlayer)
- if Result then return Result end
- end
- end
- return false
- end
- function Roles:UpdateGameMode()
- for _, Player in pairs(Players:GetPlayers()) do
- for _, FindFunction in pairs({self[FindGun], self[FindKnife]}) do
- local Weapon = FindFunction(Player, true)
- if Weapon and Weapon.KnifeServer then
- local GameMode = Weapon.KnifeServer:FindFirstChild("GameMode")
- if GameMode and GameMode:IsA("StringValue") then
- self.CurrentGameMode = tostring(GameMode.Value)
- print("Current Game Mode:", self.CurrentGameMode)
- end
- end
- end
- end
- end
- -- RAYS & INSTANCES --
- local function ToObject(string)
- local object = game
- for _, name in ipairs(string.split(string, ".")) do
- object = object:FindFirstChild(name)
- if not object then return nil end
- end
- return object
- end
- local function IsPredictBehindWallFromPart(Part, OtherCharacter, Local)
- if Local and Local.Character and Part and OtherCharacter and PredictionBox then
- local Ignored = {Local.Character, OtherCharacter}
- local Ray = Ray.new(Part.Position, (PredictionBox.Position - Part.Position).unit * 9e9)
- local Hit = Workspace:FindPartOnRayWithIgnoreList(Ray, Ignored, false, true)
- return Hit and Hit:IsDescendantOf(Workspace) and Hit ~= PredictionBox
- end
- end
- --[[
- local function IsBehindWallFromRay(Player, Local)
- if Local and Local.Character and Player.Character and RayPart and RayPart.Parent then
- local Root = Player.Character and Player.Character.PrimaryPart
- if Root then
- local Ignored = {Local.Character, PredictionBox}
- local Ray = Ray.new(RayPart.Position, (Root.Position - RayPart.Position).unit * 9e9)
- local Hit = Workspace:FindPartOnRayWithIgnoreList(Ray, Ignored, false, true)
- return Hit and not Hit:IsDescendantOf(Player.Character)
- end
- end
- end
- ]]
- local function ClosestNotBehindWallPlayer()
- local closestPlayer, closestDistance = nil, math.huge
- for _, Player in pairs(Players:GetPlayers()) do
- if Player ~= LocalPlayer then
- local Root = LocalPlayer.Character and LocalPlayer.Character.PrimaryPart
- local Root2 = Player.Character and Player.Character.PrimaryPart
- if Root and Root2 then
- local distance = (Root.Position - Root2.Position).Magnitude
- if distance < closestDistance and Roles:IsAlive(Player) and not isBehindWallFromRay(Player, LocalPlayer) then
- closestPlayer = Player
- closestDistance = distance
- end
- end
- end
- end
- return closestPlayer
- end
- -- VISUALS --
- local Visual = {
- Transparency = SavedLocals["Transparency"] or 0.7
- }
- function Visual:Esp(Player)
- repeat task.wait() until Player.Character and Player.Character:FindFirstChildOfClass("Humanoid") and Player.Character.Humanoid.RootPart and Player.Character:FindFirstChild("Head")
- local Head = Player.Character.Head
- local NameFolder = Instance.new("Folder", NameHolder)
- NameFolder.Name = Player.Name
- local BillboardGui = Instance.new("BillboardGui", NameFolder)
- BillboardGui.Adornee = Head
- BillboardGui.Name = Head.Name
- BillboardGui.Size = UDim2.new(0, 100, 0, 150)
- BillboardGui.StudsOffset = Vector3.new(0, 1, 0)
- BillboardGui.AlwaysOnTop = true
- local TextLabel = Instance.new("TextLabel", BillboardGui)
- TextLabel.BackgroundTransparency = 1
- TextLabel.Position = UDim2.new(0, 0, 0, -50)
- TextLabel.Size = UDim2.new(0, 100, 0, 100)
- TextLabel.Font = Enum.Font.Gotham
- TextLabel.TextSize = 12
- TextLabel.TextColor3 = Colors:GetColor("Innocent", "ESP")
- TextLabel.TextStrokeTransparency = 0
- TextLabel.TextYAlignment = Enum.TextYAlignment.Bottom
- TextLabel.Text = Player.Name
- TextLabel.ZIndex = 0
- TextLabel.Name = Player.Name
- end
- function Visual:PEsp(Adornee,Parent,Color3)
- local a = Instance.new("BoxHandleAdornment",Parent)
- a.Name = Adornee.Name.."_PESP"
- a.Adornee = Adornee
- a.AlwaysOnTop = true
- a.ZIndex = 0
- a.Size = Adornee.Size
- a.Transparency = Visual.Transparency
- a.Color3 = Color3
- end
- function Visual:NEsp(Adornee,Parent,Color3,Text)
- local BillboardGui = Instance.new("BillboardGui",Parent)
- BillboardGui.Adornee = Adornee
- BillboardGui.Name = Adornee.Name.."_NESP"
- BillboardGui.Size = UDim2.new(0,100,0,150)
- BillboardGui.StudsOffset = Vector3.new(0,1,0)
- BillboardGui.AlwaysOnTop = true
- local TextLabel = Instance.new("TextLabel",BillboardGui)
- TextLabel.BackgroundTransparency = 1
- TextLabel.Position = UDim2.new(0,0,0,-50)
- TextLabel.Size = UDim2.new(0,100,0,100)
- TextLabel.Font = Enum.Font.Gotham
- TextLabel.TextSize = 12
- TextLabel.TextColor3 = Color3
- TextLabel.TextStrokeTransparency = 0
- TextLabel.TextYAlignment = Enum.TextYAlignment.Bottom
- TextLabel.Text = Text
- TextLabel.ZIndex = 0
- end
- function Visual:Cham(Player)
- local ChamFolder = Instance.new("Folder", ChamHolder)
- ChamFolder.Name = Player.Name .. "_CHM"
- repeat task.wait() until Player.Character and Player.Character:FindFirstChildOfClass("Humanoid") and Player.Character.Humanoid.RootPart and Player.Character:FindFirstChild("Head")
- local Character = Player.Character
- if not Character then return Visual:Cham(Player) end
- for _, Part in ipairs(Character:GetChildren()) do
- if Part:IsA("BasePart") and Part.Name ~= ("Radio" and "HumanoidRootPart") then
- local Adornment = Instance.new("BoxHandleAdornment", ChamFolder)
- Adornment.Name = Part.Name
- Adornment.Adornee = Part
- Adornment.AlwaysOnTop = true
- Adornment.ZIndex = 0
- Adornment.Size = Part.Size
- Adornment.Transparency = Visual.Transparency
- Adornment.Color3 = Colors:GetColor("Innocent", "Cham")
- end
- end
- end
- function Visual:HandleChroma(ChromaDecal)
- if not ChromaDecal:IsA("Decal") then return end
- local Rainbow = ChromaDecal:Clone()
- Rainbow.Name, Rainbow.Texture, Rainbow.Parent = "Rainbow", Colors.ChromaTexture, ChromaDecal.Parent
- ChromaDecal:Destroy()
- end
- -- GUN DROP --
- local GrabGun = {
- DroppedGun = nil,
- isGrabGun = false
- }
- --[[ ⚠️ NO USE ⚠️
- if DontDisturb then
- if Auto then
- repeat task.wait() until not DontDisturb or not Toggles.AutoGrabGun
- else
- GrabGun["isGrabGun"] = false
- return Notify("Grab Gun","Cant grab gun right now.",3,Icons.Info)
- end
- end
- DontDisturb = true
- if not Auto then
- Timer:Start()
- end
- local theMurderer = Players:FindFirstChild(Roles.Murderer)
- if GrabGun["DroppedGun"] and GrabGun["DroppedGun"].Parent and not Roles:FindGun(LocalPlayer,false) and Roles:GetRole(LocalPlayer) == "Innocent" and Roles:IsAlive(LocalPlayer) and theMurderer then
- local GunCFrame = CFrame.new(GrabGun["DroppedGun"].Position + Vector3.new(0, -3, 0)) * CFrame.Angles(math.pi * .5, 0, 0)
- local Character = LocalPlayer.Character
- local Character2 = theMurderer.Character
- if Character and Character2 then
- local Root = Character:FindFirstChild("HumanoidRootPart")
- local Humanoid = Character:FindFirstChildOfClass("Humanoid")
- local Root2 = Character2:FindFirstChild("HumanoidRootPart")
- if Root and Humanoid and Root2 then
- if Auto then
- repeat task.wait() until (GrabGun["DroppedGun"].Position - Root2.Position).Magnitude > 5 or not GrabGun["DroppedGun"].Parent or not Root.Parent or not Root2.Parent or not Toggles.AutoGrabGun
- else
- repeat task.wait() until (GrabGun["DroppedGun"].Position - Root2.Position).Magnitude > 5 or not GrabGun["DroppedGun"].Parent or not Root.Parent or not Root2.Parent
- end
- local lastCFrame = Root.CFrame
- local lastNoclipState = Toggles.Noclip
- local lastAntiVoidState = Toggles.AntiVoid
- if Auto then
- repeat
- if GrabGun["DroppedGun"].Parent and Root.Parent then
- Workspace.CurrentCamera.CameraType = Enum.CameraType.Scriptable
- Toggles.Noclip = true
- Toggles.AntiVoid = false
- Root.CFrame = GunCFrame
- end
- RunService.Stepped:Wait()
- until not GrabGun["DroppedGun"].Parent or Roles:FindGun(LocalPlayer,false) or not Root.Parent or Roles:GetRole(LocalPlayer) ~= "Innocent" or not Roles:IsAlive(LocalPlayer) or not Toggles.AutoGrabGun
- else
- repeat
- if GrabGun["DroppedGun"].Parent and Root.Parent then
- Workspace.CurrentCamera.CameraType = Enum.CameraType.Scriptable
- Toggles.Noclip = true
- Toggles.AntiVoid = false
- Root.CFrame = GunCFrame
- end
- RunService.Stepped:Wait()
- until not GrabGun["DroppedGun"].Parent or Roles:FindGun(LocalPlayer,false) or not Root.Parent or Roles:GetRole(LocalPlayer) ~= "Innocent" or not Roles:IsAlive(LocalPlayer) or Timer["TimePassed"] > 2
- end
- Toggles.Noclip = lastNoclipState
- Toggles.AntiVoid = lastAntiVoidState
- if Humanoid and Root and lastCFrame then
- Humanoid:ChangeState(Enum.HumanoidStateType.GettingUp)
- Root.CFrame = lastCFrame
- Root.AssemblyLinearVelocity = Vector3.zero
- Root.AssemblyAngularVelocity = Vector3.zero
- end
- Workspace.CurrentCamera.CameraType = Enum.CameraType.Custom
- Success = true
- end
- end
- end
- ]]
- function GrabGun:Start(Auto)
- task.spawn(function()
- if self.isGrabGun or not self.DroppedGun then
- return not Auto and Notify("Grab Gun", "Can't grab gun right now.", 3, Icons.Info)
- end
- self.isGrabGun = true
- local Success = false
- if Roles:GetRole(LocalPlayer) == "Innocent" and self.DroppedGun and self.DroppedGun.Parent then
- local Root = LocalPlayer.Character and LocalPlayer.Character.PrimaryPart
- if Root then
- if Auto then
- repeat
- if self.DroppedGun.Parent and Root.Parent then
- self.DroppedGun.CFrame = Root.CFrame
- end
- RunService.Stepped:Wait()
- until not self.DroppedGun.Parent or Roles:FindGun(LocalPlayer, false) or not Root.Parent or Roles:GetRole(LocalPlayer) ~= "Innocent" or not Toggles.AutoGrabGun
- else
- self.DroppedGun.CFrame = Root.CFrame
- end
- Success = true
- end
- end
- self.isGrabGun = false
- return not Auto and Notify("Grab Gun", Success and "Successfully Grab Gun!" or "Try again later.", 3, Success and Icons.Check or Icons.Info)
- end)
- end
- -- MAP --
- local Map = {}
- function Map:IsMap(Model, GetInstance)
- local Spawns = Model:FindFirstChild("Spawns")
- local CoinContainer = Model:FindFirstChild("CoinAreas") or Model:FindFirstChild("CoinContainer")
- if Model:IsA("Model") and not Players:GetPlayerFromCharacter(Model) and Spawns and CoinContainer then
- return GetInstance and {Map = Model, Spawns = Spawns, CoinContainer = CoinContainer} or true
- end
- return
- end
- function Map:GetCurrentMap(GetInstance)
- local ResultTable
- for _, Childs in pairs(FindChildsInWorkspace() or {}) do
- local Result = self:IsMap(Childs, true)
- if Result then
- ResultTable = Result
- break
- end
- end
- if not ResultTable then return end
- return GetInstance and ResultTable or true
- end
- --[[
- function Map:CheckMap()
- local function ProcessGroup(Group)
- if Group:IsA("BasePart") and Group.Name == "GunDrop" then
- GrabGun.DroppedGun = Group
- if Toggles.AutoGrabGun then
- GrabGun:Start(true)
- end
- Visual:PEsp(Group, GunHolder, Colors:GetColor("Gun", "Cham"))
- Visual:NEsp(Group, GunHolder, Colors:GetColor("Gun", "ESP"), "Gun")
- if Roles:GetRole(LocalPlayer) == "Innocent" then
- Group.Size = Vector3.new(10, 10, 10)
- end
- Group.Changed:Connect(function()
- if not Group.Parent then
- for _, Childs in pairs(GunHolder:GetChildren()) do
- if Childs.Adornee == Group then
- Childs:Destroy()
- end
- end
- end
- end)
- elseif Group.Name ~= "CoinAreas" and Group.Name ~= "CoinContainer" then
- for _, Instance in pairs(Group:GetDescendants()) do
- if Instance:IsA("Decal") and Instance.Name == "Chroma" and Toggles.AntiLag then
- Visual:HandleChroma(Instance)
- end
- end
- Group.DescendantAdded:Connect(function(Instance)
- if Instance:IsA("Decal") and Instance.Name == "Chroma" and Toggles.AntiLag then
- task.wait()
- Visual:HandleChroma(Instance)
- end
- end)
- end
- end
- local MapAvailable
- local function CheckCurrentMap()
- local MapResult = self:GetCurrentMap(true)
- if MapResult then
- for _, Group in pairs(MapResult.Map:GetChildren()) do
- ProcessGroup(Group)
- end
- MapResult.Map.ChildAdded:Connect(ProcessGroup)
- MapResult.Map.Changed:Connect(function()
- if not MapResult.Map.Parent then MapAvailable = false end
- end)
- end
- end
- CheckCurrentMap()
- Workspace.ChildAdded:Connect(function(Child)
- if Child.Name == "Footsteps" and Child:IsA("Folder") and Toggles.AntiLag then
- task.wait()
- Child:Destroy() -- Anti Lag :)
- elseif Child:IsA("Model") and not (Players:GetPlayerFromCharacter(Child) and MapAvailable) then
- task.spawn(function()
- repeat task.wait(5) until self:IsMap(Child, false) or MapAvailable or not Child
- if Child then
- MapAvailable = true
- CheckCurrentMap()
- end
- end)
- end
- end)
- end
- ]]
- function Map:CheckMap()
- local function ProcessGroup(Group)
- if Group:IsA("BasePart") and Group.Name == "GunDrop" then
- GrabGun.DroppedGun = Group
- if Toggles.AutoGrabGun then
- GrabGun:Start(true)
- end
- Visual:PEsp(Group, GunHolder, Colors:GetColor("Gun", "Cham"))
- Visual:NEsp(Group, GunHolder, Colors:GetColor("Gun", "ESP"), "Gun")
- if Roles:GetRole(LocalPlayer) == "Innocent" then
- Group.Size = Vector3.new(10, 10, 10)
- end
- local connection
- connection = Group.Changed:Connect(function()
- if not Group.Parent then
- for _, Childs in ipairs(GunHolder:GetChildren()) do
- if Childs.Adornee == Group then
- Childs:Destroy()
- end
- end
- connection:Disconnect()
- end
- end)
- elseif Group.Name ~= "CoinAreas" and Group.Name ~= "CoinContainer" then
- for _, Instance in ipairs(Group:GetDescendants()) do
- if Instance:IsA("Decal") and Instance.Name == "Chroma" and Toggles.AntiLag then
- Visual:HandleChroma(Instance)
- end
- end
- Group.DescendantAdded:Connect(function(Instance)
- if Instance:IsA("Decal") and Instance.Name == "Chroma" and Toggles.AntiLag then
- Visual:HandleChroma(Instance)
- end
- end)
- end
- end
- local MapAvailable = false
- local function CheckCurrentMap()
- local MapResult = self:GetCurrentMap(true)
- if MapResult then
- for _, Group in ipairs(MapResult.Map:GetChildren()) do
- ProcessGroup(Group)
- end
- MapResult.Map.ChildAdded:Connect(ProcessGroup)
- MapResult.Map.Changed:Connect(function()
- if not MapResult.Map.Parent then
- MapAvailable = false
- end
- end)
- end
- end
- CheckCurrentMap()
- Workspace.ChildAdded:Connect(function(Child)
- if Child.Name == "Footsteps" and Child:IsA("Folder") and Toggles.AntiLag then
- task.wait()
- Child.ChildAdded:Connect(function(Step)
- task.wait()
- Step:Destroy()
- end)
- elseif Child:IsA("Model") and not Players:GetPlayerFromCharacter(Child) and not MapAvailable then
- task.spawn(function()
- while not self:IsMap(Child, false) and not MapAvailable do
- task.wait(5)
- end
- if Child then
- MapAvailable = true
- CheckCurrentMap()
- end
- end)
- end
- end)
- end
- -- PLAYER CONNECTION --
- local PlayerConnection = {
- Connection = {}
- }
- function PlayerConnection:BrokeTrap(Trap)
- if Trap then
- local TouchTransmitter = Trap:FindFirstChild("Trigger") and Trap.Trigger:WaitForChild("TouchInterest")
- if not TouchTransmitter then return end
- TouchTransmitter:Destroy()
- end
- end
- function PlayerConnection:ProcessChild(Child, Player)
- if Toggles.AntiLag and Child.Name == "Pet" then
- Child:Destroy()
- elseif Child.Name == "Trap" and Child:IsA("Model") and Player ~= LocalPlayer and Toggles.AntiTrap then
- task.spawn(function() self:BrokeTrap(Child) end)
- end
- end
- function PlayerConnection:HandleCharacter(Character, Player)
- if not Character then return end
- for _, Childs in pairs(Character:GetChildren()) do
- self:ProcessChild(Childs, Player)
- end
- self.Connection[Player.Name .. "_Connection"] = Character.ChildAdded:Connect(function(Child)
- if Child:IsA("Tool") and (Child.Name == "Gun" or Child.Name == "Knife") then
- task.spawn(function()
- local Chroma = Child:FindFirstChild("Handle") and Child.Handle:FindFirstChild("Chroma")
- if Chroma and Chroma:IsA("Decal") and Toggles.AntiLag then
- task.wait()
- Visual:HandleChroma(Chroma)
- end
- end)
- else
- task.wait()
- self:ProcessChild(Child, Player)
- end
- end)
- end
- function PlayerConnection:ConnectPlayer(Player)
- self:HandleCharacter(Player.Character, Player)
- Player.CharacterAdded:Connect(function(Character)
- self:HandleCharacter(Character, Player)
- end)
- end
- function PlayerConnection:HandlePlayer(Player)
- if Player ~= LocalPlayer then
- task.spawn(function()
- Visual:Esp(Player)
- Visual:Cham(Player)
- end)
- end
- task.spawn(function() self:ConnectPlayer(Player) end)
- end
- -- SHOOT / BREAK GUN --
- local function BreakGun(Player, Notif)
- if BreakedGun or not Player then
- return Notif and Notify("Break Gun", "Try again later.", 3, Icons.Cross)
- end
- local Gun = Roles:FindGun(Player, true)
- local ShootGun = Gun and Gun.ShootGun
- if not ShootGun then return Notif and Notify("Break Gun", "Cannot find Gun.", 3, Icons.Cross) end
- local args = {
- [1] = 1,
- [2] = Vector2.new(),
- [3] = "AH2"
- }
- task.spawn(function()
- local Success, Error = pcall(function()
- ShootGun:InvokeServer(unpack(args))
- end)
- if Error then
- BreakedGun = Player.Name
- warn("[Success] : Break Gun ("..BreakedGun..")")
- end
- return Notif and Notify("Break Gun", Error and "Successfully break the Gun." or "Try again later.", 3, Error and Icons.Check or Icons.Cross)
- end)
- end
- -- LOCALPLAYER --
- local function SecondLife(boolean)
- local Humanoid = LocalPlayer.Character and LocalPlayer.Character:WaitForChild("Humanoid")
- if not Humanoid then return end
- Humanoid:SetStateEnabled(Enum.HumanoidStateType.Dead, not boolean)
- end
- local function SetTempTool(boolean)
- local Parents = {
- Character = LocalPlayer.Character,
- Backpack = LocalPlayer:FindFirstChildOfClass("Backpack")
- }
- for _,Parent in pairs(Parents) do
- if not Parent then break end
- local TemporaryTool = Parent:FindFirstChild("TempTool")
- if boolean and Parent:IsA("Backpack") then
- if not TemporaryTool then
- local Tool = Instance.new("Tool")
- Tool.Name = "TempTool"
- Tool.Parent = Parent
- end
- break
- elseif not boolean and TemporaryTool then
- TemporaryTool:Destroy()
- break
- end
- end
- end
- local function SetTpTool(boolean)
- local Parents = {
- Character = LocalPlayer.Character,
- Backpack = LocalPlayer:FindFirstChildOfClass("Backpack")
- }
- for _,Parent in pairs(Parents) do
- if not Parent then break end
- local TpTool = Parent:FindFirstChild("Teleport Tool")
- if boolean and Parent:IsA("Backpack") then
- if not TpTool then
- SetTempTool(true)
- local Tool = Instance.new("Tool")
- Tool.Name = "Teleport Tool"
- Tool.RequiresHandle = false
- Tool.Parent = Parent
- Tool.Activated:Connect(function()
- local Humanoid = LocalPlayer.Character and LocalPlayer.Character:FindFirstChildOfClass("Humanoid")
- if not Humanoid or not Humanoid.RootPart then return end
- Humanoid:ChangeState(Enum.HumanoidStateType.GettingUp)
- Humanoid.RootPart.CFrame = CFrame.new(Mouse.Hit.X, Mouse.Hit.Y + 3, Mouse.Hit.Z, select(4, Humanoid.RootPart.CFrame:components()))
- end)
- SetTempTool(false)
- end
- break
- elseif not boolean and TpTool then
- TpTool:Destroy()
- break
- end
- end
- end
- local InfiniteJumpConnection
- local function InfiniteJump()
- if InfiniteJumpConnection then
- InfiniteJumpConnection:Disconnect()
- end
- InfiniteJumpConnection = UserInputService.JumpRequest:Connect(function()
- local Humanoid = LocalPlayer.Character and LocalPlayer.Character:FindFirstChildOfClass("Humanoid")
- if Toggles.InfiniteJump and Humanoid then
- Humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
- else
- InfiniteJumpConnection:Disconnect()
- end
- end)
- end
- -- GOD MODE --
- local GodMode = {
- isGodModeProcess = false,
- lastCFrame = nil,
- isGodMode = false
- }
- function GodMode:Start(Notif)
- if Roles:GetRole(LocalPlayer) == "Murderer" or not Roles:IsAlive(LocalPlayer) or self.isGodModeProcess then
- return Notif and Notify("God Mode", "Try again later.", 3, Icons.Info)
- end
- local Humanoid = LocalPlayer.Character and LocalPlayer.Character:FindFirstChildOfClass("Humanoid")
- if not (Humanoid or Humanoid.RootPart and Humanoid.Parent:FindFirstChild("Head")) then return end
- self.isGodModeProcess = true
- self.lastCFrame = Humanoid.RootPart.CFrame
- Humanoid:SetStateEnabled(Enum.HumanoidStateType.Dead, true)
- Humanoid.Parent.Head:Destroy()
- Humanoid.Health = -9e9
- end
- -- FLING --
- local Fling = {
- isFlinging = false,
- FlingPower = 9999999e12,
- lastFlingedCFrame = nil
- }
- function Fling:Start(Player, Auto)
- task.spawn(function()
- if DontDisturb or self.isFlinging then
- if not Auto then
- return Notify("Fling Player", "Cant fling player right now.", 3, Icons.Info)
- end
- return
- end
- DontDisturb = true
- self.isFlinging = true
- local Success = false
- if not Auto then
- Timer:Start()
- end
- local theConnection
- --
- local LocalHumanoid = LocalPlayer.Character and LocalPlayer.Character:FindFirstChildOfClass("Humanoid")
- local OtherRoot = Player.Character and Player.Character.PrimaryPart
- if LocalHumanoid and LocalHumanoid.RootPart and OtherRoot then
- local lastCFrame = LocalHumanoid.RootPart.CFrame
- local lastNoclipState = Toggles.Noclip
- local lastAntiVoidState = Toggles.AntiVoid
- local function ResetCharacter()
- if Toggles.Noclip ~= lastNoclipState then Toggles.Noclip = lastNoclipState end
- if Toggles.AntiVoid ~= lastAntiVoidState then Toggles.AntiVoid = lastAntiVoidState end
- if LocalHumanoid and LocalHumanoid.RootPart and lastCFrame then
- Workspace.CurrentCamera.CameraSubject = LocalHumanoid
- LocalHumanoid:ChangeState(Enum.HumanoidStateType.GettingUp)
- LocalHumanoid.RootPart.CFrame = lastCFrame
- LocalHumanoid.RootPart.AssemblyLinearVelocity = Vector3.zero
- LocalHumanoid.RootPart.AssemblyAngularVelocity = Vector3.zero
- end
- end
- theConnection = RunService.Heartbeat:Connect(function()
- if (Auto or Timer.TimePassed < 5 and OtherRoot and OtherRoot.AssemblyLinearVelocity.Magnitude < 250) and LocalHumanoid.Parent and LocalHumanoid.RootPart and LocalHumanoid.RootPart.Parent and OtherRoot.Parent then
- Workspace.CurrentCamera.CameraSubject = OtherRoot.Parent
- Toggles.Noclip, Toggles.AntiVoid = true, true
- local Velocity = OtherRoot.AssemblyLinearVelocity
- local Prediction = OtherRoot.Position + ((Velocity * Vector3.new(1, 0, 1) * .5 + Vector3.new(0, Velocity.Y / 10, 0)) * math.random(-2, 2))
- local Velocity2 = LocalHumanoid.RootPart.AssemblyLinearVelocity
- LocalHumanoid.RootPart.CFrame = CFrame.new(Prediction.X, Prediction.Y, Prediction.Z, select(4, OtherRoot.CFrame:components()))
- LocalHumanoid.RootPart.AssemblyLinearVelocity = Vector3.new(0, -self.FlingPower, 0)
- RunService.RenderStepped:Wait()
- LocalHumanoid.RootPart.AssemblyLinearVelocity = Velocity2
- else
- ResetCharacter()
- self.isFlinging = false
- Success = true
- theConnection:Disconnect()
- theConnection = nil
- end
- end)
- end
- repeat task.wait() until not theConnection
- self.isFlinging = false
- DontDisturb = false
- if not Auto then
- Timer:Stop()
- return not Auto and Notify("Fling Player", Success and "Successfully fling Player!" or "Try again later.", 3, Success and Icons.Check or Icons.Info)
- end
- end)
- end
- --[[
- --POWER & PERKS -- !! MOSTLY BROKEN
- local Power = {}
- function Power:SetPower(PowerType, Args1)
- local Remotes = ReplicatedStorage:FindFirstChild("Remotes")
- if PowerType == "Ghost" then
- local Stealth = Remotes and Remotes:FindFirstChild("Gameplay") and Remotes.Gameplay:FindFirstChild("Stealth")
- if Stealth then
- pcall(function()
- Stealth:FireServer(Args1)
- end)
- end
- elseif PowerType == "Trap" then
- local PlaceTrap = ReplicatedStorage:FindFirstChild("TrapSystem") and ReplicatedStorage.TrapSystem:FindFirstChild("PlaceTrap")
- if PlaceTrap then
- pcall(function()
- PlaceTrap:InvokeServer(Args1)
- end)
- end
- elseif PowerType == "FakeGun" then
- local FakeGun = Remotes and Remotes:FindFirstChild("Gameplay") and Remotes.Gameplay:FindFirstChild("FakeGun")
- if FakeGun then
- pcall(function()
- FakeGun:FireServer(Args1)
- end)
- end
- elseif PowerType == "Trails" then
- local Character = LocalPlayer.Character
- local SpeedTrail = Character and Character:FindFirstChild("SpeedTrail")
- local Toggle = SpeedTrail and SpeedTrail:FindFirstChild("Toggle")
- if Toggle then
- pcall(function()
- Toggle:FireServer(Args1)
- end)
- end
- else
- return nil
- end
- end
- ]]
- -- [VISUAL] --
- local Visual_Tab = Window:MakeTab({
- Name = "Visual",
- Icon = GetIcon("eye")
- })
- local FieldOfView = SavedLocals["FOV"] or 70
- Visual_Tab:AddLabel("Visual :")
- Visual_Tab:AddToggle({
- Name = "All ESP",
- Default = false,
- Save = true,
- Flag = "All ESP",
- Callback = function(Value)
- Toggles.EnableESP = Value
- end
- })
- Visual_Tab:AddToggle({
- Name = "All Chams",
- Default = false,
- Save = true,
- Flag = "All Chams",
- Callback = function(Value)
- Toggles.EnableChams = Value
- end
- })
- Visual_Tab:AddToggle({
- Name = "Dropped Gun ESP",
- Default = false,
- Save = true,
- Flag = "Dropped Gun ESP",
- Callback = function(Value)
- Toggles.GunESP = Value
- end
- })
- Visual_Tab:AddTextbox({
- Name = "ESP Transparency [0 - 0.9]",
- Default = SavedLocals["TRANS"] or "0.7",
- TextDisappear = false,
- Callback = function(Value)
- local number = tonumber(Value)
- if number and number > -0.1 and number < 1 then
- Transparency, SavedLocals["Transparency"] = number, number
- OrionLib:SaveLocals(SavedLocals)
- else
- Notify("Invalid Input","Please try again.",3,Icons.Info)
- end
- end
- })
- Visual_Tab:AddLabel("Misc :")
- Visual_Tab:AddTextbox({
- Name = "Field Of View",
- Default = SavedLocals["FOV"] or "70",
- TextDisappear = false,
- Callback = function(Value)
- if tonumber(Value) then
- Workspace.CurrentCamera.FieldOfView, SavedLocals["FOV"] = Value, Value
- OrionLib:SaveLocals(SavedLocals)
- end
- end
- })
- Workspace.CurrentCamera.FieldOfView = SavedLocals["FOV"] or 70
- Visual_Tab:AddToggle({
- Name = "Anti Lag",
- Default = false,
- Save = true,
- Flag = "Anti Lag",
- Callback = function(Value)
- Toggles.AntiLag = Value
- local Names = {
- "Pets",
- "CoinVisualizer"
- }
- for _, Script in pairs(Names) do
- local theScript = LocalPlayer.PlayerScripts and LocalPlayer.PlayerScripts:WaitForChild(Script)
- if theScript then
- theScript.Disabled = Value
- end
- end
- if Value then
- local Folders = {
- "PetContainer",
- "Footsteps",
- "GunDisplay"
- }
- for _, Folder in pairs(FindChildsInWorkspace() or {}) do
- if Folders[Folder.Name] and Folder:IsA("Folder") then
- if Folders.Name == "GunDisplay" then
- for _, Child in pairs(Folder:GetDescendants()) do
- if Child.Name == "Chroma" and Child:IsA("Decal") then
- Visual:HandleChroma(Child)
- end
- end
- else
- Folder:ClearAllChildren()
- end
- end
- end
- for _,Player in pairs(Players:GetPlayers()) do
- local Pet = Player.Character and Player.Character:FindFirstChild("Pet")
- if Pet then Pet:Destroy() end
- end
- end
- end
- })
- -- [LOCALPLAYER] --
- local LocalPlayer_Tab = Window:MakeTab({
- Name = "LocalPlayer",
- Icon = GetIcon("person-standing")
- })
- local WalkSpeed = SavedLocals["WS"] or 16
- local JumpPower = SavedLocals["JP"] or 50
- local Gravity = 196
- LocalPlayer_Tab:AddLabel("Character :")
- LocalPlayer_Tab:AddToggle({
- Name = "Enable WalkSpeed",
- Default = false,
- Save = true,
- Flag = "Enable WalkSpeed",
- Callback = function(Value)
- Toggles.EnableWalkSpeed = Value
- if not Value then
- local Humanoid = LocalPlayer.Character and LocalPlayer.Character:FindFirstChildOfClass("Humanoid")
- if Humanoid then
- Humanoid.WalkSpeed = 16
- end
- end
- end
- })
- LocalPlayer_Tab:AddTextbox({
- Name = "WalkSpeed",
- Default = SavedLocals["WS"] or "16",
- TextDisappear = false,
- Callback = function(Value)
- if tonumber(Value) then
- WalkSpeed, SavedLocals["WS"] = Value, Value
- OrionLib:SaveLocals(SavedLocals)
- end
- end
- })
- LocalPlayer_Tab:AddToggle({
- Name = "Enable JumpPower",
- Default = false,
- Save = true,
- Flag = "Enable JumpPower",
- Callback = function(Value)
- Toggles.EnableJumpPower = Value
- if not Value then
- local Humanoid = LocalPlayer.Character and LocalPlayer.Character:FindFirstChildOfClass("Humanoid")
- if Humanoid then
- Humanoid.JumpPower = 50
- end
- end
- end
- })
- LocalPlayer_Tab:AddTextbox({
- Name = "JumpPower",
- Default = SavedLocals["JP"] or "50",
- TextDisappear = false,
- Callback = function(Value)
- if tonumber(Value) then
- JumpPower, SavedLocals["JP"] = Value, Value
- OrionLib:SaveLocals(SavedLocals)
- end
- end
- })
- LocalPlayer_Tab:AddToggle({
- Name = "Enable Gravity",
- Default = false,
- Callback = function(Value)
- Toggles.EnableGravity = Value
- Workspace.Gravity = Value and Gravity or 196
- end
- })
- LocalPlayer_Tab:AddTextbox({
- Name = "Gravity",
- Default = "196",
- TextDisappear = false,
- Callback = function(Value)
- if tonumber(Value) then
- Gravity = Value
- end
- end
- })
- LocalPlayer_Tab:AddToggle({
- Name = "Noclip",
- Default = false,
- Callback = function(Value)
- Toggles.Noclip = Value
- if not Value then
- local Humanoid = LocalPlayer.Character and LocalPlayer.Character:FindFirstChildOfClass("Humanoid")
- if Humanoid then
- Humanoid:ChangeState(Enum.HumanoidStateType.GettingUp)
- end
- end
- end
- })
- LocalPlayer_Tab:AddToggle({
- Name = "Infinite Jump",
- Default = false,
- Callback = function(Value)
- Toggles.InfiniteJump = Value
- if Value then
- InfiniteJump()
- else
- if InfiniteJumpConnection then
- InfiniteJumpConnection:Disconnect()
- end
- end
- end
- })
- LocalPlayer_Tab:AddToggle({
- Name = "Teleport Tool",
- Default = false,
- Callback = function(Value)
- Toggles.TeleportTool = Value
- SetTpTool(Value)
- end
- })
- -- [PROTECTION] --
- local Protection_Tab = Window:MakeTab({
- Name = "Protection",
- Icon = GetIcon("shield-check")
- })
- Protection_Tab:AddLabel("Protection :")
- Protection_Tab:AddToggle({
- Name = "Second Life",
- Default = false,
- Save = true,
- Flag = "Second Life",
- Callback = function(Value)
- Toggles.SecondLife = Value
- SecondLife(Value)
- end
- })
- Protection_Tab:AddToggle({
- Name = "Anti Fling",
- Default = false,
- Save = true,
- Flag = "Anti Fling",
- Callback = function(Value)
- Toggles.AntiFling = Value
- end
- })
- Protection_Tab:AddToggle({
- Name = "Anti Void",
- Default = false,
- Save = true,
- Flag = "Anti Void",
- Callback = function(Value)
- Toggles.AntiVoid = Value
- end
- })
- Protection_Tab:AddToggle({
- Name = "Anti Trap",
- Default = false,
- Save = true,
- Flag = "Anti Trap",
- Callback = function(Value)
- Toggles.AntiTrap = Value
- if Value then
- task.spawn(function()
- for _, Player in pairs(Players:GetPlayers()) do
- if Player ~= LocalPlayer and Player.Character then
- for _, Childs in pairs(Player.Character:GetChildren()) do
- if Childs.Name == "Trap" and Childs:IsA("Model") then
- task.spawn(function() PlayerConnection:BrokeTrap(Childs) end)
- end
- end
- end
- end
- end)
- end
- end
- })
- Protection_Tab:AddToggle({
- Name = "Anti Lock",
- Default = false,
- Save = true,
- Flag = "Anti Lock",
- Callback = function(Value)
- Toggles.AntiLock = Value
- end
- })
- Protection_Tab:AddToggle({
- Name = "Mute Radios",
- Default = false,
- Save = true,
- Flag = "Mute Radios",
- Callback = function(Value)
- Toggles.MuteRadios = Value
- for _, Player in pairs(Players:GetPlayers()) do
- if Player ~= LocalPlayer then
- local Sound = Player.Character and Player.Character:FindFirstChild("Radio") and Player.Character.Radio:FindFirstChildOfClass("Sound")
- if Sound then
- Sound.Volume = Value and 0 or 0.5
- end
- end
- end
- end
- })
- -- [COMBAT] --
- local Combat_Tab = Window:MakeTab({
- Name = "Combat",
- Icon = GetIcon("shield")
- })
- local PlayerToFling = nil
- Combat_Tab:AddLabel("Fling :")
- Combat_Tab:AddTextbox({
- Name = "Player to Fling :",
- Default = "",
- TextDisappear = false,
- Callback = function(Value)
- local Player = GetPlayer(Value)[1]
- if Player then
- PlayerToFling = Player
- else
- Notify("Invalid Input","Please try again.",3,Icons.Info)
- end
- end
- })
- Combat_Tab:AddButton({
- Name = "Fling Player",
- Callback = function()
- if PlayerToFling then
- Fling:Start(PlayerToFling,false)
- else
- Notify("Fling Player","Try again later.",3,Icons.Info)
- end
- end
- })
- Combat_Tab:AddButton({
- Name = "Fling Sheriff / Hero",
- Callback = function()
- local theSheriff = Players:FindFirstChild(Roles.Sheriff) or Players:FindFirstChild(Roles.Hero)
- if theSheriff and theSheriff ~= LocalPlayer then
- Fling:Start(theSheriff,false)
- else
- Notify("Fling Player","Try again later.",3,Icons.Info)
- end
- end
- })
- Combat_Tab:AddButton({
- Name = "Fling Murderer",
- Callback = function()
- local theMurderer = Players:FindFirstChild(Roles.Murderer)
- if theMurderer and theMurderer ~= LocalPlayer then
- Fling:Start(theMurderer,false)
- else
- Notify("Fling Player","Try again later.",3,Icons.Info)
- end
- end
- })
- Combat_Tab:AddLabel("Break Gun :")
- Combat_Tab:AddButton({
- Name = "Break Gun",
- Callback = function()
- local theSheriff = Players:FindFirstChild(Roles.Sheriff) or Players:FindFirstChild(Roles.Hero)
- if theSheriff and theSheriff ~= LocalPlayer then
- BreakGun(theSheriff, true)
- else
- Notify("Break Gun", theSheriff and "You can't break your own Gun!" or "Try again later.", 3, theSheriff and Icons.Info or Icons.Cross)
- end
- end
- })
- Combat_Tab:AddToggle({
- Name = "Auto Break Gun",
- Default = false,
- Save = true,
- Flag = "Auto Break Gun",
- Callback = function(Value)
- Toggles.AutoBreakGun = Value
- if Value then
- local theSheriff = Players:FindFirstChild(Roles.Sheriff) or Players:FindFirstChild(Roles.Hero)
- if theSheriff and theSheriff ~= LocalPlayer then
- BreakGun(theSheriff,false)
- end
- end
- end
- })
- Combat_Tab:AddToggle({
- Name = "Only Break Gun When Murderer",
- Default = false,
- Save = true,
- Flag = "Only Break Gun When Murderer",
- Callback = function(Value)
- Toggles.AutoBreakGunWhenMurder = Value
- if Value and Roles:GetRole(LocalPlayer) == "Murderer" then
- local theSheriff = Players:FindFirstChild(Roles.Sheriff) or Players:FindFirstChild(Roles.Hero)
- if theSheriff and theSheriff ~= LocalPlayer then
- BreakGun(theSheriff, false)
- end
- end
- end
- })
- Combat_Tab:AddLabel("Innocent :")
- Combat_Tab:AddButton({
- Name = "God Mode [Reset]",
- Callback = function()
- GodMode:Start(false)
- end
- })
- Combat_Tab:AddButton({
- Name = "Grab Gun",
- Callback = function()
- if not GrabGun.isGrabGun then
- GrabGun:Start(false)
- end
- end
- })
- Combat_Tab:AddToggle({
- Name = "Auto Grab Gun",
- Default = false,
- Save = true,
- Flag = "Auto Grab Gun",
- Callback = function(Value)
- Toggles.AutoGrabGun = Value
- if Value then
- GrabGun:Start(true)
- end
- end
- })
- -- MORE COMING SOON!
- -- [SCRIPTS] --
- Roles:UpdateRole()
- Roles:UpdateGameMode()
- for _, Player in pairs(Players:GetPlayers()) do
- PlayerConnection:HandlePlayer(Player)
- end
- Players.PlayerAdded:Connect(function(Player) PlayerConnection:HandlePlayer(Player) end)
- Players.PlayerRemoving:Connect(function(Player)
- if Player ~= LocalPlayer then
- local PlayerName = Player.Name
- for Role, Player in pairs(Roles) do
- if Player == PlayerName then
- warn("[Reset Role] : ("..PlayerName..")")
- if Player == Roles.Sheriff or Player == Roles.Hero then
- warn("[Reset BreakedGun] : ("..PlayerName..")")
- BreakedGun = nil
- end
- Roles[Role] = ""
- break
- end
- end
- local PlayerVisuals = {
- NameHolder:FindFirstChild(PlayerName),
- ChamHolder:FindFirstChild(PlayerName.."_CHM")
- }
- for _,Visual in pairs(PlayerVisuals) do
- if Visual then Visual:Destroy() end
- end
- local Connection = table.find(PlayerConnection.Connection, PlayerName.."_Connection") and PlayerConnection.Connection[Player.Name.."_Connection"]
- if Connection then Connection:Disconnect() end
- end
- end)
- CollectionService:GetInstanceAddedSignal("CoinVisual"):Connect(function(CoinVisual)
- if LocalPlayerData.CollectedCoins[CoinVisual:GetAttribute("CoinID")] and LocalPlayerData.CollectedCoins[CoinVisual:GetAttribute("CoinID")].IsFull then
- local Parent = CoinVisual.Parent
- if Parent then task.wait() Parent:Destroy() end
- end
- end)
- -- LOOPS [1 SECOND]
- local VisualHandler = {}
- function VisualHandler:HandleESP(Player, enable)
- local BillboardGui = NameHolder:FindFirstChild(Player.Name) and NameHolder[Player.Name]:FindFirstChildOfClass("BillboardGui")
- if BillboardGui then
- local Head = Player.Character and Player.Character:FindFirstChild(BillboardGui.Name)
- BillboardGui.Adornee = enable and Head or nil
- BillboardGui.Enabled = Head and enable
- end
- end
- function VisualHandler:HandleChams(Player, enable)
- local ChamFolder = ChamHolder:FindFirstChild(Player.Name.."_CHM")
- if ChamFolder then
- for _, Cham in pairs(ChamFolder:GetChildren()) do
- local Object = Player.Character and Player.Character:FindFirstChild(Cham.Name)
- Cham.Adornee = enable and Object or nil
- Cham.Size = enable and Object and Object.Size or Vector3.zero
- Cham.Visible = Object and enable or false
- Cham.Transparency = Visual.Transparency
- end
- end
- end
- function VisualHandler:HandleGunESP(enable)
- for _, Childs in pairs(GunHolder:GetChildren()) do
- if Childs:IsA("BillboardGui") then
- Childs.Enabled = enable
- else
- Childs.Visible = enable
- Childs.Transparency = Visual.Transparency
- end
- end
- end
- task.spawn(function()
- while task.wait(1) do
- Roles:UpdateRole()
- for _,v in pairs(Players:GetPlayers()) do
- local theSheriff = Players:FindFirstChild(Roles.Sheriff)
- if not theSheriff and Roles:FindGun(v, false) then
- Roles.Hero = v.Name
- end
- if Roles.Sheriff ~= "" and Roles.Hero == Roles.Sheriff then
- Roles.Hero = ""
- end
- if v ~= LocalPlayer then
- if Roles:IsAlive(v) then
- VisualHandler:HandleESP(v, Toggles.EnableESP)
- VisualHandler:HandleChams(v, Toggles.EnableChams)
- else
- VisualHandler:HandleESP(v, false)
- VisualHandler:HandleChams(v, false)
- end
- if Toggles.MuteRadios then
- local Sound = v.Character and v.Character:FindFirstChild("Radio") and v.Character.Radio:FindFirstChildOfClass("Sound")
- if Sound then
- Sound.Volume = 0
- end
- end
- end
- end
- VisualHandler:HandleGunESP(Toggles.GunESP)
- for _, CoinVisual in pairs(CollectionService:GetTagged("CoinVisual")) do
- local Parent = CoinVisual.Parent
- if Parent then
- if Parent:GetAttribute("Collected") or Parent:GetAttribute("RoundEnd") then
- Parent:Destroy()
- else
- CoinVisual.CFrame *= Toggles.AntiLag and CFrame.Angles(0, math.rad(45), 0) or CoinVisual.CFrame
- Parent.CanTouch = not Fling.isFlinging
- Parent.Size = Fling.isFlinging and Vector3.zero or Vector3.new(10, 10, 10)
- end
- end
- end
- local Character = LocalPlayer.Character
- if Character then
- local Knife = Roles:FindKnife(LocalPlayer,true)
- if Knife and Knife.Handle then
- local KnifeHandle = Knife.Handle
- KnifeHandle.Massless = true
- KnifeHandle.Anchored = false
- KnifeHandle.CanCollide = false
- KnifeHandle.Size = Vector3.new(5,5,5)
- end
- local Humanoid = Character:FindFirstChildOfClass("Humanoid")
- if Humanoid then
- if Toggles.EnableWalkSpeed and tonumber(WalkSpeed) then
- Humanoid.WalkSpeed = WalkSpeed
- end
- if Toggles.EnableJumpPower and tonumber(JumpPower) then
- Humanoid.JumpPower = JumpPower
- end
- end
- if Toggles.EnableGravity then
- Workspace.Gravity = Gravity
- end
- if Toggles.AutoBreakGun and not BreakedGun then
- if Toggles.AutoBreakGunWhenMurder and Roles:GetRole(LocalPlayer) == "Murderer" then
- local theSheriff = Players:FindFirstChild(Roles.Sheriff) or Players:FindFirstChild(Roles.Hero)
- if theSheriff and theSheriff ~= LocalPlayer then
- BreakGun(theSheriff,false)
- end
- elseif not Toggles.AutoBreakGunWhenMurder then
- local theSheriff = Players:FindFirstChild(Roles.Sheriff) or Players:FindFirstChild(Roles.Hero)
- if theSheriff and theSheriff ~= LocalPlayer then
- BreakGun(theSheriff,false)
- end
- end
- end
- end
- end
- end)
- -- Analyze Map
- Map:CheckMap()
- -- CHARACTER ADDED
- local LastCharacter = LocalPlayer.Character
- LocalPlayer.CharacterAdded:Connect(function(Character)
- if Character and Players:GetPlayerFromCharacter(Character) then
- if Character ~= LastCharacter then
- task.spawn(function()
- BreakedGun = nil
- GodMode.isGodMode = false
- -- Character Check
- LastCharacter = Character
- -- Can Shoot
- -- Second Life
- if Toggles.SecondLife then
- SecondLife(true)
- end
- -- Grab Gun [If Meet Requirements]
- if Toggles.AutoGrabGun then
- GrabGun:Start(true)
- end
- -- Teleport Tool
- if Toggles.TeleportTool then
- SetTpTool(true)
- end
- -- God Mode
- if GodMode.isGodModeProcess then
- task.spawn(function()
- repeat task.wait() until Character:FindFirstChildOfClass("Humanoid") or not Character
- local Humanoid = Character.Humanoid
- if Humanoid and Humanoid.RootPart then
- local Root = Humanoid.RootPart
- if Root and GodMode.lastCFrame then
- Root.CFrame = GodMode.lastCFrame
- Notify("God Mode","Success!", 3, Icons.Check)
- GodMode.isGodMode = true
- end
- end
- end)
- end
- GodMode.isGodModeProcess = false
- -- Toggle Ghost
- --[[ Prediction Reset
- PredictionBox.Position = Vector3.zero
- ]]
- end)
- end
- end
- end)
- -- LOOPS [STEPPED]
- RunService.Stepped:Connect(function()
- local Character = LocalPlayer.Character
- if Character then
- local Humanoid = Character and Character:FindFirstChildOfClass("Humanoid")
- local LocalRoot = Humanoid and Humanoid.RootPart
- if Toggles.Noclip then
- for _, Childs in pairs(Character:GetChildren()) do
- if Childs:IsA("BasePart") then
- Childs.CanCollide = false
- end
- end
- end
- if Toggles.AntiVoid and LocalRoot and Humanoid then
- if LocalRoot.Position.Y <= Workspace.FallenPartsDestroyHeight + 100 then
- Humanoid:ChangeState(Enum.HumanoidStateType.GettingUp)
- LocalRoot.CFrame = CFrame.new(LocalRoot.Position.X, Workspace.FallenPartsDestroyHeight + 100, LocalRoot.Position.Z, select(4, LocalRoot.CFrame:components()))
- end
- end
- if Toggles.AntiFling and LocalRoot and not Fling.isFlinging then
- if (LocalRoot.AssemblyAngularVelocity.Magnitude > 150 or LocalRoot.AssemblyLinearVelocity.Magnitude > 250) then
- if Fling.lastFlingedCFrame then
- LocalRoot.AssemblyLinearVelocity = Vector3.zero
- LocalRoot.AssemblyAngularVelocity = Vector3.zero
- LocalRoot.CFrame = Fling.lastFlingedCFrame
- end
- else
- Fling.lastFlingedCFrame = LocalRoot.CFrame
- end
- end
- end
- if Toggles.AntiFling and not Fling.isFlinging then
- for _, Player in pairs(Players:GetPlayers()) do
- if Player ~= LocalPlayer then
- local Root = Player.Character and Player.Character.PrimaryPart
- if Root and (Root.AssemblyAngularVelocity.Magnitude > 150 or Root.AssemblyLinearVelocity.Magnitude > 250) then
- Root.AssemblyLinearVelocity, Root.AssemblyAngularVelocity = Vector3.zero, Vector3.zero
- for _, Childs in pairs(Root.Parent:GetChildren()) do
- if Childs:IsA("BasePart") then
- Childs.Massless = true
- Childs.CanCollide = false
- Childs.CustomPhysicalProperties = PhysicalProperties.new(0.01, 0.01, 0.01)
- end
- end
- end
- end
- end
- end
- end)
- -- LOOPS [HEARTBEAT]
- RunService.Heartbeat:Connect(function()
- local Root = LocalPlayer.Character and LocalPlayer.Character.PrimaryPart
- if Root then
- -- Anti Lock
- if Toggles.AntiLock and not Fling.isFlinging then
- if Root then
- local lastVelocity = Root.AssemblyLinearVelocity
- Root.AssemblyLinearVelocity = Vector3.new(0, -200, 0)
- RunService.RenderStepped:Wait()
- Root.AssemblyLinearVelocity = lastVelocity
- end
- end
- end
- end)
- task.spawn(function()
- -- Anti Lag
- local Folders = {
- "PetContainer",
- "Footsteps",
- "GunDisplay"
- }
- for _, Folder in pairs(FindChildsInWorkspace() or {}) do
- if Folders[Folder.Name] and Folder:IsA("Folder") then
- if Folders.Name == "GunDisplay" then
- Folder.DescendantAdded:Connect(function(Child)
- if Child.Name == "Chroma" and Child:IsA("Decal") and Toggles.AntiLag then
- task.wait()
- Visual:HandleChroma(Child)
- end
- end)
- else
- Folder.ChildAdded:Connect(function(Child)
- if Toggles.AntiLag then
- task.wait()
- Folder:ClearAllChildren()
- end
- end)
- end
- end
- end
- -- Game Logic
- local RemotesName = {
- "CoinsStarted",
- "CoinCollected",
- "LoadingMap"
- }
- local GamePlay = ReplicatedStorage:WaitForChild("Remotes") and ReplicatedStorage.Remotes:WaitForChild("Gameplay")
- if GamePlay then
- for _,Name in pairs(RemotesName) do
- local Remote = GamePlay:WaitForChild(Name)
- if Remote then
- if Name == "CoinsStarted" then
- Remote.OnClientEvent:Connect(function()
- LocalPlayerData.CollectedCoins = {}
- end)
- elseif Name == "CoinCollected" then
- Remote.OnClientEvent:Connect(function(...)
- local Args = {...}
- local CoinType = Args[1]
- local CoinCollected = Args[2]
- local CoinBagLimit = Args[3]
- if CoinBagLimit <= CoinCollected then
- print(CoinType, "Bag is Full! Limit :", CoinBagLimit)
- LocalPlayerData.CollectedCoins[CoinType] = {IsFull = true, Limit = CoinBagLimit}
- for _,CoinVisual in pairs(CollectionService:GetTagged("CoinVisual")) do
- if CoinVisual:GetAttribute("CoinID") == CoinType and CoinVisual.Parent then
- CoinVisual.Parent:Destroy()
- end
- end
- end
- end)
- elseif Name == "LoadingMap" then
- Remote.OnClientEvent:Connect(function(...)
- local Args = {...}
- local GameMode = Args[1]
- Roles.CurrentGameMode = GameMode
- print("Current Game Mode:",Roles.CurrentGameMode)
- end)
- end
- end
- end
- end
- end)
- -- MORE COMING SOON!
- Notify("Script Loaded.","Enjoy!",5,Icons.ThumbsUp)
- warn("Loaded : 2 / 2 ✅")
- OrionLib:Init()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement