local UserInputService = game:GetService("UserInputService")
local Players = game:GetService("Players")
local player = Players.LocalPlayer
UserInputService.JumpRequest:Connect(function()
local character = player.Character
if character and character:FindFirstChild("Humanoid") then
character.Humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
end
end)local player = game.Players.LocalPlayer
local noclip = false
-- Create button
local screenGui = Instance.new("ScreenGui")
screenGui.Parent = player:WaitForChild("PlayerGui")
local button = Instance.new("TextButton")
button.Size = UDim2.new(0, 150, 0, 50)
button.Position = UDim2.new(0, 20, 0, 20)
button.Text = "Noclip: OFF"
button.Parent = screenGui
button.MouseButton1Click:Connect(function()
noclip = not noclip
button.Text = noclip and "Noclip: ON" or "Noclip: OFF"
end)
game:GetService("RunService").Stepped:Connect(function()
if noclip and player.Character then
for _, part in pairs(player.Character:GetDescendants()) do
if part:IsA("BasePart") then
part.CanCollide = false
end
end
end
end)local player = game.Players.LocalPlayer
local antiFling = false
local gui = Instance.new("ScreenGui")
gui.Parent = player:WaitForChild("PlayerGui")
local button = Instance.new("TextButton")
button.Size = UDim2.new(0, 150, 0, 50)
button.Position = UDim2.new(0, 20, 0, 80)
button.Text = "AntiFling: OFF"
button.Parent = gui
button.MouseButton1Click:Connect(function()
antiFling = not antiFling
button.Text = antiFling and "AntiFling: ON" or "AntiFling: OFF"
end)
game:GetService("RunService").Heartbeat:Connect(function()
if antiFling and player.Character then
local hrp = player.Character:FindFirstChild("HumanoidRootPart")
if hrp and hrp.AssemblyLinearVelocity.Magnitude > 100 then
hrp.AssemblyLinearVelocity = Vector3.zero
hrp.AssemblyAngularVelocity = Vector3.zero
end
end
end)local tool = script.Parent
local player = game.Players.LocalPlayer
local mouse = player:GetMouse()
tool.Activated:Connect(function()
local character = player.Character
if not character then return end
local origin = character.Head.Position
local direction = (mouse.Hit.Position - origin).Unit * 500
local params = RaycastParams.new()
params.FilterDescendantsInstances = {character}
params.FilterType = Enum.RaycastFilterType.Exclude
local result = workspace:Raycast(origin, direction, params)
if result then
print("Hit:", result.Instance.Name)
end
end)
Comments
im new im sorry