Contributing

From The Cataclysm: Dark Days Ahead Wiki
Jump to navigation Jump to search

There are several ways you can contribute to the C:DDA project. You can write code, support bugs, update documentation, help answer questions of people, or even donate money to help hosting and or fund development. This page will explain the several methods how to contribute.

Helping with the wiki

There are a lot of things that still need to be fixed on this wiki. You can help with this. We have a centralised list of things that need to be done, but here are some common recurring things that need to be done to get you started:

  • Look at the Category:Unknown_version pages, try to figure out for which version the page is, and update the {{ver}} template with the correct version. Or update the whole page to the most recent version, rewrite what you can. The main idea is to keep the wiki as updated as possible with the most recent experimental, but also to make keeping the wiki updated in the future relatively hassle free. So feel free to tag old pages with {{delete}}, remove information, or rewrite stuff. Just try to add the current experimental version using the template:ver template when you do.
  • Pick a guide from the Category:Guides, see if it is still up to date, and if it isn't update it, and tag it for the correct version using the template:ver template.
  • Fix one of the stub pages that needs more information Category:Stub.
  • Fix one of the pages that needs more information Category:Verify.
  • Look at the Special:SpecialPages and fix double redirects, broken redirects, pages that are orphaned (check if they are still needed/exist in the current version of the game, orphaned pages are not linked anywhere on the wiki).
  • While it can help, it usually is a bad idea to make item pages for items that don't exist yet. Unless the items are very important. Due to the high list of items in the game, it is usually better to use a program to automatically update/create any missing pages, which doesn't exist yet, feel free to bother Soyweiser to create a script for this. If you add a new item page, don't bother with writing down the statistics of the item, bother with how you can use it, where you can find it (if rare) and other special information about it. Stuff that can't be easily understood from the item description basically.
  • Same goes for monster/bionic/etc pages btw. A lot of information can easily be automatically generated.
  • If there is a page without a {{ver}}, update that page with either the correct version, or 'unknown' if you don't know.
  • Look at the Special:RecentChanges page, check if there was no vandalism, and check new additions by other users.
  • See the Todo page for a bigger list of things that you could help us all with

Contributing JSON

See The Guide to adding new content to CDDA for first time contributors. Please read carefully because the guide is fairly comprehensive but somewhat haphazardly organized.

Contributing code

For an up to date guide see CONTRIBUTING.md. Might be a bit hard to read, as it contains a lot of information. But if this page contradicts CONTRIBUTING.md, the latter is probably right.

This is a guide to setting up and using Git for the purposes of contributing to Cataclysm:DDA. This does not cover astyle, or the two spaces after sentences, or four spaces instead of indents.

First, make yourself a Github account here:

https://github.com/join?source=header-home 

Then, download Git from here:

https://git-scm.com/downloads

Then install Git, for our purposes we are going to tell it to use its own Git Shell, which is where you will be entering these commands.

git clone https://github.com/CleverRaven/Cataclysm-DDA.git

cd Cataclysm-DDA

git checkout -b YourNewForkName

Then you want to make the changes to the code you just created. Once you are done, compile if you made changes to code, or run the game if you made changes to JSON, and then go back to the Git shell.

If it is your first time using git, you need to tell it who you are:

git config --global user.name "YourGithubUserName"

git config --global user.email "YourGithubUserEmail"

Then you want to change the upstream to your own account. You can get your .git link at the top of your github page, under clone or download. It will look like this:

https://github.com/YourGithubUsername/Cataclysm-DDA.git

You change the upstream like this:

git remote set-url origin https://github.com/YourGithubUsername/Cataclysm-DDA.git

Then you add the files and commit them:

git add .

git commit

This will bring you to a VIM (I think) window. Delete the lines with # in front, and let us know what you did briefly in your commit message. When you are done, hit esc, then :wq then:

git push origin YourNewForkName

Then go to your github user page, and at the top it will say something like, "YourNewForkName was pushed a couple seconds ago" you want to hit "merge / create pull request". Fill this out with more detail than your commit message. Then hit "create pull request."

Rough "for dummies" guide

This is intended to be easy to follow rather than comprehensive, so reference other guides when necessary. If another guide contradicts this one, probably listen to that one, unless it's out of date.

Compiling (Windows 10):

  1. Fork the repository on github and clone your version to somewhere on your machine
  2. Install Windows Subsystem for Linux (gets you a nice Bash shell with Ubuntu without needing to switch to a VM)
  3. sudo apt install everything mentioned in COMPILING.md that sounds like you should install it
  4. cd into /mnt/c/wherever you cloned it to
  5. Compile with make in the source cdda directory (just make should be fine, probably)
  6. Run with ./cataclysm

