ldoc return fixes

This commit is contained in:
2026-02-26 17:41:06 +01:00
parent e56662f6ad
commit 337f1fc132
21 changed files with 279 additions and 262 deletions

View File

@@ -1,13 +1,11 @@
--- @section Print
--- Prints text with shadow.
--- @within Print
--- @param text string The text to print.
--- @param x number The x-coordinate.
--- @param y number The y-coordinate.
--- @param color number The color of the text.
--- @param[opt] fixed boolean If true, uses fixed-width font.
--- @param[opt] scale number The scaling factor.
--- @param text string The text to print.<br/>
--- @param x number The x-coordinate.<br/>
--- @param y number The y-coordinate.<br/>
--- @param color number The color of the text.<br/>
--- @param[opt] fixed boolean If true, uses fixed-width font.<br/>
--- @param[opt] scale number The scaling factor.<br/>
function Print.text(text, x, y, color, fixed, scale)
local shadow_color = Config.colors.black
if color == shadow_color then shadow_color = Config.colors.light_grey end
@@ -18,12 +16,12 @@ end
--- Prints centered text with shadow.
--- @within Print
--- @param text string The text to print.
--- @param x number The x-coordinate for centering.
--- @param y number The y-coordinate.
--- @param color number The color of the text.
--- @param[opt] fixed boolean If true, uses fixed-width font.
--- @param[opt] scale number The scaling factor.
--- @param text string The text to print.<br/>
--- @param x number The x-coordinate for centering.<br/>
--- @param y number The y-coordinate.<br/>
--- @param color number The color of the text.<br/>
--- @param[opt] fixed boolean If true, uses fixed-width font.<br/>
--- @param[opt] scale number The scaling factor.<br/>
function Print.text_center(text, x, y, color, fixed, scale)
scale = scale or 1
local text_width = print(text, 0, -6, 0, fixed, scale)