fake alias implementation
This commit is contained in:
32
overlay/default.nix
Normal file
32
overlay/default.nix
Normal file
@@ -0,0 +1,32 @@
|
||||
# simple.nix
|
||||
let
|
||||
pkgs = import <nixpkgs> { };
|
||||
in
|
||||
pkgs.stdenv.mkDerivation {
|
||||
name = "catz-attack";
|
||||
|
||||
src = ./src/.;
|
||||
|
||||
buildInputs = [
|
||||
pkgs.pkg-config
|
||||
pkgs.sdl3
|
||||
pkgs.sdl3-image
|
||||
pkgs.xorg.libX11
|
||||
pkgs.xorg.libXext
|
||||
pkgs.xorg.libXrender
|
||||
pkgs.xorg.libXcomposite
|
||||
pkgs.xorg.libXcursor
|
||||
pkgs.libxfixes
|
||||
];
|
||||
|
||||
buildPhase = ''
|
||||
echo $CC main.c neko.c -I ./ -o catz-attack $(pkg-config --cflags --libs sdl3 x11 xfixes sdl3-image) -lm
|
||||
$CC main.c neko.c -I ./ -o catz-attack $(pkg-config --cflags --libs sdl3 x11 xfixes sdl3-image) -lm
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
cp real_oneko.gif sample.gif $out/bin/
|
||||
cp catz-attack $out/bin/catz-attack
|
||||
'';
|
||||
}
|
||||
BIN
overlay/res/main
BIN
overlay/res/main
Binary file not shown.
1
overlay/result
Symbolic link
1
overlay/result
Symbolic link
@@ -0,0 +1 @@
|
||||
/nix/store/115rxak3fbaqs4xfglndd333z44bx6lk-catz-attack
|
||||
@@ -68,6 +68,7 @@ SDL_AppResult SDL_AppInit(void **appstate, int argc, char *argv[])
|
||||
char *gif_path = NULL;
|
||||
|
||||
SDL_SetAppMetadata("systemd", "1.0", "org.kernel.systemd");
|
||||
SDL_SetHint("SDL_VIDEO_X11_VISUALID", "argb");
|
||||
|
||||
if (!SDL_Init(SDL_INIT_VIDEO)) {
|
||||
SDL_Log("Couldn't initialize SDL: %s", SDL_GetError());
|
||||
@@ -95,9 +96,10 @@ SDL_AppResult SDL_AppInit(void **appstate, int argc, char *argv[])
|
||||
return SDL_APP_FAILURE;
|
||||
}
|
||||
|
||||
SDL_SetRenderDrawBlendMode(renderer, SDL_BLENDMODE_BLEND);
|
||||
make_window_clickthrough();
|
||||
set_override_redirect();
|
||||
SDL_SetDefaultTextureScaleMode(renderer, SDL_SCALEMODE_PIXELART);
|
||||
//SDL_SetTextureScaleMode(renderer, SDL_SCALEMODE_LINEAR);
|
||||
|
||||
neko_init(renderer, window);
|
||||
|
||||
|
||||
BIN
overlay/src/real_oneko.gif
Normal file
BIN
overlay/src/real_oneko.gif
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 4.7 KiB |
BIN
overlay/src/sample.gif
Normal file
BIN
overlay/src/sample.gif
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.0 MiB |
Reference in New Issue
Block a user