Basically what i want is a button where it says "Unbound" and when you click it, it says "Press any key...", then when you click any key on your keyboard the buttons text will change to the key you pressed, pretty much like a bind key button, oh and add in a "chat.AddText('Works!')" when you click the binded key, if you want, and yes i know i'm asking for alot, i'm very sorry, i'm just really bad at lua, oh, and the reason why i'm asking for this is because i have a menu on my server that allows you to buy items, and i want to add a bind key button instead of doing "bind p sw_shop" in console to toggle the menu.
[CODE]
local frame = vgui.Create( "DFrame" )
frame:SetSize( 300, 250 )
frame:Center()
frame:SetTitle("")
frame:MakePopup()
local button = vgui.Create( "DButton", frame )
button:SetText( "" )
button:SetPos( 25, 50 )
button:SetSize( 250, 30 )
[/CODE]
Thank you for your help & support.
[URL="https://facepunch.com/showthread.php?t=1251673"]You guys are hurting garry's feelings every time you don't read the sticky :([/URL]
Also, if you want something made for you, [URL="https://www.gmodstore.com/jobs/"]this would be a more fitting place[/URL]
Sorry, you need to Log In to post a reply to this thread.