This repository has no description
0

Configure Feed

Select the types of activity you want to include in your feed.

superconfig / games / jazz2 / default.nix
1.4 kB 59 lines
1{ 2 fetchurl, 3 jazz2, 4 lib, 5 runCommandLocal, 6 stdenvNoCC, 7 unzip, 8 writeShellScript, 9}: 10 11let 12 jazz2-mp = jazz2.overrideAttrs (old: { 13 cmakeFlags = old.cmakeFlags ++ [ 14 (lib.cmakeBool "WITH_MULTIPLAYER" true) 15 ]; 16 }); 17 18 gameData = fetchurl { 19 url = "https://archive.org/download/jazz-jackrabbit-2-1.24-the-secret-files-plus/Jazz%20Jackrabbit%202%201.24%20The%20Secret%20Files%20Plus.zip"; 20 hash = "sha256-ceeXiGUy5QDq1HQPo5gpyQe2odAK1F5frofBXegeXi8="; 21 name = "jazz-jackrabbit-2-tsf.zip"; 22 }; 23 24 sourceData = 25 runCommandLocal "jazz2-source-data" 26 { 27 nativeBuildInputs = [ unzip ]; 28 } 29 '' 30 mkdir -p "$out/Jazz² Resurrection/Source" 31 unzip -j -o ${gameData} -d "$out/Jazz² Resurrection/Source/" 32 ''; 33 34 wrapper = writeShellScript "jazz2" '' 35 datadir="''${XDG_DATA_HOME:-$HOME/.local/share}/Jazz² Resurrection" 36 if [ ! -e "$datadir/Source/Anims.j2a" ]; then 37 mkdir -p "$datadir" 38 rm -rf "$datadir/Source" 39 ln -sfn "${sourceData}/Jazz² Resurrection/Source" "$datadir/Source" 40 fi 41 exec ${lib.getExe jazz2-mp} "$@" 42 ''; 43in 44 45stdenvNoCC.mkDerivation { 46 pname = "jazz2-with-gamedata"; 47 inherit (jazz2) version; 48 49 dontUnpack = true; 50 51 installPhase = '' 52 mkdir -p $out/bin 53 ln -s ${wrapper} $out/bin/jazz2 54 ''; 55 56 meta = jazz2.meta // { 57 description = "Jazz Jackrabbit 2 (Jazz² Resurrection with game data and multiplayer)"; 58 }; 59}