Skip to content

Getting started with modding

Nightinggale edited this page Nov 29, 2018 · 2 revisions

Getting started with modding

This guide will tell the steps needed to start modding. Modding in this case is modifying any file in the mod, be it programming, graphics, xml setup, translations etc. It's not meant to teach how to mod, just how to get access to the files and run the git version (as in not just download the latest release).

Git usage

The mod is stored in a git repository. For our purpose, think of it as a shared drive online. Everybody can read from the drive and those with an account can write to it. This makes it a lot easier for multiple people to work on the same project at the same time.

Getting an account

You don't need one for read only, but if you want to be able to contribute, you need one. Just sign up for GitHub (you are already here).

Get a git client

In theory any client will do. This guide will assume SmartGIT since it's free and so far is the client, which has caused the least amount of problems for people who never used git before.

Download the files

Use the git clone feature. It's in the repository menu. Clone the URL https://github.com/We-the-People-civ4col-mod/Mod.git. Sometimes it's causing problems with self signed certificates (antivirus etc), in which case the ssh URL can be used ssh://git@github.com/We-the-People-civ4col-mod/Mod.git, though ssh require extra setup. In general, if git doesn't work right in the first try, ask for help.

SSH keys: https://help.github.com/articles/connecting-to-github-with-ssh/

The place to clone is in MODS in Colonization. The repository has the files laid out to work as a mod if cloned to the right location.

Updating to get the newest files is done with the pull button.

Branch selection

The repository has multiple branches, as in different versions of the mod. Advanced users can merge changes from multiple branches, meaning working in a branch is a tool used to avoid conflicts while working. If you need this guide, you most likely shouldn't consider this topic other than work in the branch you are told to work in.

To change a branch, look at the window branches (usually the bottom left). Double click on the branch you want to work on to switch to it. If the branch you need isn't in Local Branches, open origin, double click on the branch in question and accept tracking the branch.

Getting the DLL file

You either have to compile yourself or get the DLL file from somebody with a compiler. Being able to compile yourself can be useful and for some tasks it can be critical. For other tasks (particularly translation work, but also some xml and graphics), being able to compile is far less important.

TODO: write about compiler