Skip to content

Instantly share code, notes, and snippets.

Stijn Raaijmakers bugshake

Block or report user

Report or block bugshake

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
View Bush Shader Indirect Color.shader
Shader "Instanced/BushShader" {
_MainTex("Albedo (RGB)", 2D) = "white" {}
_Color0("Color0", Color) = (0,0,0,1)
_Color1("Color1", Color) = (1,1,1,1)
_Cutoff("Alpha cutoff", Range(0,1)) = 0.5
_FadeStart("Fade start", Float) = 10000.0
_FadeEnd("Fade end", Float) = 11000.0
_WaveAmount("Wave Amount", Float) = 0.1
_WaveSpeed("Wave Speed", Float) = 1.0
bugshake / SortedGizmos.cs
Created Sep 28, 2018
Depth sorted Gizmos in the Unity Editor
View SortedGizmos.cs
using System;
using System.Collections.Generic;
using UnityEngine;
public static class SortedGizmos
static List<ICommand> commands = new List<ICommand>(1000);
public static Color color { get; set; }
bugshake / Screenshotter.cs
Created Feb 21, 2018
Save a screenshot in any resolution from the Unity Editor. Useful for making screenshots higher than your monitor's resolution.
View Screenshotter.cs
using System;
using System.IO;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using UnityEngine;
using UnityEditor;
AUTHOR: Stijn Raaijmakers @bugshake
bugshake / ObservableProperty.cs
Created Oct 2, 2017
C# Observable Property
View ObservableProperty.cs
// get an event when a property changes
public class ObservableProperty<T>
T value;
public delegate void ChangeEvent(T data);
public event ChangeEvent changed;
public ObservableProperty(T initialValue)
bugshake / RigidbodyInspector.cs
Created Mar 3, 2017
Expose detectCollisions property in Rigidbody component
View RigidbodyInspector.cs
using UnityEngine;
using UnityEditor;
public class RigidBodyInspector : Editor
public override void OnInspectorGUI()
Rigidbody target = (Rigidbody);
if (DrawDefaultInspector())
bugshake / ReadableID
Created Feb 22, 2017
Translate a unique ID into something human readable/recognizable/discernable
View ReadableID
public static class ReadableID
static readonly string[] syllables = new string[256];
public static void initOnce()
string[] consonants = new string[] { "b", "br", "c", "ch", "d", "f", "fr", "g", "h", "j", "k", "kn", "l", "m", "n", "p", "pr", "qu", "r", "s", "st", "sl", "sc", "t", "tr", "v", "w", "x", "z" };
string[] vowels = new string[] { "a", "e", "i", "o", "u", "y", "ae", "ee", "ea", "ai" };
for (int i = 0; i < syllables.Length; ++i)
bugshake / MeshInspector.cs
Created Sep 11, 2016
Show mesh vertices and normals in sceneview [Unity3D]
View MeshInspector.cs
// author: Stijn Raaijmakers (@bugshake)
// date: 11 sep 2016
using UnityEngine;
using UnityEditor;
/// <summary>Add this component to any GameObject with a MeshFilter, then select it in the editor</summary>
public class MeshInspector : MonoBehaviour
You can’t perform that action at this time.