mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Fix core.wrap_text and make its behaviour consistent with the docs
Code based on initial implementation by @dsohler.
This commit is contained in:
parent
17fd5fe935
commit
6fa2f6b4aa
4 changed files with 21 additions and 53 deletions
|
@ -250,7 +250,7 @@ end
|
|||
|
||||
--------------------------------------------------------------------------------
|
||||
function text2textlist(xpos, ypos, width, height, tl_name, textlen, text, transparency)
|
||||
local textlines = core.wrap_text(text, textlen)
|
||||
local textlines = core.wrap_text(text, textlen, true)
|
||||
local retval = "textlist[" .. xpos .. "," .. ypos .. ";" .. width ..
|
||||
"," .. height .. ";" .. tl_name .. ";"
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue