about summary refs log tree commit diff
path: root/pkgs/games/build-support/build-unity.nix
Commit message (Collapse)AuthorAgeFilesLines
* games/build-unity: Add support for .app dirsaszlig2018-06-281-1/+6
| | | | | | | | | | | | | | | Some games (well, currently just one, Dungeons 3) come with a .app directory that contains additional game data which includes package .unity3d files. Such directories will be searched relative from the current working directory, so let's actually set the working directory to $out/share/something and copy the .app directory to that if it exists. Tested with Dungeons 3 and also with a few other Unity3d games to see whether they still work. Signed-off-by: aszlig <aszlig@nix.build>
* pkgs/games: Replace usages of mesa with libGLaszlig2018-04-211-2/+2
| | | | | | | | | | | | | This has been changed in NixOS/nixpkgs@6bf1421f13d667c2997b67728cf777c6, so let's change it here as well. Quote from the mentioned commit: Implement libGL as a symlink package which uses libraries from libglvnd and headers from Mesa (since ones from libglvnd are outdated). Signed-off-by: aszlig <aszlig@nix.build>
* build-unity: Properly re-add attributesaszlig2018-02-091-2/+2
| | | | | | | | A few attributes weren't re-added to the actual derivation, so for example whenever we add buildInputs to buildUnity the attribute would be completely ignored. Signed-off-by: aszlig <aszlig@nix.build>
* pkgs/build-unity: Make saveDir optionalaszlig2017-11-211-3/+5
| | | | | | | | If the saveDir isn't set the game only gets access to all the saveDirs from other Unity games, so missing that attribute shouldn't be a deal breaker. Signed-off-by: aszlig <aszlig@nix.build>
* pkgs/build-unity: Add a saveDir attributeaszlig2017-11-211-2/+2
| | | | | | | | This is used for sandboxing and instead of letting all Unity games access the data of every other Unity game we now restrict it to its own save directory only. Signed-off-by: aszlig <aszlig@nix.build>
* pkgs/sandbox: Handle non-existing pathsaszlig2017-11-211-2/+9
| | | | | | | | | | | | | | | | | | We now distinguish between paths that have to exist and paths that are fine to skip during bind mounting. So far we had hard failures whenever a path that needed to be mounted didn't exist, for example something like $XDG_CONFIG_HOME/unity3d failed whenever the directory didn't exist. Apart from that we now have a more clean attribute structure for sandbox parameters, which are now: * paths.required: Created prior to bind-mounting * paths.wanted: Skipped if it doesn't exist * paths.runtimeVars: Extracted from PATH-like environment variables Signed-off-by: aszlig <aszlig@nix.build>
* pkgs/build-game: Enable sandbox by defaultaszlig2017-10-031-0/+2
| | | | | | | | | This is using buildSandbox with the addition of adding LD_LIBRARY_PATH to the default runtimePathVars. I've also renamed the attribute to be called runtimePathVars instead of runtimePathVariables, simply because it's shorter. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
* pkgs/build-unity: Switch to using buildGameaszlig2017-09-131-23/+19
| | | | | | | | | | | Now we no longer need to invoke patchelf by ourselves and all of the dependencies are patched automatically. I've added gtk2-x11, gdk_pixbuf and glib to buildUnity as well, because after inspecting other Unity games they seem to require the same libraries as well. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
* pkgs/build-unity: Create desktop entryaszlig2017-09-101-2/+19
| | | | | | | | | | | | This automatically creates a desktop entry based on the given fullName and the standard path for the icon (Resources/UnityPlayer.png). Well, at least I hope that the icon path is standard, but we'll see once we use buildUnity for more games. Tested using Plasma 5 for Invisigun Heroes. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
* pkgs/build-unity: Wrap binary instead of linkingaszlig2017-09-101-2/+4
| | | | | | | | The executable of Unity games at the moment is unable to find its own path if it can't do a stat() on argv[0]. So wrapping the program helps here for now. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
* games/invisigun-heroes: Factor out into buildUnityaszlig2017-09-101-0/+49
There are a lot of Unity games out there, so it's a good idea to have a generic builder just for Unity, which we then can apply to a lot more games. Right now this is a pretty basic abstraction which I've only tested with Invisigun Heroes. Signed-off-by: aszlig <aszlig@redmoonstudios.org>