How do I make like this in mobile I wanna put when it's equip

I want is to pop up this when my gun is equipped for mobile
Screenshot_2023_0825_115602

You could try:

local Tool = script.Parent

Tool.Equipped:Connect(function()
           -- Enable GUI
end)
1 Like

Here is solution for it:

-- local script

local gui = -- your gui here
local uis = game:GetService("UserInputService")

ismobile = uis.TouchEnabled

gui.Visible = ismobile

1 Like

Are you talking about this?
image

if you are

make it so that it will show up if you open the tool and if your in mobile(use a better function)

function getplatform()
    local GuiService = game:GetService("GuiService")
local UserInputService = game:GetService("UserInputService")
    if (GuiService:IsTenFootInterface()) then
        return "Console"
    elseif (UserInputService.TouchEnabled and not UserInputService.MouseEnabled) then
        --touchscreen computers now have touchenabled so make sure to check for lack of mouse too
		--also, not all phones/tablets have accelerometer and/or gyroscope
        local DeviceSize = workspace.CurrentCamera.ViewportSize; 
		if ( DeviceSize.Y > 600 ) then
			return "Tablet"
		else
			return "Phone"
		end
    else
        return "Desktop"
    end
end

local path = "put tool path here"
local gui = "put gui path here"

-- triggers when equipped
Tool.Equipped:Connect(function()
if getplatform() == "Phone" then
-- shows gui
gui.Visible = true
end
end)

Tool.Unequipped:Connect(function()
if getplatform() == "Phone" then
-- hides gui
gui.Visible = false
end
end)
if not

mabye you are talking about this
image

if you are

use context action service

tutorial

if still not

then i dont know what are you talking about
describe it better

also please reply

1 Like