1
0
Fork 0
mirror of https://github.com/Reuh/anselme.git synced 2025-10-27 16:49:31 +00:00

Clean implementation of 👁️ and no longer increment 🏁 on checkpoint execution (redundant with 👁️)

This commit is contained in:
Étienne Fildadut 2022-10-03 18:10:47 +09:00
parent f79e2f5716
commit 2ff494d108
12 changed files with 115 additions and 77 deletions

View file

@ -152,7 +152,7 @@ else
-- simple random to get the same result across lua versions
local prev = 0
local function badrandom(a, b)
prev = (15485863 * prev + 11) % 2038074743
prev = (4241 * prev + 11) % 6997
return a + prev % (b-a+1)
end
function math.random(a, b)

View file

@ -1,18 +1,22 @@
local _={}
_[29]={}
_[28]={}
_[27]={}
_[26]={}
_[25]={}
_[24]={}
_[23]={}
_[22]={}
_[21]={}
_[20]={tags=_[25],text="2"}
_[19]={tags=_[25],text="Reached: "}
_[18]={tags=_[24],text="1"}
_[17]={tags=_[24],text="Seen: "}
_[16]={tags=_[23],text="seen!"}
_[15]={tags=_[22],text="1"}
_[14]={tags=_[22],text="Reached: "}
_[13]={tags=_[21],text="0"}
_[12]={tags=_[21],text="Seen: "}
_[20]={text="1",tags=_[29]}
_[19]={text="Reached: ",tags=_[28]}
_[18]={text="1",tags=_[27]}
_[17]={text="Seen: ",tags=_[26]}
_[16]={text="seen!",tags=_[25]}
_[15]={text="1",tags=_[24]}
_[14]={text="Reached: ",tags=_[23]}
_[13]={text="0",tags=_[22]}
_[12]={text="Seen: ",tags=_[21]}
_[11]={_[19],_[20]}
_[10]={_[17],_[18]}
_[9]={_[16]}
@ -27,17 +31,17 @@ _[1]={"text",_[7]}
return {_[1],_[2],_[3],_[4],_[5],_[6]}
--[[
{ "text", { {
tags = <1>{},
tags = {},
text = "Seen: "
}, {
tags = <table 1>,
tags = {},
text = "0"
} } }
{ "text", { {
tags = <1>{},
tags = {},
text = "Reached: "
}, {
tags = <table 1>,
tags = {},
text = "1"
} } }
{ "text", { {
@ -45,18 +49,18 @@ return {_[1],_[2],_[3],_[4],_[5],_[6]}
text = "seen!"
} } }
{ "text", { {
tags = <1>{},
tags = {},
text = "Seen: "
}, {
tags = <table 1>,
tags = {},
text = "1"
} } }
{ "text", { {
tags = <1>{},
tags = {},
text = "Reached: "
}, {
tags = <table 1>,
text = "2"
tags = {},
text = "1"
} } }
{ "return" }
]]--

View file

@ -4,10 +4,10 @@ _[20]={}
_[19]={}
_[18]={}
_[17]={}
_[16]={tags=_[21],text="c"}
_[15]={tags=_[20],text="a"}
_[14]={tags=_[19],text="c"}
_[13]={tags=_[18],text="b"}
_[16]={tags=_[21],text="a"}
_[15]={tags=_[20],text="c"}
_[14]={tags=_[19],text="b"}
_[13]={tags=_[18],text="a"}
_[12]={tags=_[17],text="c"}
_[11]={_[16]}
_[10]={_[15]}
@ -26,6 +26,10 @@ return {_[1],_[2],_[3],_[4],_[5],_[6]}
tags = {},
text = "c"
} } }
{ "text", { {
tags = {},
text = "a"
} } }
{ "text", { {
tags = {},
text = "b"
@ -38,9 +42,5 @@ return {_[1],_[2],_[3],_[4],_[5],_[6]}
tags = {},
text = "a"
} } }
{ "text", { {
tags = {},
text = "c"
} } }
{ "return" }
]]--

View file

@ -0,0 +1,12 @@
:$ fn
{👁️}
:! a
a: {👁️}
~ fn.a
~ fn.a
~ fn.a

View file

@ -0,0 +1,45 @@
local _={}
_[19]={}
_[18]={}
_[17]={}
_[16]={}
_[15]={}
_[14]={}
_[13]={text="2",tags=_[19]}
_[12]={text="a: ",tags=_[18]}
_[11]={text="1",tags=_[17]}
_[10]={text="a: ",tags=_[16]}
_[9]={text="0",tags=_[15]}
_[8]={text="a: ",tags=_[14]}
_[7]={_[12],_[13]}
_[6]={_[10],_[11]}
_[5]={_[8],_[9]}
_[4]={"return"}
_[3]={"text",_[7]}
_[2]={"text",_[6]}
_[1]={"text",_[5]}
return {_[1],_[2],_[3],_[4]}
--[[
{ "text", { {
tags = {},
text = "a: "
}, {
tags = {},
text = "0"
} } }
{ "text", { {
tags = {},
text = "a: "
}, {
tags = {},
text = "1"
} } }
{ "text", { {
tags = {},
text = "a: "
}, {
tags = {},
text = "2"
} } }
{ "return" }
]]--