Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

How can I change the shift lock logo?

I want the logo of shift lock to change from the circle to the default mouse. Any ways I can go by doing this?

1 answer

✓ Accepted answer

You can manually impose a new Icon for the Cursor using 'mouse.Icon' to set a new Image ID. You'll have to set and reverse this every time you press Shift to make sure it doesn't follow through permanently. - This can be achieved through UserInputService.

--// Local Script - Preferably located in StarterPlayerScripts

local Player = game:GetService("Players").LocalPlayer
local Cursor = Player:GetMouse() --// Get Cursor from LocalPlayer
local CursorIcon = 'rbxassetid://##ID##' --// Cursor Icon ID

local UserInputService = game:GetService("UserInputService")
local Toggled = false

UserInputService.InputBegan:Connect(function(InputObject, GameProcessed)
	if (InputObject.UserInputType == Enum.UserInputType.Keyboard) then
		if (InputObject.KeyCode == Enum.KeyCode.LeftShift)  then
			if (GameProcessed) then return end
			if not (Toggled) then
				Cursor.Icon = CursorIcon; Toggled = true
			return end
			Toggled = false
			Cursor.Icon = ""
		end
	end
end)

Hope this helps! if so, don't forget to accept this answer!

1 comment

0

I've amended this answer, it wasn't properly function though is now!

This discussion is preserved as it was. New answers, comments, and votes are closed.