1
0
Fork 0
mirror of https://github.com/Reuh/anselme.git synced 2025-10-27 08:39:30 +00:00
This commit is contained in:
Étienne Fildadut 2021-11-27 14:37:55 +01:00
parent 12d2aa3e82
commit 14d348bad9
3 changed files with 28 additions and 28 deletions

View file

@ -18,9 +18,9 @@ local function post_process_text(state, text)
for i=1, #text-1 do
local a, b = text[i], text[i+1]
local na = #a.text:match(" *$")
local nb = #b.text:match(" *$")
local nb = #b.text:match("^ *")
if na > 0 and nb > 0 then -- remove duplicated spaces from second element first
b.text = b.text:match("^(.-) *$")
b.text = b.text:match("^ *(.-)$")
end
if na > 1 then
a.text = a.text:match("^(.- ) *$")

View file

@ -4,20 +4,20 @@ _[29]={}
_[28]={}
_[27]={1}
_[26]={}
_[25]={tags=_[26],text=" to move."}
_[24]={tags=_[26],text=" joystick"}
_[23]={tags=_[30],text="left"}
_[22]={tags=_[26],text="Use "}
_[21]={tags=_[29],text="Other"}
_[25]={text=" to move.",tags=_[26]}
_[24]={text="joystick",tags=_[26]}
_[23]={text="left ",tags=_[30]}
_[22]={text="Use ",tags=_[26]}
_[21]={text="Other",tags=_[29]}
_[20]={}
_[19]={tags=_[28],text="No"}
_[18]={tags=_[20],text=" to jump."}
_[17]={tags=_[27],text="A"}
_[16]={tags=_[20],text="Press "}
_[15]={tags=_[26],text="ok"}
_[19]={text="No",tags=_[28]}
_[18]={text="to jump.",tags=_[20]}
_[17]={text="A ",tags=_[27]}
_[16]={text="Press ",tags=_[20]}
_[15]={text="ok",tags=_[26]}
_[14]={_[22],_[23],_[24],_[25]}
_[13]={_[21]}
_[12]={tags=_[20],text="ok"}
_[12]={text="ok",tags=_[20]}
_[11]={_[19]}
_[10]={_[16],_[17],_[18]}
_[9]={_[15]}
@ -36,10 +36,10 @@ return {_[1],_[2],_[3],_[4],_[5]}
text = "Press "
}, {
tags = { 1 },
text = "A"
text = "A "
}, {
tags = <table 1>,
text = " to jump."
text = "to jump."
} }, { {
tags = {},
text = "No"
@ -56,10 +56,10 @@ return {_[1],_[2],_[3],_[4],_[5]}
text = "Use "
}, {
tags = { 1 },
text = "left"
text = "left "
}, {
tags = <table 1>,
text = " joystick"
text = "joystick"
}, {
tags = <table 1>,
text = " to move."

View file

@ -3,13 +3,13 @@ _[16]={1}
_[15]={}
_[14]={1}
_[13]={}
_[12]={tags=_[15],text=" to move."}
_[11]={tags=_[15],text=" joystick"}
_[10]={tags=_[16],text="left"}
_[9]={tags=_[15],text="Use "}
_[8]={tags=_[13],text=" to jump."}
_[7]={tags=_[14],text="A"}
_[6]={tags=_[13],text="Press "}
_[12]={text=" to move.",tags=_[15]}
_[11]={text="joystick",tags=_[15]}
_[10]={text="left ",tags=_[16]}
_[9]={text="Use ",tags=_[15]}
_[8]={text="to jump.",tags=_[13]}
_[7]={text="A ",tags=_[14]}
_[6]={text="Press ",tags=_[13]}
_[5]={_[9],_[10],_[11],_[12]}
_[4]={_[6],_[7],_[8]}
_[3]={"return"}
@ -22,20 +22,20 @@ return {_[1],_[2],_[3]}
text = "Press "
}, {
tags = { 1 },
text = "A"
text = "A "
}, {
tags = <table 1>,
text = " to jump."
text = "to jump."
} } }
{ "text", { {
tags = <1>{},
text = "Use "
}, {
tags = { 1 },
text = "left"
text = "left "
}, {
tags = <table 1>,
text = " joystick"
text = "joystick"
}, {
tags = <table 1>,
text = " to move."