Skip to content

Instantly share code, notes, and snippets.


Alexander "Ananace" Olofsson ananace

View GitHub Profile
ananace /
Created Aug 22, 2018
Example configuration for Steam Proton user settings
#!/usr/bin/env python3
import os
user_settings = {
#logs are saved to $HOME/steam-$STEAM_APP_ID.log, overwriting any previous log with that name
# "WINEDEBUG": "+timestamp,+pid,+tid,+seh,+debugstr,+module",
# "DXVK_LOG_LEVEL": "info",
ananace / gist:de7f30454e99b3952405
Last active Jun 8, 2018
OpenMW Windows Development Environment Setup - Appveyor scripts
View gist:de7f30454e99b3952405

NB; (An updated version of this guide can be found on the wiki)

OpenMW Windows Dev-Env

What you need?

  • Visual Studio 2013 or 2015 (Community edition is enough)
  • MSYSGit or Git for Windows as it's also called (cinst git.install if you have Chocolatey)
ananace / PackingExample.cpp
Last active May 6, 2018
Message packing example for libyojimbo, with built-in compression.
View PackingExample.cpp
#include <yojimbo.h>
#include <miniz.h>
class PackedMessage : public yojimbo::BlockMessage
enum { MsgType = 0x00 };
template <typename Stream>
bool Serialize(Stream& stream)
ananace / 99-better-pa.patch
Created Mar 22, 2018
PA patch for qemu 2.11
View 99-better-pa.patch
diff --git a/audio/audio.c b/audio/audio.c
index beafed209b..6f42a019b0 100644
--- a/audio/audio.c
+++ b/audio/audio.c
@@ -2066,3 +2066,8 @@ void AUD_set_volume_in (SWVoiceIn *sw, int mute, uint8_t lvol, uint8_t rvol)
+int64_t audio_get_timer_ticks(void)
ananace /
Last active Jan 28, 2018
Puppet SSL certs example for Kubernetes

Kubernetes API cert with Puppet CA


  • Create the folder /etc/puppetlabs/puppet/ssl/manual_ca
  • Add the contents of the gist into there
  • Run
  • Deploy the generated cert and private key onto your K8s master.
ananace / Event.hpp
Created Apr 26, 2016
Simple C#-like event handling in C++11
View Event.hpp
#pragma once
#include <functional>
#include <vector>
template<typename... Args>
class Event
typedef std::function<void(Args...)> EventHook;
View gist:7023952
Current Server:
Port: 4567
Header - 5 bytes, network order:
Flags - 1 byte:
SYN - 1
ACK - 2
ananace / gist:6410128
Created Sep 2, 2013
Sublime Update script
View gist:6410128
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
import re
import sys
import urllib2
from subprocess import call
from platform import machine
ananace / FindMyGUI.cmake
Created Mar 27, 2012
Findmygui changes
View FindMyGUI.cmake
# - Find MyGUI includes and library
# This module defines
# MYGUI_LIBRARIES, the libraries to link against to use MYGUI.
# MYGUI_LIB_DIR, the location of the libraries
# MYGUI_FOUND, If false, do not try to use MYGUI
# Copyright © 2007, Matt Williams
ananace / Script
Last active Aug 29, 2015
LD31 Script Interface
View Script

LD31 Script interface documentation

Global properties


Color Colors::Black const
Color Colors::Blue const