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

How do i make a combo using UIS?

Asked by
oSyM8V3N 429 Moderation Voter
7 years ago

For ex a player has to click EEQ to do a certain move or animation

1 answer

Log in to vote
1
Answered by
blowup999 659 Moderation Voter
7 years ago
local UIS = game:GetService("UserInputService")
local keys = {}

UIS.InputBegan:connect(function(key)
    table.insert(keys, {key, tick()}
    if tick() - keys[#keys - 2][2] < 1 then
        if keys[#keys - 2][1].KeyCode == Enum.KeyCode.E then
            if keys[#keys - 1][1].KeyCode == Enum.KeyCode.E then
                if keys[#keys][1].KeyCode == Enum.KeyCode.Q then
                    --Combo
                end
            end
        end
    end
end)


0
Line 6 has an error oSyM8V3N 429 — 7y
0
nvm i fixed it thx oSyM8V3N 429 — 7y
Ad

Answer this question