
Hey All, PICO-8 0.2.7 is now up on lexaloffle, Humble and itch.io. No CHIP/PocketCHIP build yet, sorry! (my last PocketCHIP died -- I'll come back to that later)
This update introduces some late additions to the API before freezing at 0.3, and improvements aimed at handheld devices. 0.2.7 also includes an important security patch for a vulnerability affecting untrusted carts running locally (see below).
RRECT

This feature was needed for Picotron but I think also feels at home in PICO-8 / Voxatron. rrect() and rrectfill() take x,y for the top left corner, a width and height of the rectangle, and a radius for the corners. When the radius is 0 (the default), rrect / rrectfill act as an alternative to rect / rectfill when it is more convenient to specify a width and height rather than x1, y1.
Outlines & Underlines
P8SCII in 0.2.7 has new commands for outlining and underlining text. To get an outline, use \^o followed by a single character for colour, and two hex characters that indicate which of the 8 neighbouring pixels to draw:
0x01 0x02 0x04 0x08 -- 0x10 0x20 0x40 0x80 |
For example, to draw a dot with a red(8) outline of the lower neighbours (0x20+0x40+0x80) and the top left neighbour (0x1), the command would be: ?"\^o8e1."

The underline command \^u does not take any parameters; it draws a line in the foreground colour 1 pixel below the bottom of the character. See the manual for more details:
https://www.lexaloffle.com/dl/docs/pico-8_manual.html#P8SCII_Outlines
Cart Prefetching & Cache Surfing
Cartridges that are listed in SPLORE are now proactively fetched from the BBS in the background, instead of downloading a cart only once it is selected. This makes it easier to grab a bunch of cartridges from the BBS and then play them while offline. Simply list the carts you'd like to download (e.g. by scrolling through NEW and selecting [LOAD MORE]), and wait for a few seconds for them to finish downloading. There is a small colourful spinner animation in the top left corner that indicates batch downloading is in progress. It is visible when a cartridge is not selected (e.g. on the [more] or [update] menu items), which you can see in the gif below.
Prefetching can be disabled (or made more aggressive) in config.txt with:
max_prefetch_threads 0 |

Cartridges that are downloaded to the local cache can also be listed newest first from the local files list under [CACHE] in the root directory. In the gif, you can see prefetched cartridges showing up in the cache listing each time [REFRESH] is selected.
Note that BBS cartridges that are downloaded are never automatically deleted from the cache (they do not expire), so there is normally no need to manually download and copy cartridges if they can be found in splore (e.g. by adding them to your favourites).
Favourited cartridges in the cache do not necessarily have any metadata stored (author, full title), and show up as just the cart id. For such carts, metadata is fetched from the BBS the next time the cartridge is run while internet is available.
BBS Favourite Listings
To list cartridges that you have favourited via the website (while logged in), you can now use the search section in splore:
-
Set your favourites (or likes) to public on the settings page
- In PICO-8, seach for:
fav:username
orlike:username
Multicart Export Limit: 32 Cartridges
0.2.7 now allows up to 32 cartridges in a single HTML or binary export, an increase from the previous limit of 16. This is aimed at [groups of] authors who would like to release bundles of carts, and I think 32 is a cute size in that context. I've heard from several groups who are interested in creating "n-in-1 game" style collections, which PICO-8 is naturally suited for, and 16 cartridges isn't quite enough for that. I don't think I could stomache going as far as 64 though -- you'd need to start packing multiple tiny games per cart for that!
[The downside of course is that a 32 cart limit does introduce extra unwanted gravity towards Making Bigger Things. However, there have only been a handful of projects that have pushed the 16 cart limit in order to cram extra content into a single game, and I don't think any of them would have suffered from this new limit.]
Security Patch
When run un-sandboxed (i.e. as a local cart), ls() in 0.2.6b and earlier caused a buffer overrun for long input strings, allowing a hypothetical bad actor to construct an RCE attack. A proof of concept for such an attack that works under windows was posted 4 weeks ago, but the author kindly took it down soon after while I worked on this patch. In 0.2.7 I've fixed that particular case, audited the codebase for similar issues, and introduced some extra safeguards for string handling that is in code paths reachable by the userland api. I opted to release it along with 0.2.7 features to encourage as many users to update as possible.
This vulnerability does not impact cartridges that are run directly from splore or via load #foo, and I have been monitoring the BBS cartridge submissions for anything suspicious. In any case, please consider updating soon especially if you planning on running carts locally from un-trusted sources.
Changelog



Fabulous update. love the config.txt option to default to splore. Also this caching is great! Also love the new favorites and likes feature. Still trying to figure out how to manage it so that I can get quick access to my favorites. Probably use favorites for all my carts and Likes for my ultra favorites.



Thank you for the Update itself and the better Splore Cache and Fav Functions 🦍🖖🏼💋



Thank you for the update! Both rrect and text outlines are great additions.



Thanks for an awesome update! Rrect seems like a great addition as well.



What kind of output is expected in splore when searching fav:<username>? I come up with a spinning activity icon but then no results and no error



Will this update download all carts in multi-cart games right on load or do we still need to pull those manually or have games load them?
Really great update



Awesome update!!! I still hope pico 8 will be available on iPadOS



@buckysrevenge try again now -- I fixed a server-side bug that was causing the public favourites settings flag to be ignored. You should get a list of carts that is the same as this one: https://www.lexaloffle.com/bbs/?uid=1&mode=carts&list=user_favourites#m
@aloven yeah, prefetching only applies to the listed carts so multi-cart games still need to be run while online first.



@buckysrevenge For me, it came back with my favorites list pretty quickly when I did fav:2bitchuck in Splore on my RGB30.
[Please log in to post a comment]