diff --git a/LUA-Keybinds.md b/LUA-Keybinds.md index 202e085..5e1cae3 100644 --- a/LUA-Keybinds.md +++ b/LUA-Keybinds.md @@ -9,7 +9,7 @@ The Keybind module allows you to execute pieces of script when a certain key or Creates a keybind using the given variables. #### Syntax: ```lua -SetKeybind(string name, string hotkey, PressType pressType function function, [params]); +SetKeybind(string name, string hotkey, PressType pressType function function, [params]) ``` ##### Required arguments - **name:** A name to identify the keybind by @@ -25,21 +25,21 @@ SetKeybind(string name, string hotkey, PressType pressType function function, [p ```lua -- Simply call a method function kbTest() - print("oohai!"); + print("oohai!") end -Keybind.SetKeybind("test1", "SHIFT+D", kbTest); +Keybind.SetKeybind("test1", "SHIFT+D", kbTest) -- Call a method with argument(s) function kbTest2(message) - print(message); + print(message) end -Keybind.SetKeybind("test2", "SHIFT+F", kbTest2, "hello!!!"); +Keybind.SetKeybind("test2", "SHIFT+F", kbTest2, "hello!!!") ``` --- ### RemoveKeybind Removes an existing keybind. ```lua -RemoveKeybind(string name); +RemoveKeybind(string name) ``` ##### Required arguments - **name:** The name of the keybind to remove @@ -48,8 +48,8 @@ RemoveKeybind(string name); ```lua function kbTest() -- As a test, remove the keybind after being pressed once - Keybind.RemoveKeybind("test"); + Keybind.RemoveKeybind("test") end -Keybind.SetKeybind("test", "SHIFT+F", kbTest); +Keybind.SetKeybind("test", "SHIFT+F", kbTest) ``` --- \ No newline at end of file