Is there anyway to stop User Input Service from activating when a player is typing? I know there is but I can't remember how to do it.
Thanks for reading
game:GetService("UserInputService").InputBegan:connect(function(input,processed) -- code end)
There are two arguments given with an inputbegan function. The first, input, just gives you the input, whilst the one I have put as processed checks if the game is processing it (i.e. chatting).
Therefore, you'd just check if it wasn't processed by the game with, if not processed then
.
Yes, you can use something like gameProcessedEvent
, which i use alot. An example is shown here:
UIS.InputBegan:Connect(function(Input, gameProcessedEvent) if not gameProcessedEvent then -- detects if the player is typing -- rest of your code end end)