Simple Custom Mouse script not working?

Simple Custom Mouse not working?

Hello scripting supporters! I designed a custom mouse that I would like to use in my game so I scripted a little simple script though to my surprise it isn’t working and no errors seem to appear. I hope someone got a fix to this.

The script:

local mouse = game.Players.LocalPlayer:GetMouse()
mouse.Icon = "http://www.roblox.com/asset?id=9734070956"

Thanks for reading!

1 Like

I have the same issue, don’t know if it might be a possible bug tho

1 Like

I’m pretty sure this is because you are using a Content-Deleted icon.

It’s working for me. Just find a different image.

Hope this helps

2 Likes

I already tried a different image and still didn’t work and also it’s not Content-Deleted CustomCursor - Roblox

try using rbxassetid instead.

local mouse = game.Players.LocalPlayer:GetMouse()
mouse.Icon = "rbxassetid://9734070956"
1 Like

I tried it but sadly still not working.

where did you place the script and did you make it local?

Do what @Kaid3n22 gave but with the id 9734070900 (That is the correct id, roblox handles images weirdly)

What is happening here is that 9734070956 is the decal id which roblox automatically converts in studio but not when it is set by code.

9734070956 is actually XML to the true id 9734070900.
9734070900 is the image id.

The script is local and I placed it inside a ScreenGui that is inside StarterGui.

Try using a purchasable one instead. Like this:Mouse Icon - Roblox

Also place the localscript in starterplayerscripts

Thanks a lot this made it work!

Can you give me a clear explanation of how you found the true id?

(You can easily get the true id by pasting the decal id inside of an ImageLabel.Image but I wasn’t inside of Studio at the time so)

I used https://assetdelivery.roblox.com/v1/asset?assetId=(AssetId) to download the XML
This is what you will see inside of the XML.

But how do I exactly put the asset ID into asset delivery?

Might be a better solution for you but

https://assetdelivery.roblox.com/v1/asset?assetId=ReplaceThisWithYourAssetid
e.g. https://assetdelivery.roblox.com/v1/asset?assetId=9734070956

Alright, I see! Thanks a lot for putting time and effort into helping me!