FuriouZ Posted September 29, 2013 Posted September 29, 2013 Hey! I have a question, how to bind key like scoreboard ? I mean how to do that if i hold eg: x down,then it shows gui and if i release button then it hides a gui ? I hope that you understang, what i mean and thanks Homepage @ http://rageresources.blogspot.com/ Offical Facebook @ https://www.facebook.com/pages/Rage-Scr ... fref=photo
glowdemon1 Posted September 29, 2013 Posted September 29, 2013 https://wiki.multitheftauto.com/wiki/BindKey Couple of examples are inside. bindKey ( player, "F1", "down", showGUI ) bindKey ( player, "F1", "up", deleteGUI ) Something like this. MySQL based MP3 System - unique radio stations My mappings
~Gangsta~ Posted September 29, 2013 Posted September 29, 2013 bindKey ( "--button--", "both", --function name-- ) ?
Khalil Posted September 29, 2013 Posted September 29, 2013 No. Use this to show the GUI bindKey ( "--button--", "down", showGUI ) Then this to hide it bindKey ( "--button--", "up", hideGUI ) Level 3 admin on RRC:RPG.
Castillo Posted September 29, 2013 Posted September 29, 2013 What's the problem of using the "both" state? San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
FuriouZ Posted September 29, 2013 Author Posted September 29, 2013 Thanks glowdemon1 ! But i have another question too, Is possible to unbind arrow up,down,left and right onPlayerJoin ? Homepage @ http://rageresources.blogspot.com/ Offical Facebook @ https://www.facebook.com/pages/Rage-Scr ... fref=photo
glowdemon1 Posted September 29, 2013 Posted September 29, 2013 https://wiki.multitheftauto.com/wiki/UnbindKey - read it carefuly tho. MySQL based MP3 System - unique radio stations My mappings
FuriouZ Posted September 29, 2013 Author Posted September 29, 2013 https://wiki.multitheftauto.com/wiki/UnbindKey - read it carefuly tho. I still don't get it what is Bad Argument .. Debug says "bad argument @ unbindkey Server: local root = getRootElement() function unBindKeys ( ) unbindKey ( thePlayer, "arrow_up", "both") unbindKey ( thePlayer, "arrow_down", "both") unbindKey ( thePlayer, "arrow_left", "both") unbindKey ( thePlayer, "arrow_right", "both") end addEventHandler ( "onPlayerSpawn", root, unBindKeys ) addEventHandler ( "onPlayerJoin", root, unBindKeys ) addEventHandler ( "onPlayerLogin", root, unBindKeys ) Homepage @ http://rageresources.blogspot.com/ Offical Facebook @ https://www.facebook.com/pages/Rage-Scr ... fref=photo
Castillo Posted September 29, 2013 Posted September 29, 2013 'thePlayer' is not defined anywhere, change it to 'source'. San Andreas Utopia RPG (SAUR) Owner & Developer. Education is the most powerful weapon which you can use to change the world.
glowdemon1 Posted September 29, 2013 Posted September 29, 2013 "Note: unbindKey will only work on binds that were added by the same resource" - In other words,I'm afraid it's impossible, unless the resource itself bound the keys. MySQL based MP3 System - unique radio stations My mappings
FuriouZ Posted September 29, 2013 Author Posted September 29, 2013 "Note: unbindKey will only work on binds that were added by the same resource"- In other words,I'm afraid it's impossible, unless the resource itself bound the keys. So, i can't unbind MTA default binds ? Homepage @ http://rageresources.blogspot.com/ Offical Facebook @ https://www.facebook.com/pages/Rage-Scr ... fref=photo
denny199 Posted September 29, 2013 Posted September 29, 2013 Use https://wiki.multitheftauto.com/wiki/ToggleControl for that. Control names: https://wiki.multitheftauto.com/wiki/Control_names Sometimes I dream about cheese
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now