Any way to detect the version of specific map save?
-
- Manual Inserter
- Posts: 2
- Joined: Mon Nov 11, 2024 5:19 am
- Contact:
Any way to detect the version of specific map save?
Hello, I'm working on dockerizing a Factorio map renderer that can accept map saves from any version. However, I'm currently stuck on how to retrieve the version information from a map save file.
-
- Long Handed Inserter
- Posts: 70
- Joined: Sat Oct 27, 2018 11:10 pm
- Contact:
Re: Any way to detect the version of specific map save?
I think I see it at the start of script.dat. first 8 bytes are 4 16 bit integers representing the version.
ex: 02 00 00 00 0f 00 04 00
= 2 0 15 4
= 2.0.15-4
there are similar bytes in level-init.dat but they would give 2.0.7.0.
(note I can't guarantee the meaning of the values. ie: it is not _necessarily_ the game version; could be the file or format version that is close but not identical to the game version or something like that.)
note also this thread from a long time ago where someone else was doing something similar: viewtopic.php?t=47014
ex: 02 00 00 00 0f 00 04 00
= 2 0 15 4
= 2.0.15-4
there are similar bytes in level-init.dat but they would give 2.0.7.0.
(note I can't guarantee the meaning of the values. ie: it is not _necessarily_ the game version; could be the file or format version that is close but not identical to the game version or something like that.)
note also this thread from a long time ago where someone else was doing something similar: viewtopic.php?t=47014
-
- Manual Inserter
- Posts: 2
- Joined: Mon Nov 11, 2024 5:19 am
- Contact:
Re: Any way to detect the version of specific map save?
I think you're rightMisterDoctor wrote: Mon Nov 11, 2024 7:54 am I think I see it at the start of script.dat. first 8 bytes are 4 16 bit integers representing the version.
ex: 02 00 00 00 0f 00 04 00
= 2 0 15 4
= 2.0.15-4
there are similar bytes in level-init.dat but they would give 2.0.7.0.
(note I can't guarantee the meaning of the values. ie: it is not _necessarily_ the game version; could be the file or format version that is close but not identical to the game version or something like that.)
note also this thread from a long time ago where someone else was doing something similar: viewtopic.php?t=47014
