about summary refs log tree commit diff
path: root/modules/nixos/games
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--modules/nixos/games/default.nix (renamed from modules/nixfiles/games/default.nix)0
-rw-r--r--modules/nixos/games/gamemode.nix (renamed from modules/nixfiles/games/gamemode.nix)0
-rw-r--r--modules/nixos/games/gog.nix (renamed from modules/nixfiles/games/gog.nix)0
-rw-r--r--modules/nixos/games/lutris.nix (renamed from modules/nixfiles/games/lutris.nix)7
-rw-r--r--modules/nixos/games/mangohud.nix (renamed from modules/nixfiles/games/mangohud.nix)6
-rw-r--r--modules/nixos/games/minecraft.nix (renamed from modules/nixfiles/games/minecraft.nix)4
-rw-r--r--modules/nixos/games/steam-run.nix (renamed from modules/nixfiles/games/steam-run.nix)26
-rw-r--r--modules/nixos/games/steam.nix (renamed from modules/nixfiles/games/steam.nix)17
8 files changed, 27 insertions, 33 deletions
diff --git a/modules/nixfiles/games/default.nix b/modules/nixos/games/default.nix
index 1c5766b..1c5766b 100644
--- a/modules/nixfiles/games/default.nix
+++ b/modules/nixos/games/default.nix
diff --git a/modules/nixfiles/games/gamemode.nix b/modules/nixos/games/gamemode.nix
index 051d12e..051d12e 100644
--- a/modules/nixfiles/games/gamemode.nix
+++ b/modules/nixos/games/gamemode.nix
diff --git a/modules/nixfiles/games/gog.nix b/modules/nixos/games/gog.nix
index 86039f1..86039f1 100644
--- a/modules/nixfiles/games/gog.nix
+++ b/modules/nixos/games/gog.nix
diff --git a/modules/nixfiles/games/lutris.nix b/modules/nixos/games/lutris.nix
index e7faef3..72179fc 100644
--- a/modules/nixfiles/games/lutris.nix
+++ b/modules/nixos/games/lutris.nix
@@ -16,20 +16,17 @@ in {
       steam-run.enable = true;
     };
 
-    # This removes the annoying warning.
-    boot.kernel.sysctl."dev.i915.perf_stream_paranoid" = 0;
-
     hm.home.packages = with pkgs; [
       (lutris.override {
         lutris-unwrapped = lutris-unwrapped.override {
           wine = buildFHSUserEnv {
-            # We don't really need Wine because Lutris downloads the required
+            # We don't really need Wine because Lutris downloads a required
             # runtime for us.
             name = "empty";
           };
         };
-        steamSupport = false;
       })
+      vkBasalt
     ];
   };
 }
diff --git a/modules/nixfiles/games/mangohud.nix b/modules/nixos/games/mangohud.nix
index b521687..d693c82 100644
--- a/modules/nixfiles/games/mangohud.nix
+++ b/modules/nixos/games/mangohud.nix
@@ -13,13 +13,13 @@ in {
       enable = true;
       settings = {
         fps = true;
+        frame_timing = true;
         gpu_stats = true;
         gpu_temp = true;
         cpu_stats = true;
         cpu_temp = true;
-      };
-      settingsPerApplication = {
-        mpv.no_display = true;
+        ram = true;
+        vram = true;
       };
     };
   };