Using github to actually make changes:

  1. Set up remotes for origin (your fork) and upstream (main repository), and do the other things to set it up with github
  2. git branch some-name and git checkout some-name to create a new branch based on the current branch
  3. git pull -r upstream master to get changes from main repository
  4. Make changes
  5. git commit -a -m "Brief description of changes" (preferably do this regularly if you're doing a lot)
  6. git push origin some-name to update your fork with new changes (might need to do git push --force origin some-name if it complains, usually after rebasing (pull -r) from upstream)
  7. Test to make sure your code works, and compiles! Do not create a pull request for code that doesn't work. This wastes the other developers time.
  8. Create a pull request (there might be a way to do it in the terminal but I just use the website)
  9. Fix anything the checks (or other people) complain about
  10. Wait for someone to merge it

Submitting bugs

If you have made a github account, as described above, you can also submit bugs/problems/requests for change to the project. This is a lot easier than adding code.

First read how to properly submit an issue to the project. See issues.md here. It is important to read this well and follow these guidelines. As proper issue reporting will save the people trying to fix the issues a LOT of time. And the less time they spend on bugs, the sooner we all get new stuff.

After reading, log into your github account go to the Cataclysm-DDA issue page. First search if your issue has not been reported already. If it has, great! Saves you work, see if you can add more information to the existing issue, and if it is a closed issue, or a stale issue, mention it is still a problem. At least, if you are still running a current version of the game. Like the experimental version. As bug reports about older versions are not valuable, as the old versions are no longer being developed, and the code has probably been changed.

If the issue has not been reported, follow the steps described in issues.md above and write up a good description of the problem. Submit it. And done.

Wait! not really done yet. Do check your email, or the issue page if you don't allow github to send you emails, for any updates on the issue, there might be some things that are not clear, so stick around to answer some questions. It really helps a lot!

Adopting a mod

Due to the nature of C:DDA there always will be new and old mods which are created, will become popular and later are no longer really maintained by anybody, as people drift into and out of the C:DDA project. This causes a build-up no longer maintained but popular mods. You can help by becoming the maintainer of one of those mods. This means you need to update the old mod to work using new versions and new mechanics. As an old example, when various block abilities and martial art styles were introduced to work with various weapons, some unmaintained mods, which should either have these abilities or work with these styles were never updated for these things, this is one of the many things that should be checked and done. But also updating recipes, checking for game balance etc. It is a task which is much needed but for which not many people step up.

How to find obsolete mods? Again, as C:DDA is a relatively fast moving project, finding obsolete mods can be tricky, best is to either check this github pr which obsoleted a some popular, but no longer maintaned mods, but you can also ask around on the C:DDA discord server, or any other place. Or just look at mods you use, but which seem to have bugs in them. Also, as always, try to find whomever made the mod, or maintained it before, and strike up a conversation with them about if you can take over, or how you can work together to improve the mods.

Updating documentation, and writing guides

C:DDA has quite a lot of documentation about it. While most data about the game can easily be gotten from the item browser. But a lot of other information needs to be updated, or checked. Especially the wiki (you are here). You are always welcome to help out on the wiki (just make an account here, via the buttons in the upper right corner of the screen), or with suggestions on how to improve the ingame documentation (you will need to make a github account, and either make an issue out of it, or edit the code, as described above).

You can also write for advanced subjects, such as how to build multi story buildings, or surviving longer, or any other subject that you find important. First, look here at the wiki, if such a guide doesn't already exist, then improving the existing guide is probably better. Lets be honest, you can probably do a better job than the previous editor, and that guide is already outdated. So get to work.

There might also be guides at other places in the community, so you might want to ask/look around so you don't duplicate something already out there.

One word of warning, the CONTRIBUTING.md file linked above also speaks about documentation. But that is for programmers how to properly document their code. Which is different from the documentation meant here, which is for the players of C:DDA.

Translation

There is a special part on the CONTRIBUTING.md file listed earlier about how to help with translations. You should make an account at transifex, and follow the instructions in the TRANSLATING.md document.

We love it when more people help translating the game, it makes the game a lot more accessible to different people.

Answering questions, and helping people

There are various places the community gathers, such as the forums, irc, r/cataclysmdda's subreddit, and the C:DDA discord channel, including a lot of new players who have questions about the game. Or older players who don't know everything. Knowledgeable, well read people (which you obviously are, if you reached this far into this guide), are a great resource. Just head out there and answer people's questions.

Donating

Don't have much time or programming skills? But you do have spare money? You can always help by donating. First, you can donate to Chesthole/Chezzo's patreon. He generously hosts this wiki, the item browser, creates tilesets and more.

Second, you can use the github bounty system. Where you put bounties on certain pieces of improvements you want to see to the code. And if somebody implements them, they get the monetary reward. While this is no guarantee somebody will implement the thing you want, it will at least be a little bit more appealing.

Lastly, you can always try to contact Kevin Granade and directly donate to him, or the project. He is generally available at the various community locations listed above. He can be a busy man however, so don't expect instant reactions.

So in short: