This example serves to toggle buttons using keystrokes

Aquí pueden poner todos los programas y utilidades que hayan creado con AMS.
يخدم هذا المثال ل تبديل أزرار باستخدام ضربات المفاتيح
This example serves to toggle buttons using keystrokes
Este ejemplo sirve para activar o desactivar botones utilizando combinaciones de teclas
HIDE: ON
Hidebb Message Hidden Description
!TmE4hA7_6hGUNc4EqF815zbQMNYawSBp7nqf4pmJwPs
What do you mean toggle button using keystrokes is no longer a button if its listening to a keystroke it become more of a command action, two different means really unless you mean its a exable to show a keystroke enabling and disabling a toggle button.


Also what is with this key bull shit, if you made these example or passing example on what are on the ineternet stop locking them with keys.
On Show add
TestForEnable = 0;
TestForDisable = 0;


And change your functions like so.

if e_Modifiers.ctrl and e_Key == 70 then --Press ctrl + "F"  
TestForEnable = TestForEnable + 1;
elseif e_Key == 85 then --letter "U"
TestForEnable = TestForEnable + 1;
elseif e_Key == 67 then --letter "C"
TestForEnable = TestForEnable + 1;
elseif e_Key == 75 then --letter "K"
TestForEnable = TestForEnable+ 1;
if(TestForEnable == 4)then
xButton.SetEnabled("xButton1", true);
-- Reset TestForEnable
TestForEnable = 0;
end
end


This means the user can't just press K and D to enable and disable the buttons like you had it before.
and to make it a little more complex you could also create a timer what resets TestForEnable and disabled
the timer after the modifer as been enabled.
Graças
fffffffffffffffffffff
thanxxxxxx
thanksssss
AMIGO BOM DE