diff --git a/modules/nixfiles/games/minecraft.nix b/modules/nixos/games/minecraft.nix
index 47279f8..e53f9eb 100644
--- a/modules/nixfiles/games/minecraft.nix
+++ b/modules/nixos/games/minecraft.nix
@@ -23,8 +23,6 @@ in {
   config = mkMerge [
     (mkIf cfg.client.enable {
       hm.home.packages = with pkgs; [pollymc];
-
-      system.extraDependencies = [inputs.pollymc];
     })
     (mkIf cfg.server.enable {
       # Configurations, opslist, whitelist and plugins are managed imperatively.
@@ -47,8 +45,6 @@ in {
 
       # Defined in /var/lib/minecraft/server.properties.
       networking.firewall.allowedTCPPorts = [55565];
-
-      system.extraDependencies = [inputs.nix-minecraft-servers];
     })
   ];
 }
diff --git a/modules/nixfiles/games/steam-run.nix b/modules/nixos/games/steam-run.nix
index 4731fd6..1a1e61f 100644
--- a/modules/nixfiles/games/steam-run.nix
+++ b/modules/nixos/games/steam-run.nix
@@ -11,12 +11,15 @@ in {
     enable = mkEnableOption "native Steam runtime";
 
     quirks = {
-      mountandblade = mkEnableOption ''fixes for "Mount & Blade: Warband" issues'';
+      mountAndBladeWarband = mkEnableOption ''fixes for "Mount & Blade: Warband" issues'';
+      cryptOfTheNecrodancer = mkEnableOption ''fixes for "Crypt of the NecroDancer" issues'';
     };
   };
 
   config = mkIf cfg.enable {
     nixfiles.modules = {
+      common.nix.allowedUnfreePackages = ["steam" "steam-run"];
+
       games = {
         enable32BitSupport = true;
         gamemode.enable = true;
@@ -27,11 +30,12 @@ in {
       (steam.override {
         extraLibraries = _:
           with cfg.quirks;
-            optionals mountandblade [
+            []
+            ++ optionals mountAndBladeWarband [
               (glew.overrideAttrs (_: super: let
                 opname = super.pname;
               in rec {
-                pname = "${opname}-mbw";
+                pname = "${opname}-runfix";
                 inherit (super) version;
                 src = fetchurl {
                   url = "mirror://sourceforge/${opname}/${opname}-${version}.tgz";
@@ -41,7 +45,7 @@ in {
               (fmodex.overrideAttrs (_: super: let
                 opname = super.pname;
               in rec {
-                pname = "${opname}-mbw";
+                pname = "${opname}-runfix";
                 inherit (super) version;
                 installPhase = let
                   libPath = makeLibraryPath [
@@ -54,16 +58,16 @@ in {
                   patchelf --set-rpath ${libPath} $out/lib/libfmodex64.so
                 '';
               }))
+            ]
+            ++ optionals cryptOfTheNecrodancer [
+              (import (builtins.fetchTarball {
+                url = "https://github.com/NixOS/nixpkgs/archive/d1c3fea7ecbed758168787fe4e4a3157e52bc808.tar.gz";
+                sha256 = "0ykm15a690v8lcqf2j899za3j6hak1rm3xixdxsx33nz7n3swsyy";
+              }) {inherit (config.nixpkgs) config localSystem;})
+              .flac
             ];
       })
       .run
     ];
-
-    nixpkgs.config.allowUnfreePredicate = p:
-      elem (getName p) [
-        "steam"
-        "steam-original"
-        "steam-run"
-      ];
   };
 }
diff --git a/modules/nixfiles/games/steam.nix b/modules/nixos/games/steam.nix
index bbd01f6..8dfa72c 100644
--- a/modules/nixfiles/games/steam.nix
+++ b/modules/nixos/games/steam.nix
@@ -11,18 +11,15 @@ in {
     mkEnableOption "Steam runtime";
 
   config = mkIf cfg.enable {
-    nixfiles.modules.games = {
-      enable32BitSupport = true;
-      gamemode.enable = true;
+    nixfiles.modules = {
+      common.nix.allowedUnfreePackages = ["steam" "steam-original"];
+
+      games = {
+        enable32BitSupport = true;
+        gamemode.enable = true;
+      };
     };
 
     hm.home.packages = with pkgs; [steam];
-
-    nixpkgs.config.allowUnfreePredicate = p:
-      elem (getName p) [
-        "steam"
-        "steam-original"
-        "steam-run"
-      ];
   };
 }

Consider giving Nix/NixOS a try! <3