Chaz-CR Posted June 28, 2013 Posted June 28, 2013 Hola, simplemente me gustaria bindear una misma letra asi como abre un panel cerrarlo sin necesidad de tocar un boton (cerrar) Gracias. aca el ejemplo de abrir un panel etc. addEventHandler("onClientResourceStart", resourceRoot, function() bindKey("r", "down", clientToggleRadio)
Castillo Posted June 28, 2013 Posted June 28, 2013 El panel es GUI? si es asi, entonces usa guiGetVisible para obtener el estado, si esta visible, lo ocultas, y si no, lo mostras.
~ProtoN! Posted June 29, 2013 Posted June 29, 2013 Espero que esto te ayude c: estado = 0 addEventHandler("onClientResourceStart", resourceRoot, function() bindKey("r", "down", function() if estado == 0 then radio = playSound("linkdelaradio") setSoundVolume(radio, 100) setRadioChannel(0) estado = 1 elseif estado == 1 then stopSound(radio) estado = 0 end
Recommended Posts