~ruther/nixos-config

ref: 5b1602c8f5563556f28c67d066d1aee7b46e55e7 nixos-config/modules/programs/games.nix -rw-r--r-- 1.1 KiB
5b1602c8 — Frantisek Bohacek chore: update 1 year, 3 days ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#
# Gaming
# Steam + MC + Emulation
#
# Do not forget to enable Steam play for all title in the settings menu
#

{ pkgs, lib, ... }:

{
  environment.systemPackages = [
    pkgs.lunar-client
    # pkgs.heroic
    # pkgs.lutris
    # pkgs.prismlauncher
    # pkgs.retroarchFull
    # pcsx2
  ];

  programs = {                                  # Needed to succesfully start Steam
    steam = {
      enable = true;
    };
    gamemode.enable = true;                     # Better gaming performance
                                                # Steam: Right-click game - Properties - Launch options: gamemoderun %command%
                                                # Lutris: General Preferences - Enable Feral GameMode
                                                #                             - Global options - Add Environment Variables: LD_PRELOAD=/nix/store/*-gamemode-*-lib/lib/libgamemodeauto.so
  };

  nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [
    "steam"
    "steam-original"
    "steam-runtime"
  ];                                            # Use Steam for Linux libraries
}
Do not follow this link