I’m looking to make a game Gamepad-Only (Controller-Only), meaning that Keyboard inputs will not do anything.
then make userinputservice or contextactionservice or whatever input detector youre using only respond to controller only inputs like buttonA through seeing if its in a hashmap of controller only inputs the continuing if it is
i suck at explaining so heres a code snippet
local controllerInputs = {
ButtonA = true,
-- other controller inputs
}
userinputservice.InputBegan:Connect(function(input)
if controllerInputs[input] then
-- do controller stuff
end
end
I’d like Keyboard and Mouse inputs to not register though (ex. pressing W won’t move you forward, holding right-click won’t rotate your camera, etc.)
I’ve tried deleting some of the modules responsible for the player’s movement but it doesn’t seem to have an effect.
fork the modules and delete the moveto in them when a key is pressed, also for camera I did it in the past by forking the modules and keeping them empty, I dont remember if I did other steps
edit: I think I wrote a custom camera script but I dont remember exactly
when you load into a game go into starter player scripts and find the playermodule and copy it into your own starterplayerscripts. Find the keyboard under the controlmodule and around line 100 just delete the handmove functions insides.
Worked. Thanks.
Some more characters needed
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.