You miss built-in lua functions such as ipairs
or getmetatable
in pico-8? Well, fear no more.
getmetatable
setmetatable
rawget
unpack
ipairs
table.pack
table.unpack
as an alias tounpack
table.insert
table.remove
table.sort
Travis-CI is set to test missing.lua
against test.lua
, which compares results of this library functions with the built-in ones. Well, tests may be incomplete, so do not hesitate to flag a bug to the issue tracker if something goes wrong.
Heads up to the latest release. Then, there's two options:
- Either you download
missing.lua
then copy the file contents into your.p8
project file, preferably before the rest of your code; or - you load
missing.p8
in pico-8 to test it out first.
This library is under creative commons license CC4-BY-NC-SA. See LICENSE.md. It's the same license as the optional one on Lexaloffle's website if you choose to publish a cart.
So, if you happen to publish a cart using this library, it would be nice if you mention it.
To Lexaloffle, which this library would not exist without pico-8.
- Add some
table
functions.table.pack
table.unpack
as an alias tounpack
table.insert
table.remove
table.sort
- Refactor
ipairs
to make it return aniter
function, as the native one does.
- Add
getmetatable
setmetatable
rawget
unpack
ipairs