
2.1k Views
75.0k Executions
Shiftlock for mobile
10K executions
Universal Script 📌
bruwo10K executions
9 months ago
Please login to perform these actions:Does it work?
No reports yetNo reports yet. Tried it? Be the first to say.
Also noticed:
Description
works even in games that don't have shiftlock pls tell me if you have any trouble using it
local Players = game:GetService("Players")
local RunService = game:GetService("RunService")
local UserInputService = game:GetService("UserInputService")
local Player = Players.LocalPlayer
local Camera = workspace.CurrentCamera
local ScreenGui = Instance.new("ScreenGui")
ScreenGui.Name = "MobileShiftlockGUI"
ScreenGui.ResetOnSpawn = false
ScreenGui.Parent = Player:WaitForChild("PlayerGui")
local ToggleButton = Instance.new("ImageButton")
ToggleButton.Name = "ShiftlockButton"
ToggleButton.Parent = ScreenGui
ToggleButton.BackgroundTransparency = 1
ToggleButton.Size = UDim2.new(0, 60, 0, 60)
ToggleButton.Position = UDim2.new(0.85, -30, 0.5, -30)
ToggleButton.Image = "rbxasset://textures/ui/mouseLock_off@2x.png"
local dragging
local dragInput
local dragStart
local startPos
local function update(input)
local delta = input.Position - dragStart
ToggleButton.Position = UDim2.new(startPos.X.Scale, startPos.X.Offset + delta.X, startPos.Y.Scale, startPos.Y.Offset + delta.Y)
end
ToggleButton.InputBegan:Connect(function(input)
if input.UserInputType == Enum.UserInputType.MouseButton1 or input.UserInputType == Enum.UserInputType.Touch then
dragging = true
dragStart = input.Position
startPos = ToggleButton.Position
input.Changed:Connect(function()
if input.UserInputState == Enum.UserInputState.End then
dragging = false
end
end)









Add like a x button to remove it
You able to make it draggable?! Gets in the way cause of the size
@RobinsonF Just updated it!
@bruwo shoot awesome!! thank you for you incredible work:)