Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Mobile support buttons script?

Asked by 5 years ago

I have that script for a button,that if you click it it's like a mouse click,one for left click,and other for right click. The button appears,but it doesn't works,Why?
I'm doing this because i have a fps gun model,and it doesn't fire in mobile.This is a local script in starter gui:

local contextActionService = game:GetService("ContextActionService")
function onButtonPress()
    MouseCLick
local mobilebutton = contextActionService:BindAction("FireButton",onButtonPress,true,"d")
contextActionService:SetPosition("FireButton",UDim2.new(0.72,-25,0.20,-25))
contextActionService:SetImage("FireButton","http://www.roblox.com/asset/?id=68437731")
0
Any errors? Potatofoox 129 — 5y

Answer this question