Hi All,
I’m making a game and currently i have a placement script for placing items ingame, it’s fine on keyboard and mouse and console but terrible on tablet/mobile. When placing an item it jumps to where the button is when trying to place it. Please see video
My scripts are as follows:
if youre detecting touch input through userinputservice then you should terminate the function if the second argument from inputbegan or touchbegan is true
if youre already doing this then check that the button is active and interactible so it actually sinks input
and to support dynamic thumbstick you should deny all touch inputs that are in the bottom left corner of the screen
-- this second argument signifies if the input is outside of the game
UserInputService.InputBegan:Connect(function(input, gameProcessed)
if gameProcessed then return end
-- other code to move the block and whatever
end)
I had the same problem when i was making a placement system. What i did is that whenever the player requests to place an item, the block becomes stuck in place so that the object cannot move unless the player requests to place it in a different spot. Before adjusting the objects position, you should check if it’s already locked in place.