#Overhead System not detecting mobile?

1 messages · Page 1 of 1 (latest)

opaque bloom
#

My overhead system isn’t detecting mobile players correctly. When I test in Roblox Studio using the mobile emulator, it works fine, but when I play on my actual phone, it still shows the desktop icon instead of mobile. Any idea why?

hard bear
#

I take it this is the problem code? it looks about right: ```lua
if OVSettings.MainSettings.DeviceDisplay then
local devicesFrameClone = script.Devices:Clone()
devicesFrameClone.Parent = billBoardGuiClone

    local deviceImageLabel = devicesFrameClone:WaitForChild("Device")
    if deviceImageLabel then
        if UserInputService.TouchEnabled == true then
            deviceImageLabel.Image = "rbxassetid://16624149840"
        elseif UserInputService.GamepadEnabled == true then
            deviceImageLabel.Image = "rbxassetid://16624150956"
        elseif UserInputService.VREnabled == true then
            deviceImageLabel.Image = "rbxassetid://16624144834"
        elseif UserInputService.MouseEnabled == true then
            deviceImageLabel.Image = "rbxassetid://16624148448"
        end
    end
end```
#

touchenabled is checked first so that's good

#

maybe add some prints in there to see whats going on

opaque bloom
#

ill add some prints to see what it’s actually detecting on my phone ill lyk

hard bear
#

may need to make them warns instead of prints so they show up in the live error console on the dashboard since you can only really test it on a physical phone in the roblox player

#

and phone doesnt have dev console

opaque bloom
#

it does on ios i think

#

yea if u go to settings and scroll down theres a dev console

wary canopyBOT
#

studio** You are now Level 1! **studio

opaque bloom
#

i think it might be because the script is server sided

hard bear
opaque bloom
#

i found out btw

hard bear