const hexToArray = (hex: string) => {
	const h = ["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"];
	const a = [];
	for (let i = 0; i < hex.length; i+=2) {
		a.push(16*h.indexOf(hex[i])+h.indexOf(hex[i+1]));
	}
	return a;
};

export default {
	"carts": [
		{
			"name": "mygame",
			"rom": hexToArray("[encoded data, 65536 characters]")
		},
		{
			"name": "secondcart",
			"src": "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAKAAAADNCAYAAAA/pXupAAAItUlEQVR4Ae2drY4jyxmG36pqMHBBwLmAwAMGHLhRHGlBwLmAE2mkWJGlM2BhYMCCBQEHDlhg4ChzCQcEDKhIfQFzCYELAgYEut2R7Clvucc/Pf1T3R4/j2R903Z39dTXT78fNbPZrQLzxWK5PYAtRnJyRmVRFpJkJSdntSpWRXyek1wh7Xx3Hht0cmVhCqmU5OS02YVToeJ5/5LK571ZZ52KlVbOFipWz5t3m/0Xxcn9z6bTbHvrIOB8sVjOpjeD7N9JpjCu1Ob5hu1v/zKSC5vffG+lYrWtTnKFc5vfT+9/dBzYv9sK4Mxm/0UpK7nVtj/R/qVCzp3F/ueL+62EZja71fwf/1z+/Oc/7b4Bkjbbl+SMVJQ69Pa75zekcK44RwFOG/Jt/zs9kIogwKZdZ5h+A0tolF0NlnyAhJY2wJAgICBgU77Mv/IEEXAg+X6YS09zfbn9iaeIgInl++Sln57T77ff68u7DzxJBEzH7aeJsqc/SpL+/snr9umBJ3mpAn755fPO59B31e+PXV/nHrPPP+j7h9/oP/87T/l+/DB5VY2vC599x/F3h46Prbfvt33Hx65LJmCQ4favf9tNqOg4/B2fu++7k6kXXRd4/6/bi0yNXx/8i79D/fHDRL8++BfHddeLZXvtOk3IuljkUHJ1IXacqrCbnm2vjeVq+iK0TcBOBKyTYG3Xq6bmWxTp1PGxxGqSnl2KNMgIrpOIVWG+/PJ573enRN53Han37ftQg0zx+afGZ/Xcpus0wSi7Ws6mN8w1SM58cd9PAgIMOoIBEBAQEAABAQEBEBB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