As the title says, I am trying to get the Custom Mouse to work in First person. I have tried different codes but they all don’t work. It works for a second, and turns back to Normal Roblox Cursor. I tried to loop it but it seems to not work when game.StarterPlayer.CameraMode is set to LockFirstPerson. Any idea how I can fix this?
1 Like
(It’s not CameraMode cause I did all the checking and it still doesn’t work)
You can try to hide the default mouse cursor and create a custom cursor with “ImageLabel”, and setting “ImageLabel” position to your mouse. You can hide the mouse cursor with the below code:
local UserInputService = game:GetService("UserInputService")
UserInputService.MouseIconEnabled = false
I have also created a script for you:
local RunService = game:GetService("RunService")
local UserInputService = game:GetService("UserInputService")
local Player = game.Players.LocalPlayer
local ScreenGui = Instance.new("ScreenGui", Player.PlayerGui)
local ImageLabel = Instance.new("ImageLabel", ScreenGui)
RunService.RenderStepped:Connect(function()
local Mouse = Player:GetMouse()
local X = Mouse.X
local Y = Mouse.Y
UserInputService.MouseIconEnabled = false
ImageLabel.Image = "rbxassetid://9208578430"
ImageLabel.AnchorPoint = Vector2.new(0.5, 0.5)
ImageLabel.Position = UDim2.new(0, X, 0, Y)
ImageLabel.Visible = true
ImageLabel.Size = UDim2.new(0, 10, 0, 10)
end)
3 Likes