weetabixharry
Associate Captain
This is starting to look better, but I can't get all the dates to align correctly. For example, the IPL dates are all off by a few days.
Instead of the first match (Mumbai vs Chennai) being on 29th March, it's on 1st April. However, the English matches start correctly on 2nd April. Therefore, it seems like the different leagues are somehow referenced from a different base date. This is possibly encoded somewhere in the fixtures file (or I'm missing a simple trick).
For future reference, here is my (colour-coded) interpretation of what we know about the fixture file data format (almost all discovered by @Isura, @mrtwisties and perhaps others, with very minor additions/clarifications by me).
Each calendar date has a 6-byte header, comprising a 2-byte date index, a 2-byte count of the number of matches being played on this date... and the last 2 bytes are always zero (maybe reserved for future functionality):
The start of each match has a 42-byte header (or 50 bytes starting from CC 2021). I think all bytes are now understood:
The continuation of a multi-day match (after the first day) is just denoted using a 2-byte match reference (where the first match in the file has reference 0002, with increment thereafter).
Putting this information together, we can start reading off the information from the fixture file like this:
After this, we get some examples of multi-day matches continuing (red highlight):
Note that a new match start header can appear in between match references for ongoing matches (e.g. the last 0A 00 appears after a new match header).
The greyed-out 00 00 00 at the start of the file is probably actually a date header for day 0 (with no matches). The next greyed-out part FF FF 01 00 09 00 43 72 46 69 78 74 75 is the file header (which appears after the first data header with a nonzero number of matches). This is actually FF FF 01 00 09 00 followed by CrFixture in ASCII. The final re is not considered as part of the file header in Isura's code; instead, it is treated as a special match info delimiter (instead of 01 80) for the first match. This fits well into the code, so I certainly wouldn't change it (just a clarification).
Instead of the first match (Mumbai vs Chennai) being on 29th March, it's on 1st April. However, the English matches start correctly on 2nd April. Therefore, it seems like the different leagues are somehow referenced from a different base date. This is possibly encoded somewhere in the fixtures file (or I'm missing a simple trick).
For future reference, here is my (colour-coded) interpretation of what we know about the fixture file data format (almost all discovered by @Isura, @mrtwisties and perhaps others, with very minor additions/clarifications by me).
Each calendar date has a 6-byte header, comprising a 2-byte date index, a 2-byte count of the number of matches being played on this date... and the last 2 bytes are always zero (maybe reserved for future functionality):
The start of each match has a 42-byte header (or 50 bytes starting from CC 2021). I think all bytes are now understood:
The continuation of a multi-day match (after the first day) is just denoted using a 2-byte match reference (where the first match in the file has reference 0002, with increment thereafter).
Putting this information together, we can start reading off the information from the fixture file like this:
After this, we get some examples of multi-day matches continuing (red highlight):
Note that a new match start header can appear in between match references for ongoing matches (e.g. the last 0A 00 appears after a new match header).
The greyed-out 00 00 00 at the start of the file is probably actually a date header for day 0 (with no matches). The next greyed-out part FF FF 01 00 09 00 43 72 46 69 78 74 75 is the file header (which appears after the first data header with a nonzero number of matches). This is actually FF FF 01 00 09 00 followed by CrFixture in ASCII. The final re is not considered as part of the file header in Isura's code; instead, it is treated as a special match info delimiter (instead of 01 80) for the first match. This fits well into the code, so I certainly wouldn't change it (just a clarification).
Last edited: