-
Notifications
You must be signed in to change notification settings - Fork 0
Crea Mod File format
Crea Mod Files (abbreviated CMFs) are the main files of CMM. A CMF contains every data CMM needs to process a mod.
Basically CMFs are 7z files with a specified content and the extension .cmf.
CMFs can be compressed in any way 7-Zip can decompress. However, it is highly recommended to stick to this guideline:
- Everything except info.xml and icon.png is compressed with the standard 7z method in one solid block at the highest compression level.
- info.xml is compressed with PPMd and the highest model order.
- icon.png is saved uncompressed.
The content of a CMF is structured as follows:
-
info.xml
This XML file contains all the metadata of the mod. -
icon.png
The logo of the mod. It is a PNG and optional. It is recommended to make the logo square. -
mod.diff
The diff file which contains the differences between the original and the modified files. It is necessary that the diff is in the unified format. -
org folder
The folder which contains the original Crea files while creating the mod. -
add folder
It contains files which add or replace files in Crea. A file will be considered as added if no original Crea file existed while creating the mod. A file will be considered as replaced if an original Crea file existed but creating diff data was not possible. This happens for example if a binary file was modified.
This is the first file which is processed by CMM. It contains all the metadata of the mod. This file has to validate against info.xsd.
The purposes of the elements are as follows:
-
cmf
The root element of the file. The attributeversionspecifies the XML version. The current version is0. -
text
It contains a string. The meaning of the string depends on the parent element. Allowed parent elements arename,descandshortDesc. You can specify the language of the string with the attributelang. The value of it is a language identifier as defined by RFC 3066. -
id
A 256-bit long unique identifier of the mod. CMM identifies mods by this value. This means:
- When you create a new mod, the ID must not already been used by another mod.
- When you update your mod, the ID must stay the same.
Creating a new ID randomly should be sufficient enough. The value is stored in Base64 format as defined by the W3C (which is based on the definition in RFC 2045).
-
name
The name of the mod. The actual string is contained in the elementtext. Severaltextelements are allowed for different languages. The name can only be up to 40 characters long. -
author
The author of the mod. It can only be up to 40 characters long. If the space is not enough, because several people developed the mod, it is recommended to write a team name here. The members of the team can be mentioned indesc. -
shortDesc
A short description of the mod. The actual string is contained in the elementtext. Severaltextelements are allowed for different languages. This short description can only be up to 140 characters long. -
desc
A detailed description of the mod. The actual string is contained in the elementtext. Severaltextelements are allowed for different languages. This long description is optional. -
homepage
An URL to a web page about the mod. A forum thread where the mod is published or something similar is sufficient enough. -
updateLink
An URL where CMM can check for updates. This is optional. The layout of the update page is not specified yet. -
version
The version of the mod. The values of the version are saved invelements inside theversionelement. Only numerical or alphabetical values are allowed. The order of thevelements is important; the most significant value is the first element. The order of the values is not specified yet.
The display format is saved in the attributeformat. The positions of the version values inside the string are defined by empty curly braces ({}). -
tags
The tags of the mod set by the author of the mod. Each tag is saved in atagelement. It can only be up to 40 characters long per tag. You can specify the language of the tag with the attributelang. The value of it is a language identifier as defined by RFC 3066.
Tags are optional. -
changelog
The release notes for every version of the mod. Each release note is saved in anentryelement. The version to which the note corresponds is saved in theversionattribute. The release date of this version is saved in thedateattribute. Its format is defined by the W3C. -
files
The file paths of the mod files. Modified files are saved inmodifyelements. Added files are saved inaddelements. Replaced files are saved inreplaceelements. You can find more details in the Content segment.
The way how CMFs are signed is not specified yet.