Showing
1 changed file
with
26 additions
and
0 deletions
utils/gog_changelog.lua
0 → 100644
1 | +local args = {...} | |
2 | + | |
3 | +local skip_next = false | |
4 | +for line in io.lines(args[1]) do | |
5 | + local ok = true | |
6 | + if line == "" and skip_next then ok = false end | |
7 | + skip_next = false | |
8 | + | |
9 | + if line == "[img]https://te4.org/images/tmp/changelog_tome.png[/img]" then line = "" | |
10 | + elseif line == "[img]https://te4.org/images/tmp/changelog_ashes.png[/img]" then line = "" | |
11 | + elseif line == "[img]https://te4.org/images/tmp/changelog_embers.png[/img]" then line = "" | |
12 | + elseif line == "[img]https://te4.org/images/cults_header.png[/img]" then line = "" | |
13 | + end | |
14 | + line = line:gsub("^%[%*%]", "* ") | |
15 | + line = line:gsub(" See http://te4.org/", "") | |
16 | + | |
17 | + if line == "[list]" or line == "[/list]" then ok = false end | |
18 | + if line == "Your launcher should automatically update your game so no need to redownload it all." then ok = false skip_next = true end | |
19 | + if line == "If your launcher didn't self-update correctly, just redownload it from the homepage." then ok = false skip_next = true end | |
20 | + if line == "Don't forget to help ToME by with donations ( http://te4.org/donate ) or on [url=https://www.patreon.com/darkgodone]Patreon[/url] !" then ok = false skip_next = true end | |
21 | + | |
22 | + if ok then | |
23 | + print(line) | |
24 | + end | |
25 | + was_ok = ok | |
26 | +end | ... | ... |
-
Please register or login to post a comment