THIS ERROR HAS BEEN RESOLVED (09-13-21)
Closing error ticket.
I was running into an error in the newest version of Pico-8.
If you have this code:
function _init() cls() for i=1,8 do a=rand(1,2) print(a) end end function rand(a,b) if (a>b) a,b=b,a return flr(a+rnd(b-a+1)) end |
And run it. It works fine in all versions of Pico-8.
However if in immediate mode you type:
print(rand(1,2)) |
It works just fine in version 0.1.12c but you get an ERROR message in version 0.2.3.
It does not matter if the functions come before _init() you get the same results.
If I read this correctly it means we cannot use immediate mode to debug our functions in the newest version whereas in the earlier version, you could. I personally need this so I can check my functions in immediate mode to make sure they are working correctly.
Version 0.1.12c is the latest version where it works correctly; you can call functions in immediate mode. All versions after this up to 0.2.3 will not let you. I checked and confirmed this.
[Please log in to post a comment]