Created
May 19, 2023 10:34
-
-
Save gaming-and-other-stuff/ac64418d08272b874822eeaa30666286 to your computer and use it in GitHub Desktop.
What I currently know about .mgm game files
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The .mgm file format is used by the three Madoka Magica TPS games released from December 2011 to October 2012. The format is likely part of a proprietary game engine used by the game's developers, Mebius Co. Ltd./D-Mebius. | |
----------------------------------------------------------- | |
The first 12 bytes are mostly made up of 00's, but there are three places in the first 13 bytes where they aren't 00's. | |
The first, fifth, and ninth bytes don't use 00, but instead use a seemingly random hex digit. I don't know what the purpose of this is at the moment. | |
Examples | |
stage0.mgm from Puella Magi Madoka Magica TPS FEATURING Mami Tomoe (jp.co.fwinc.madomagimamiTPS) | |
0C 00 00 00 05 00 00 00 05 00 00 00 | |
stage1.mgm from Puella Magi Madoka Magica TPS FEATURING Mami Tomoe (jp.co.fwinc.madomagimamiTPS) | |
0C 00 00 00 08 00 00 00 04 00 00 00 | |
stage0.mgm from Puella Magi Madoka Magica TPS FEATURING Homura Akemi (jp.co.fwinc.madomagihomuraTPS) | |
0C 00 00 00 09 00 00 00 04 00 00 00 | |
After the first 12 bytes, the .mgm files all declare which skybox is to be used in the level. | |
Example | |
73 6B 79 30 -> sky0 | |
sky0 corresponds to an image in /res/drawable-nodpi/ called "sky0.png". | |
After the skybox, a 16 byte space is added. The 13th byte uses a seemingly random byte. | |
00 00 00 00 00 00 00 00 00 00 00 00 0X 00 00 00 | |
Example | |
00 00 00 00 00 00 00 00 00 00 00 00 07 00 00 00 | |
After the space, textures to be used in the level are declared. Depending on the level, skybox elements are also declared afterwards. | |
Examples | |
69 6D 61 67 65 34 -> image4 | |
73 6B 79 31 -> sky1 | |
69 6D 61 67 65 34 00 00 00 00 00 00 00 00 00 00 00 00 04 00 00 00 73 6B 79 31 | |
image4................sky1 | |
After declaring the skybox and textures, the level data itself is presumably the data that takes up most of the file. | |
The file ends with 12 bytes of 00 hex digits. | |
00 00 00 00 00 00 00 00 00 00 00 00 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment