Skip to content

Instantly share code, notes, and snippets.

View kiosion's full-sized avatar
🔮
Grokking the hypersphere

Maxim Dietz kiosion

🔮
Grokking the hypersphere
View GitHub Profile
@kiosion
kiosion / DoubleSidedCutoutSurfaceShader.shader
Created December 25, 2023 21:06
Simple 2-sided cutout surface shader for Unity with bumpmap support
Shader "Kio/DoubleSidedCutoutSurfaceShader"
{
Properties
{
_Color ("Color", Color) = (1,1,1,1)
_MainTex ("Albedo (RGB)", 2D) = "white" {}
_BumpMap ("Normal Map", 2D) = "bump" {}
_Glossiness ("Smoothness", Range(0,1)) = 0.5
_Metallic ("Metallic", Range(0,1)) = 0.0
_Cutoff ("Alpha Cutoff", Range(0,1)) = 0.5
@kiosion
kiosion / ArmatureAssignment.cs
Last active December 22, 2023 23:31
Unity script to reassign mesh weights to new armature
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using UnityEngine;
using UnityEditor;
public class ArmatureAssignment: EditorWindow
{
private int MeshCount = 1;
@kiosion
kiosion / grailed-modal-keyhandler.js
Last active May 6, 2023 03:12
Grailed modal keyhandler TamperMonkey userscript
// ==UserScript==
// @name Grailed Modal Keyhandler
// @namespace https://www.grailed.com/
// @version 0.1
// @description Handle keypresses in image modals like should be fucking done by default :)
// @author Kiosion
// @match https://www.grailed.com/*
// @icon https://www.google.com/s2/favicons?sz=64&domain=grailed.com
// @grant none
// ==/UserScript==
@kiosion
kiosion / MeshInfo.cs
Created April 12, 2023 23:39
Simple script for displaying mesh info for selection(s) containing MeshFilters / SkinnedMeshRenderers in Unity Editor
using UnityEngine;
using UnityEditor;
public class MeshInfo : EditorWindow {
private int vertexCount;
private int submeshCount;
private int totalTriangleCount;
private int triangleCount;
private int uvChannels;
private int blendShapesCount;
@kiosion
kiosion / intellij-bspwm-fix.md
Created September 13, 2021 07:42
Fix for IntelliJ grey-screen while running under bspwm

Here's how I fixed IntelliJ IDEA opening to a grey/null screen while running under bspwm or other tiling WM's. According to this section in bspwm's page on the Arch Wiki, it's an issue with the way some Java programs respond to tiling WM's. There are several fixes and pages listed there; below is what I found to work best, YMMV.

Install

  • jdk11-openjdk & wmname via pacman sudo pacman -S jdk11-openjdk wmname
  • Switch system to jdk11 (this fixed crashes I was getting with jdk16, might not be necessary) archlinux-java jdk11-openjdk

Config

@kiosion
kiosion / keybase.md
Created December 26, 2020 16:08
Keybase Proof

Keybase proof

I hereby claim:

  • I am kiosion on github.
  • I am kiosion (https://keybase.io/kiosion) on keybase.
  • I have a public key ASBjnQKJjnJzCkDlnP3u3u5xQdJkaOBbvD90Rfg460g_SQo

To claim this, I am signing this object: