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

How can I tap a key to enter and tap the same key to exit?

Asked by 3 years ago

What am I trying to do I'm trying to make a key press in same key press out. I've used :byte() but that hasn't worked (I think its a problem with pressing the same key because using other keys work). Here's my script

elseif string.lower(Key) == "q" then
        if Humanoid.WalkSpeed < 8 then 
            AimIn()
        elseif Humanoid.WalkSpeed > 8 or GunReload == true then
            AimStop()
        end 

    end 
    elseif Key:byte() == 48 and Equipped == true then
        AimStop()
    elseif Key:byte() == 48 and Equipped == nil then
        AimStop()
    end
0
why not use UserInputService instead? kkfilms_1 68 — 3y
0
Because I dont want to. Zendex32 -2 — 3y

Answer this question