MIX: Difference between revisions
m Shifted VXL/HVA from ecache to expands due to the classic modding doing it. Also fixed some typos. |
m Changed the expandmd##, ecache* explanation. |
||
Line 54: | Line 54: | ||
As a result of this, it is common to distribute new and modified files as follows: | As a result of this, it is common to distribute new and modified files as follows: | ||
=== {{tt|expand{{co|md|#D2691E}}##.mix}} === | === {{tt|expand{{co|md|#D2691E}}##.mix}} === | ||
This is | This file is used for addon or expansion purpose where new or modified files can be placed. Most filetypes can be placed in it, except the files from lang*.mix which are higher in loading hierarchy. | ||
*[[INIs]] | *[[INIs]] | ||
*[[File_Types#.TEM.2C .SNO.2C .URB.2C .UBN.2C .LUN.2C .DES|.TEM, .SNO, .URB, .UBN, .LUN, .DES]] | *[[File_Types#.TEM.2C .SNO.2C .URB.2C .UBN.2C .LUN.2C .DES|.TEM, .SNO, .URB, .UBN, .LUN, .DES]] | ||
Line 62: | Line 62: | ||
*[[VXL]]s | *[[VXL]]s | ||
*[[HVA]]s | *[[HVA]]s | ||
In RA2 expand##, game doesn't accept some filetypes placed in it like SHPs (Buildings, infantries etc.) or Tree files, those would become invisible in-game. Such files could be placed in ecache*. | |||
=== {{tt|ecache*.mix}} === | === {{tt|ecache*.mix}} === | ||
As the name suggests, this is a cache file. | As the name suggests, this is a cache file. This file is lower in file loading heirarchy than many other mix files. So the game will read new or modified SHP files from it but only VXL/HVA files with different filenames over the original mix files. Both RA2 and YR read the files placed in ecache*, so it could be used as common resouorce file. | ||
*[[SHP]]s (normal buildings, infantry etc.) | *[[SHP]]s (normal buildings, infantry etc.) | ||
*[[AUD]] files (Not used in [[Red Alert 2]]/[[Yuri's Revenge]]) | *[[AUD]] files (Not used in [[Red Alert 2]]/[[Yuri's Revenge]]) |
Revision as of 11:02, 26 June 2017
.mix is the extension for the files used by Westwood to store most game files up until Yuri's Revenge. For Generals and following, big-files took this part.
Editing Mix-files
Mix-files are read, edited and created using the XCC Mixer and the XCC Mix Editor, both created by Olaf van der Spek. They can be downloaded at http://xccu.sourceforge.net.
File Names and Loading Hierarchy
Naming your MIX correctly is important for the correct execution of your mod.
There are three names/naming systems
- expandmd##.mix
- Where ## is a number between 01 and 99, and md is added if the the file is for Yuri's Revenge.
- ecache*.mix
- Where * can be any string.
- elocal*.mix
- Where * can be any string.
Loading Hierarchy
The game searches the MIX files for contents in this order. Once a file is found in a mix, the next MIXes don't even get checked for its presence.
- A higher-numbered expandmd##.mix has a higher level than a lower numbered one.
- For ecache* and elocal* files, order is not guaranteed - standard WinAPI functionality is used to locate them, and no sorting is done.
- Quoting MSDN - FindNextFile:
- The order in which this function returns the file names is dependent on the file system type. With the NTFS file system and CDFS file systems, the names are usually returned in alphabetical order. With FAT file systems, the names are usually returned in the order the files were written to the disk, which may or may not be in alphabetical order. However, as stated previously, these behaviours are not guaranteed.
- Additionally, files that have any of the "Hidden", "System" or "Temporary" attributes set are not loaded.
- Quoting MSDN - FindNextFile:
- LANGMD.MIX
- LANGUAGE.MIX
- EXPANDMD##.MIX ;( 99, 98, ... 02, 01)
- RA2MD.MIX
- RA2.MIX
- CACHEMD.MIX
- CACHE.MIX
- LOCALMD.MIX
- LOCAL.MIX
- AUDIOMD.MIX
- ECACHE*.MIX
- ELOCAL*.MIX
- CONQMD.MIX
- GENERMD.MIX
- GENERIC.MIX
- ISOGENMD.MIX
- ISOGEN.MIX
- CONQUER.MIX
- CAMEOMD.MIX
- CAMEO.MIX
- MAPSMD03.MIX
- MULTIMD.MIX
- THEMEMD.MIX
- MOVMD03.MIX
- theater-specific MIXes - see Theatres for a list
- SIDEC##.MIX ;the ## stands for side you're playing as - 1 for Allied
- SIDENC##.MIX
As a result of this, it is common to distribute new and modified files as follows:
expandmd##.mix
This file is used for addon or expansion purpose where new or modified files can be placed. Most filetypes can be placed in it, except the files from lang*.mix which are higher in loading hierarchy.
- INIs
- .TEM, .SNO, .URB, .UBN, .LUN, .DES
- WAVs (EVA voices, not the audio normally stored in audio.bag)
- SHPs (interface-/screen-elements, including side-related GUI ones)
- FNTs (general game font which can be edited by a FNT editor)
- VXLs
- HVAs
In RA2 expand##, game doesn't accept some filetypes placed in it like SHPs (Buildings, infantries etc.) or Tree files, those would become invisible in-game. Such files could be placed in ecache*.
ecache*.mix
As the name suggests, this is a cache file. This file is lower in file loading heirarchy than many other mix files. So the game will read new or modified SHP files from it but only VXL/HVA files with different filenames over the original mix files. Both RA2 and YR read the files placed in ecache*, so it could be used as common resouorce file.
- SHPs (normal buildings, infantry etc.)
- AUD files (Not used in Red Alert 2/Yuri's Revenge)
elocal*.mix
This file is practically not used in the community, but works for "unofficial SHP, VXL, HVA and MAP files" according to DeeZire's Red Alert 2 and Yuris Revenge INI Editing Guide. Since, in the original game, local.mix holds almost all object-related graphics, and elocal*.mix works for the same file types, it is likely it was originally conceived as an expansion file specifically for local.mix. It is unknown why the community started using ecache*.mix for unit graphics instead.
Loose
Note that, despite this common distribution of files, many files (especially graphics) work in an expandmd##.mix as well.
How to make a new MIX file
Important: In order to be read by the game, your new mix has to reside in the game's folder, and has to be named correctly.
Using XCC Mix Editor
Click New and choose where to save it. To add files to a mix file you can go to import or you can use the faster method of "drag 'n drop" you can select files from explorer and drag them into the XCC Mix Editor window. Next press the "Compact" button, this saves and compresses the file.
Using XCC Mixer
Click File - New and select where to save it. Then, navigate there and open that file in the Mixer. Now you can actually drag and drop files to the Mixer as well to add them, there is an option to compact in the context menu that appears when you right click on a file in that mix.
Location of files in the game's mix files
RA2/YR
- The INI files are in RA2.mix → local.mix and RA2md.mix → localmd.mix. rulesmd.ini and soundmd.ini for YR 1.001 are in expandmd01.mix.
- Cameos (build icons), which are single frame SHPs, can found in language.mix → cameo.mix and in langmd.mix → cameomd.mix.
- Infantry, which are multi frame SHPs, can be found in RA2.mix → conquer.mix and ra2md.mix → conqmd.mix.
- The voxels (and their associated hva files), Tanks, naval vessels, and aircraft, can be found in ra2.mix → local.mix and ra2md.mix → localmd.mix.