So I tried to create this script where it allows players to do combat combos, but every time I press " Q ", no animation track plays. Im missing the animation thing. But still didn't work with it somi took it out. Do u know why my script isnt working?

local Player = game.Players.LocalPlayer
local UIS = game:GetService("UserInputService")
local Last_Press = tick()
local Combo = 1

UIS.InputBegan:Connect(function(Input, GPE)
    if GPE then
        --
    elseif Input.KeyCode == Enum.KeyCode.Q then
        if Combo == 1 and tick() - Last_Press <= 2 then
            Combo = 2
            print(Combo)
        elseif Combo == 2 and tick() - Last_Press <= 2 then
            Combo = 3
            print(Combo)
        elseif Combo == 3 and tick() - Last_Press <= 2 then
            Combo = 4
            print(Combo)
        elseif Combo == 4 and tick() - Last_Press <= 2 then
            Combo = 1
            print(Combo)
        end
        Last_Press = tick()
    end
end) 

2 comments

0

Can you edit your post to make the script in the proper format, its rather hard to read

0

Ok