m (Protected "Addons": Wiki moved ([edit=sysop] (indefinite) [move=sysop] (indefinite)))
m (Removed protection from "Addons": tidy)
Latest revision as of 20:15, 1 June 2015
The addons format is a method of formatting the folders in a distributed mod to ensure it is easiest to install (GAE users can simply copy the archive to their addons folder, while Glest and MegaGlest users need to only extract the archive into the installation directory and their personal MegaGlest folder, respectively). It is done by having all folders relative to the share/glestae folder (in GAE) or the installation directory (in Glest/MegaGlest). The name of the archive can be any unique name (preferably including version numbers and the name of the mod) while the folder structure must always be constant. Think of it as having the archive merged with the installation directory (or share/glestae directory in GAE).
Packaging a techtree named "my_techtree" would have the folder structure:
Or if you had a mod pack that was distributing various maps, a techtree, and a tileset:
archive_name.7z/techs/my_techtree/[..] /tilesets/my_tileset/[..] /maps/[..]
In short, you can pretend the archive was the installation directory or share/glestae directory.
GAE and Glest/MegaGlest store scenarios in different folders. This is great for preventing engine specific code from getting mixed up, but if your mod uses scenarios that are compatible with both engines, then you will have to have two instances of the scenario. In GAE, scenarios are stored in gae/scenarios whereas in MegaGlest, they are stored in scenarios and tutorials. As well, GAE has a further folder after scenarios which is the category to place the scenario in (default categories are "glest_classic" and "glest_tutorials"). Because the non-supporting engines will ignore the extra folder, you can use both locations. For example:
Having "my_scenario" work in all engines:
Having it work in just GAE:
Or in just Glest/MegaGlest:
To ensure support with the intended GAE target, all addons must be compressed as either zip or 7z. 7z is strongly recommended due to its advantages over zip in size and performance. Both can be compressed and decompressed by the 7zip program. Note that it must be a non-solid 7z archive (by default, it is solid, which is not compatible). This can be changed from the add to archive screen in 7-zip.
On Linux, 7z archives can be created as non-solid by appending -ms=off to the end of the command. For example: 7z a elves.7z ./techs -ms=off. You may need to install the p7zip-full package to get this functionality.
- See Installing mods
One of the biggest features of the addons format, in addition to being a single folder convention between all the engines, is the ease of installation. This varies slightly with the engine used.
In GAE, the archive (as a 7z or zip file) needs to merely be copied to the addons folder.
|Operating system||Location of the addons folder|
|Windows 2000/XP||C:\Documents and Settings\[User name]\glestadv\addons|
|Windows Vista/7||C:\Users\[User name]\glestadv\addons|
In MegaGlest, the archive should be directly extracted (uncompressed) to their personal MegaGlest folder.
|Operating system||Location of the MegaGlest folder|
|Windows 2000/XP||C:\Documents and Settings\[User name]\Application Data\megaglest|
|Windows Vista/7||C:\Users\[User name]\AppData\Roaming\megaglest|
In Glest, there is no user specific installation, so installing a mod installs it for all users. The archive should be directly extracted to the installation folder.
|Operating system||Default installation folder|
|Windows 2000/XP/Vista/7||C:\Program Files\Glest_*|
* denotes the version number, so Glest 3.2.2 would have the folder name Glest_3.2.2.
GAE can play compressed addons without having to uncompress them, allowing for a smaller filesize, as well as eliminating the need to extract the file. Archives are merely placed in the addons folder located in %personal_folder%/glestadv. This is the same folder where the INI and log files are stored. In GAE, it is also possible to use a non-compressed folder to contain addons.
On Linux, this location is ~/.glestadv.