I want to change the mouse icon. I try to even force the mouse icon, does not change
game["Run Service"].Heartbeat:Connect(function()
game.UserInputService.MouseIcon = "rbxassetid://15245649109"
print(game.UserInputService.MouseIcon)
end)
Expected behavior
The mouse icon to change when I tell it to
2 Likes
Try this :
local player = game:GetService("Players").LocalPlayer
local mouse = player:GetMouse()
mouse.Icon = "rbxassetid://15245649109" -- Change to whatever icon you like
PS : This is not a Studio bug, use script support next time
1 Like
This does not work
Can see it sets it for a split second before reverting back to default for no reason
And even if it did work effectively, GetMouse() is deprecated and Mouse.Icon will be deprecated
Can’t help you more then.
It seems like you have the same problem as this guy.
Everyone else got their mouse changed except you
What do you want to achieve? I am trying to change the mouse’s icon.
What is the issue? Whenever I try to change it, it just stays as the default.
What solutions have you tried so far? I am trying to use mouse.Icon
Here is the code:
local player = game.Players.LocalPlayer
local mouse = player:GetMouse()
mouse.Icon = "http://www.roblox.com/asset/?id=5923963876"
For some reason, it just stays the same. This script is a local script inside of PlayerGui. I am trying to play test in stu…
It’s undocumented, but you have to wait until the end of the current frame so input can be processed.
You can try this.
local function SetMouseIcon(Icon: string)
UserInputService.MouseIcon = Icon
end
task.defer(SetMouseIcon, "rbxassetid://15245649109")
Hey, thanks for the report, just forwarded this to the team!
We tested this, should be working fine, is everything good on your end?
1 Like
MetaVars
(MetaVars)
July 30, 2024, 9:02pm
#8
It works with other assets, but not with the one provided.
E.g. rbxassetid://14891607998 loads correctly.
system
(system)
Closed
August 13, 2024, 9:02pm
#9
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.