about summary refs log tree commit diff
path: root/pkgs/games/cataclysm-dda
diff options
context:
space:
mode:
authorMitsuhiro Nakamura <m.nacamura@gmail.com>2020-04-09 19:53:02 +0900
committerMitsuhiro Nakamura <m.nacamura@gmail.com>2020-07-18 14:23:23 +0900
commitd472eed4b570f9392aad7a4f2a1bdbf2b5fd5bf8 (patch)
tree589d2b76dee498eab2fd65a7d778e1952e54d03e /pkgs/games/cataclysm-dda
parent633f21111314ac3ee34d9103e72f7de08cd12daf (diff)
cataclysmDDA: add README
Diffstat (limited to 'pkgs/games/cataclysm-dda')
-rw-r--r--pkgs/games/cataclysm-dda/README.md83
1 files changed, 83 insertions, 0 deletions
diff --git a/pkgs/games/cataclysm-dda/README.md b/pkgs/games/cataclysm-dda/README.md
new file mode 100644
index 0000000000000..e8fe17a2661aa
--- /dev/null
+++ b/pkgs/games/cataclysm-dda/README.md
@@ -0,0 +1,83 @@
+# Cataclysm: Dark Days Ahead
+
+## Installation
+
+To install the latest stable release of Cataclysm DDA, run
+`nix-env -f "<nixpkgs>" -iA cataclysm-dda`.
+For the curses build (build without tiles), install `cataclysmDDA.stable.curses`.
+Note: `cataclysm-dda` is an alias to `cataclysmDDA.stable.tiles`.
+
+If you like access to a development build of your favorite git revision, override
+`cataclysm-dda-git` (or `cataclysmDDA.git.curses` if you like no tiles):
+
+```nix
+cataclysm-dda-git.override {
+  version = "YYYY-MM-DD";
+  rev = "YOUR_FAVORITE_REVISION";
+  sha256 = "CHECKSUM_OF_THE_REVISION";
+}
+```
+
+The sha256 checksum can be obtained by
+
+```sh
+nix-prefetch-url --unpack "https://github.com/CleverRaven/Cataclysm-DDA/archive/${YOUR_FAVORITE_REVISION}.tar.gz"
+```
+
+## Customizing with mods
+
+To install the game with mods of your choice, you can use `withMods` attribute:
+
+```nix
+cataclysm-dda.withMods (mods: with mods; [
+  tileset.UndeadPeople
+])
+```
+
+All mods, soundpacks, and tilesets available in nixpkgs are found in
+`cataclysmDDA.pkgs`.
+
+To modify existing mods and/or add more mods not available in nixpkgs, you can
+do it like this way:
+
+```nix
+let
+  customMods = self: super: lib.recursiveUpdate super {
+    # Modify existing mod
+    tileset.UndeadPeople = super.tileset.UndeadPeople.overrideAttrs (old: {
+      # If you like to apply a patch to the tileset for example
+      patches = [ ./path/to/your.patch ];
+    });
+
+    # Add another mod
+    mod.Awesome = cataclysmDDA.buildMod {
+      modName = "Awesome";
+      version = "0.x";
+      src = fetchFromGitHub {
+        owner = "Someone";
+        repo = "AwesomeMod";
+        rev = "...";
+        sha256 = "...";
+      };
+      # Path to be installed in the unpacked source (default: ".")
+      modRoot = "contents/under/this/path/will/be/installed";
+    };
+
+    # Add another soundpack
+    soundpack.Fantastic = cataclysmDDA.buildSoundPack {
+      # ditto
+    };
+
+    # Add another tileset
+    tileset.SuperDuper = cataclysmDDA.buildTileSet {
+      # ditto
+    };
+  };
+in
+cataclysm-dda.withMods (mods: with mods.extend customMods; [
+  tileset.UndeadPeople
+  mod.Awesome
+  soundpack.Fantastic
+  tileset.SuperDuper
+])
+```