Refactor API functions to improve parameter aliasing and enhance documentation clarity
This commit is contained in:
@@ -1,12 +1,14 @@
|
||||
---@diagnostic disable: missing-return, lowercase-global
|
||||
---@meta
|
||||
|
||||
---@param button 5 or Button5
|
||||
---@param 1 or LeftButton
|
||||
---@param 2 or RightButton
|
||||
---@param 3 or MiddleButton
|
||||
---@param 4 or Button4
|
||||
---@param 5 or Button5
|
||||
---@return 1nil isDown
|
||||
---@alias mouseButton
|
||||
---| 1 or "LeftButton" - Primary mouse button
|
||||
---| 2 or "RightButton" - Secondary mouse button
|
||||
---| 3 or "MiddleButton" - Third mouse button (or clickable scroll control)
|
||||
---| 4 or "Button4" - Fourth mouse button
|
||||
---| 5 or "Button5" - Fifth mouse button
|
||||
|
||||
---@param button mouseButton
|
||||
---@return boolean isDown
|
||||
---Returns whether a given mouse button is held down. If no button is specified, returns 1 if any mouse button is held down.
|
||||
function IsMouseButtonDown(button, 1 or LeftButton, 2 or RightButton, 3 or MiddleButton, 4 or Button4, 5 or Button5) end
|
||||
function IsMouseButtonDown(button) end
|
||||
|
||||
Reference in New Issue
Block a user