Skip to content

Instantly share code, notes, and snippets.

View Miss-Inputs's full-sized avatar
🐈
Being a cat

Megan Leet Miss-Inputs

🐈
Being a cat
View GitHub Profile
@Miss-Inputs
Miss-Inputs / mGBA thumbnailer.py
Last active January 8, 2024 10:29
GB + GBA ROM thumbnailer using mGBA
#!/usr/bin/env python3
# TODO: Better logging, as this just spams the system journal under the tumblerd unit
from argparse import ArgumentParser
from collections.abc import Iterator
from datetime import timedelta
import numpy
from mgba.core import find, load_path
#!/usr/bin/env python3
# Copyright 2022 Megan Leet
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH T
#!/usr/bin/env python3
#Copyright (c) 2022 Megan Leet
#Permission is hereby granted, free of charge, to any person obtaining a copy
#of this software and associated documentation files (the "Software"), to deal
#in the Software without restriction, including without limitation the rights
#to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
#copies of the Software, and to permit persons to whom the Software is
#furnished to do so, subject to the following conditions:
@Miss-Inputs
Miss-Inputs / Compare arcade dat versions.py
Last active September 18, 2021 13:59
Compare the dats of two git revisions of a libretro core (for arcade games) to see what is new
#!/usr/bin/env python3
import re
import sys
from urllib.request import urlopen
from xml.etree import ElementTree
description_matcher = re.compile(r'(.+?)\s*(\[[^\]]+\])$')
class Game():
def __init__(self, xml):
#!/usr/bin/env python3
import os
import glob
from urllib.request import urlopen
from urllib.error import HTTPError, URLError
from xml.etree import ElementTree
source_path = '/home/megan/351ELEC'
1. Enchantekue (Snow Bros)
2. Super Fight (Super Contra)
3. Overlord (Exerion)
4. Baresark (SD Hero Soukessen - Taose! Aku no Gundan)
5. Fire Bolt
6. Elf Legend (Chip & Dale Rescue Rangers 2 with Po Teletubbies and Charmander)
7. Defier (Street Fighter II Pro, 12 Peoples variant)
8. X-War (Silkworm, starts at level 6 then goes to level 1)
9. Boy Sport (Downtown - Nekketsu Koushinkyoku - Soreyuke Daiundoukai)
10. Racing Car (Race America, seems unplayable due to lack of 2nd player?)
@Miss-Inputs
Miss-Inputs / MAME benchmarker.py
Last active November 18, 2020 00:55
MAME benchmarker
#!/usr/bin/env python3
import csv
import re
import statistics
import subprocess
import sys
import xml.etree.ElementTree as ElementTree
systems = {
@Miss-Inputs
Miss-Inputs / Nicer sizes on Internet Archive zip listings.user.js
Created May 12, 2019 17:17
Nicer sizes on Internet Archive zip listings
// ==UserScript==
// @name Nicer sizes on Internet Archive zip listings
// @match http://*.archive.org/zipview.php?zip*
// @match https://*.archive.org/zipview.php?zip*
// ==/UserScript==
[].slice.call(document.getElementsByTagName('tr')).forEach(function(tr) {
size = tr.cells[3].innerHTML * 1;
if (isNaN(size)) {
return;
@Miss-Inputs
Miss-Inputs / ScummVM rom folder detect.py
Created May 8, 2019 15:43
ScummVM detect + asyncio stuff
#!/usr/bin/env python3
import asyncio
import datetime
import os
import re
import shlex
async def run(exe_name, args):
proc = await asyncio.create_subprocess_exec(exe_name, *args, stdout=asyncio.subprocess.PIPE, stderr=asyncio.subprocess.PIPE)
-- Classic Controller
Contra ReBirth (can also use sideways Wiimote)
-- GameCube controller or Classic Controller (turn the other one off to prevent conflicts)
Arcade VC (none of them use too many buttons)
Cartoon Network: Punch Time Explosion XL
Castlevania: The Adventure ReBirth (can also use sideways Wiimote, or Wiimote + Nunchuk)
C64 VC (does it not need IR for virtual keyboard?)
Dragon Ball: Revenge of King Piccolo (can also use Wiimote + Nunchuk)
Fire Emblem: Radiant Dawn (can also use sideways Wiimote)