using System; using System.Collections.Generic; namespace PKHeX.Core { public static class Meta8 { public static SCBlock[] GetBlankDataSWSH() => GetBlankBlockArray(DefaultChunkSizesSWSH, 2408); private static SCBlock[] GetBlankBlockArray(IReadOnlyList arr, int totalBlocks) { var blocks = new SCBlock[totalBlocks]; for (int i = 0; i < blocks.Length; i++) blocks[i] = new SCBlock {Data = Array.Empty()}; for (int i = 0; i < arr.Count; i += 2) { int index = arr[i]; int length = arr[i + 1]; blocks[index].Data = new byte[length]; } return blocks; } private static readonly int[] DefaultChunkSizesSWSH = { 0007, 0x00004, 0011, 0x00001, 0013, 0x00009, 0023, 0x00004, 0024, 0x00004, 0025, 0x00004, 0048, 0x056F8, 0057, 0x00004, 0058, 0x00004, 0074, 0x00004, 0075, 0x00004, 0076, 0x00004, 0097, 0x00004, 0104, 0x00004, 0105, 0x00004, 0106, 0x00004, 0107, 0x00004, 0108, 0x00004, 0109, 0x00004, 0110, 0x00004, 0111, 0x00004, 0112, 0x00004, 0113, 0x00004, 0114, 0x00004, 0115, 0x00004, 0116, 0x00004, 0117, 0x00004, 0129, 0x00004, 0130, 0x00004, 0134, 0x00004, 0136, 0x00004, 0141, 0x00004, 0142, 0x00004, 0143, 0x50A00, 0145, 0x00004, 0147, 0x00004, 0148, 0x00001, 0150, 0x00004, 0151, 0x00004, 0168, 0x00004, 0177, 0x00004, 0186, 0x017C8, 0190, 0x00004, 0191, 0x012F8, 0199, 0x00004, 0201, 0x00004, 0210, 0x00004, 0217, 0x00004, 0229, 0x00880, 0231, 0x00648, 0235, 0x00004, 0236, 0x00648, 0237, 0x00004, 0238, 0x00004, 0239, 0x00004, 0240, 0x00004, 0241, 0x00004, 0242, 0x00004, 0243, 0x00004, 0244, 0x00004, 0249, 0x00004, 0252, 0x00880, 0253, 0x06010, 0262, 0x00004, 0266, 0x00004, 0268, 0x00880, 0269, 0x00004, 0272, 0x00880, 0273, 0x00084, 0275, 0x00440, 0276, 0x00880, 0286, 0x00001, 0288, 0x0021C, 0308, 0x00004, 0352, 0x00132, 0363, 0x00008, 0370, 0x00004, 0378, 0x00004, 0380, 0x00004, 0381, 0x00004, 0382, 0x00004, 0386, 0x00004, 0387, 0x00004, 0398, 0x00004, 0399, 0x00004, 0402, 0x00004, 0403, 0x00004, 0404, 0x00004, 0405, 0x00004, 0406, 0x00004, 0407, 0x00004, 0408, 0x00004, 0409, 0x00004, 0414, 0x00004, 0418, 0x21FC0, 0419, 0x00004, 0420, 0x00004, 0428, 0x00814, 0431, 0x00001, 0440, 0x00004, 0465, 0x00570, 0470, 0x00004, 0476, 0x00020, 0481, 0x00004, 0484, 0x00008, 0500, 0x00004, 0502, 0x00004, 0509, 0x00048, 0518, 0x00004, 0519, 0x00004, 0526, 0x00004, 0532, 0x00004, 0536, 0x00004, 0539, 0x00004, 0544, 0x000C8, 0546, 0x00004, 0549, 0x00D50, 0557, 0x00004, 0558, 0x00004, 0561, 0x00004, 0570, 0x00004, 0582, 0x033D0, 0614, 0x00004, 0615, 0x00004, 0616, 0x00004, 0617, 0x00004, 0619, 0x00002, 0626, 0x00004, 0627, 0x00004, 0629, 0x00001, 0630, 0x00004, 0635, 0x00002, 0639, 0x00001, 0644, 0x00004, 0658, 0x00004, 0659, 0x00004, 0661, 0x00001, 0668, 0x00038, 0678, 0x00004, 0692, 0x00028, 0693, 0x00004, 0699, 0x04B00, 0705, 0x00004, 0718, 0x00004, 0727, 0x00004, 0728, 0x00004, 0729, 0x00004, 0732, 0x00001, 0735, 0x00004, 0738, 0x00004, 0741, 0x00004, 0743, 0x00004, 0748, 0x00004, 0777, 0x02964, 0811, 0x00004, 0822, 0x02304, 0829, 0x02304, 0841, 0x02304, 0843, 0x00004, 0850, 0x02304, 0865, 0x02304, 0871, 0x02304, 0877, 0x02304, 0879, 0x00004, 0889, 0x02304, 0891, 0x00004, 0900, 0x00004, 0902, 0x00004, 0908, 0x00002, 0912, 0x00004, 0916, 0x00001, 0926, 0x00810, 0928, 0x02304, 0929, 0x00004, 0933, 0x00004, 0936, 0x00002, 0938, 0x00004, 0941, 0x00002, 0953, 0x02304, 0955, 0x00004, 0971, 0x00004, 0980, 0x00004, 0987, 0x00004, 0988, 0x00004, 0992, 0x00004, 0995, 0x00004, 0996, 0x0426C, 1002, 0x00004, 1003, 0x00004, 1012, 0x00004, 1013, 0x00004, 1015, 0x00004, 1016, 0x00132, 1018, 0x00004, 1020, 0x00004, 1024, 0x00004, 1027, 0x00002, 1039, 0x067D0, 1042, 0x00004, 1048, 0x00004, 1058, 0x00004, 1059, 0x00004, 1060, 0x00001, 1061, 0x00132, 1065, 0x00004, 1082, 0x00004, 1106, 0x00004, 1110, 0x00001, 1115, 0x04610, 1119, 0x00004, 1123, 0x00004, 1128, 0x00004, 1129, 0x00004, 1134, 0x01F50, 1139, 0x00004, 1146, 0x00004, 1151, 0x00004, 1158, 0x00004, 1169, 0x00020, 1173, 0x00008, 1178, 0x00004, 1187, 0x00004, 1195, 0x00004, 1238, 0x00004, 1239, 0x00132, 1251, 0x00004, 1256, 0x00004, 1259, 0x001D0, 1261, 0x00004, 1270, 0x033D0, 1272, 0x033D0, 1278, 0x00004, 1288, 0x00004, 1298, 0x00004, 1300, 0x00004, 1301, 0x00038, 1302, 0x00008, 1304, 0x00004, 1305, 0x000D0, 1308, 0x00004, 1315, 0x00004, 1318, 0x00004, 1321, 0x00004, 1322, 0x00004, 1326, 0x00A68, 1328, 0x00004, 1332, 0x00004, 1336, 0x00004, 1342, 0x00004, 1344, 0x00004, 1346, 0x00055, 1347, 0x00004, 1355, 0x00132, 1356, 0x00004, 1373, 0x00019, 1377, 0x00002, 1382, 0x00400, 1390, 0x00004, 1400, 0x00004, 1406, 0x00004, 1407, 0x00004, 1411, 0x00004, 1412, 0x00004, 1413, 0x00004, 1433, 0x00004, 1436, 0x00132, 1469, 0x00002, 1489, 0x00004, 1498, 0x00004, 1509, 0x00019, 1517, 0x00004, 1518, 0x00004, 1526, 0x00004, 1536, 0x00004, 1544, 0x00004, 1549, 0x00004, 1551, 0x00268, 1554, 0x00004, 1573, 0x00004, 1590, 0x00280, 1591, 0x1241C, 1592, 0x00004, 1594, 0x00004, 1597, 0x023D4, 1603, 0x00004, 1604, 0x00004, 1605, 0x00004, 1606, 0x00004, 1616, 0x00004, 1635, 0x000F8, 1637, 0x00004, 1638, 0x00028, 1643, 0x00004, 1670, 0x50C20, 1690, 0x0001E, 1730, 0x00004, 1744, 0x00004, 1765, 0x00004, 1784, 0x00004, 1789, 0x00408, 1790, 0x00004, 1793, 0x00004, 1796, 0x00004, 1808, 0x000A0, 1814, 0x00004, 1830, 0x00004, 1836, 0x00132, 1841, 0x00004, 1842, 0x00002, 1843, 0x00004, 1848, 0x00004, 1849, 0x00004, 1851, 0x00004, 1855, 0x00004, 1868, 0x00004, 1873, 0x00004, 1890, 0x0001C, 1891, 0x00001, 1892, 0x00004, 1912, 0x00004, 1915, 0x00132, 1989, 0x00F1C, 2073, 0x00008, 2104, 0x00004, 2109, 0x00008, 2111, 0x02304, 2116, 0x02304, 2128, 0x00004, 2130, 0x00001, 2131, 0x00001, 2135, 0x00320, 2136, 0x00008, 2141, 0x00004, 2149, 0x02304, 2160, 0x02304, 2165, 0x02304, 2169, 0x02304, 2197, 0x02304, 2207, 0x02304, 2209, 0x000F0, 2213, 0x00014, 2216, 0x02304, 2222, 0x02304, 2232, 0x02304, 2234, 0x02304, 2236, 0x00001, 2237, 0x00538, 2242, 0x033D0, 2243, 0x02304, 2246, 0x116C4, 2248, 0x02304, 2252, 0x00002, 2253, 0x00004, 2262, 0x02304, 2269, 0x02304, 2274, 0x02955, 2275, 0x00110, 2278, 0x02304, 2285, 0x02304, 2301, 0x00004, 2312, 0x00004, 2313, 0x00004, 2319, 0x00004, 2321, 0x00004, 2343, 0x00004, 2344, 0x00004, 2355, 0x00004, 2363, 0x00004, 2364, 0x02304, 2368, 0x03208, 2373, 0x02304, 2391, 0x00004, 2396, 0x00002 }; } }