27 Sep
2019
27 Sep
'19
4:59 a.m.
Hi, I am trying to pass variables/data between context and lua. Lua would be used for calculations on data coming from context. Unfortunately I can't figure out what to do. The code below doesn't work, but is there to illustrate my idea. Any help would be much appreciated. Thanks, Martin \define\question{44} \starttext \startluacode local points = \question * 92 -- do some calculations with points and return to to context answer=42 \stopluacode % lots of Text in between The answer is \answer \stoptext