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

Gamepad Controls Not Working! Can Anyone Help Me?

Asked by 9 years ago

So i was making gamepad controls for my Gun and it doesn't come up with red lines but it wont work when i play the game heres the script to show:

01--------------------------------------------------------------------------------------
02--------------------[ GAMEPAD CONTROLS ]------------------------------------------
03--------------------------------------------------------------------------------------
04local userInputService = game:GetService("UserInputService")
05userInputService.InputChanged:connect(function(input, processed)
06    if input.UserInputType == Enum.UserInputType.Gamepad1 then
07        if input.KeyCode == Enum.KeyCode.ButtonX then
08           if (not Reloading) and (not Running) then
09            Reload()
10        elseif input.KeyCode == Enum.KeyCode.ButtonB and S.CanKnife then
11            if KnifeReady and (not Knifing) and (not ThrowingGrenade) then
12            if Aimed then UnAimGun(true) end
13            BreakReload = true
14            Knifing = true
15            KnifeReady = false
View all 45 lines...
0
Is there any output? We can't know if there's an error unless you tell us your output lightpower26 399 — 9y
0
it doesnt show an output Thegrimdeathzombie 40 — 9y
0
Does using the gamepad actually work? Because it might be that your gamepad isn't connected to the computer properly. TheDeadlyPanther 2460 — 9y
0
it is connected Thegrimdeathzombie 40 — 9y

Answer this question