Universal Script πŸ“Œ
952 Views
1.7k Executions

Rotation Lock

Universal Script πŸ“Œ
vincent009
vincent00910 followers
8 months ago
Get an executor
Please login to perform these actions:

Does it work?

No reports yet

No reports yet. Tried it? Be the first to say.

Also noticed:

Description

This script forces the player’s screen orientation to stay locked in LandscapeRight (Left because the landscaping is reverse) It works by: getting the local player and their PlayerGui setting a target orientation with Enum.ScreenOrientation.LandscapeRight repeatedly reapplying that orientation every frame using RunService.RenderStepped That means even if the game or device tries to change the orientation, this script keeps it fixed. The comment notes that you can switch it to LandscapeLeft by changing Right to Left. Auto execute is recommended for no annoying auto tilting for mobile Better version of @majwejner script Enjoy the script!

View Raw
local Players = game:GetService("Players")
local RunService = game:GetService("RunService")

local player = Players.LocalPlayer
local playerGui = player:WaitForChild("PlayerGui")

local LOCK_ORIENTATION = Enum.ScreenOrientation.LandscapeRight -- change the "Right" to "Left" if you don't like the way it set

RunService.RenderStepped:Connect(function()
    playerGui.ScreenOrientation = LOCK_ORIENTATION
end)


Comments

0
Log in to join the conversation. Login
No comments yet. Be the first!

Tags

More universal scripts

See all
Script hub
63.4k
293.2k
Bumped 1 hour ago
Key System
Script hub
3.0M
19.6M
Bumped 2 hours ago

Script hub

Hall of Fame #1

KeylessVerified script badgeYARHM Hub KEYLESS 2026

Script hub
120.5k
213.6k
Bumped 2 hours ago
Key System
Universal Script πŸ“Œ
6.7k
10.9k
Bumped 2 hours ago