1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-08-26 18:21:04 +00:00

ContentDB redesign: Add package dialog

Co-authored-by: Gregor Parzefall <gregor.parzefall@posteo.de>
This commit is contained in:
rubenwardy 2024-03-31 19:24:27 +01:00
parent 05cbd84ae0
commit 78aab8c95d
12 changed files with 529 additions and 130 deletions

View file

@ -19,12 +19,7 @@
local function prepare_credits(dest, source)
local string = table.concat(source, "\n") .. "\n"
local hypertext_escapes = {
["\\"] = "\\\\",
["<"] = "\\<",
[">"] = "\\>",
}
string = string:gsub("[\\<>]", hypertext_escapes)
string = core.hypertext_escape(string)
string = string:gsub("%[.-%]", "<gray>%1</gray>")
table.insert(dest, string)