Skip to content

Instantly share code, notes, and snippets.

Niklas Haas haasn

Block or report user

Report or block haasn

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
haasn /
Last active Oct 23, 2018
PS4 backlog / collection


  • 1/5: I can't find a redeeming feature of the game. I did not enjoy even a second of it.
  • 2/5: Probably not worth playing unless you're super into it for some reason. I liked some parts but overall it was not a particularly enjoyable experience.
  • 3/5: Average game. Worth a play if you have money to spare but not a super high priority pickup. I enjoyed some aspects but got annoyed by others.
haasn / heroline.hs
Last active Jul 24, 2016
HeroLine DPS calculator -- NOTE: moved to
View heroline.hs
import Control.Monad (replicateM, guard)
import Data.Ord (comparing)
import Data.List (maximumBy)
-- Type definitions
data Item = Item
{ name :: String
, wdmg :: Int
, udmg :: Int

Keybase proof

I hereby claim:

  • I am haasn on github.
  • I am haasn ( on keybase.
  • I have a public key ASAN_wtvtyoVO_75tpC2zkdYGpL76sjwNWPDf_1p8ecGIAo

To claim this, I am signing this object:

haasn / image.lua
Last active Sep 18, 2019
mvi - set of configuration for turning mpv into an image viewer
View image.lua
-- Allow changing a property with by zoom-adjusted amount
function zoom_invariant_add(prop, amt)
amt = amt / 2 ^ mp.get_property_number("video-zoom")
mp.set_property_number(prop, mp.get_property_number(prop) + amt)
-- Resets the pan if the entire image would be visible
function zoom_check_center()
local zoom = mp.get_property_number("video-zoom")
local rot = mp.get_property_number("video-rotate") * math.pi / 180
haasn / kspfix.c
Last active Jun 7, 2016
Work-around for Kerbal Space Program under 10-bit displays (or any Unity game, really)
View kspfix.c
// Compile as and load with LD_PRELOAD
#define _GNU_SOURCE
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <dlfcn.h>
#include <GL/glx.h>
haasn /
Last active Oct 20, 2019
Firefox bullshit removal via about:config

Firefox bullshit removal

Updated: Just use qutebrowser (and disable javascript). The web is done for.

You can’t perform that action at this time.