I wanted to download an older version of one of my carts and didnt save the cart number or add it to my cart thread. I couldn't find a good way to navigate the BBS to find my old carts. So I downloaded them all (AFAIK) up to 7/22/18.
Here's a link to them all: Download
Let me know if I missed any.
I used c# webclient and went through the web. And yes some of them just dont exist.
I didnt even think of using pico-8! (duh!)
@spencifier: AFAIK you couldn't do this with pico-8 anyway. load() also runs the cart so you couldn't save it with code. Felice's post was pseudo-code for what you actually did and the cart I posted was just a semi-related random thought :)
I'm entirely certain there's some garbage collection going on for carts which don't exist in posts/threads anymore. If you want to keep your old versions accessible, you need to stuff them in a post somewhere, Presumably the bottom of your main thread post in a little hidden spoiler area would be ideal? I think that having multiple carts in the same post keeps all but the first one from showing up in splore, anyway.
Time to revisit this. I started using tac08 on my rg350 and wanted to download a few carts. So...I made a small python program that will find and download all carts. As of writing this, there are 8,478 carts (150MB)
Credit and details on how to do this is here: https://www.ebartsoft.com/pico8
import requests import os, sys, time from os.path import exists from PIL import Image from io import BytesIO CART_DOWNLOAD_DIR = os.path.dirname(__file__) + "\carts" PAGES = 5320 DOWNLOAD_URL = "https://www.lexaloffle.com/bbs/get_cart.php?cat=7&play_src=2&lid=" def save_cart(cart_info, data): # Remove invalid filepath characters filename = "".join(x for x in cart_info if x.isalnum()) # If two carts have the same title add on the carts unique name. if exists(CART_DOWNLOAD_DIR + "\\" + filename + ".p8.png"): filename += "." + cart_info # Write cart data to file with open(CART_DOWNLOAD_DIR + "\\" + filename + ".p8.png","wb") as cd: cd.write(data) def get_cart_listing(sub, start_index): # Search cart listings 32 at a time. print("Searching carts " + str(32*start_index) + " to " + str((32*start_index)+31) + "...") r = requests.get("https://www.lexaloffle.com/bbs/cpost_lister3.php?max=32&start_index=" + str(32*start_index) + "&cat=7&sub=" + str(sub) + "&version=000202cw&cfil=0") return r.content def parse_cart_info(pixels): # Cart listing image is 32 carts in a 4 x 8 grid # Metadata about each cart is in the 8 pixel rows under each cart, RGB encoded cart_info =  for row in range (1, 5): for col in range (0, 8): cart_data =  for y in range (128*row + (8*(row-1)), (128*row) + 8 + (8*(row-1))): line = "" for x in range (128*col, (128*col) + 128): rgba = pixels[x,y] line += chr(rgba) # decrypt pixel RGB to a character cart_data.append(line.replace("\x00","")) # Clean-up empty characters cart_info.append(cart_data) return cart_info def download_cart(cart_info): dc = requests.get(DOWNLOAD_URL + cart_info) save_cart(cart_info, dc.content) def main(): # Make download directory for all the carts if it doesn't exist if not os.path.isdir(CART_DOWNLOAD_DIR): os.mkdir(CART_DOWNLOAD_DIR) for sub in [2,3,4,8]: print("Sub: " + str(sub)) for p in range(0, PAGES): print("Page: " + str(p+1) + " of " + str(PAGES)) cart_listing_bytes = get_cart_listing(sub, p) if len(cart_listing_bytes) <= 1064: break cart_listing_image = Image.open(BytesIO(cart_listing_bytes)) cart_pixels = cart_listing_image.load() cart_listing_info = parse_cart_info(cart_pixels) for i in range(len(cart_listing_info)): if cart_listing_info[i]: print("Downloading cart " + str(32*p+i) + "..." + cart_listing_info[i]) download_cart(cart_listing_info[i]) print("Waiting 2 secs...") time.sleep(2) # Trying not to kill the BBS print("Cart downloads complete.") if __name__ == "__main__": main()
[Please log in to post a comment]