Skip to content

Instantly share code, notes, and snippets.


Damien Mayance valryon

View GitHub Profile
View UnityShadersCheatSheet.shader
Shader "Name" {
Properties {
_Name ("display name", Range (min, max)) = number
_Name ("display name", Float) = number
_Name ("display name", Int) = number
_Name ("display name", Color) = (number,number,number,number)
_Name ("display name", Vector) = (number,number,number,number)
elisee /
Last active Jun 8, 2019
Setting up a great console on Windows

The default console on Windows has many limitations!

  • No tabs, no split screen support
  • File and folder autocomplete doesn't stop when an ambiguity is reached
  • It doesn't append slashes when completing folder names which makes writing paths unnecessarily cumbersome

Solution: ConsoleZ + Clink



Create an app with Automator that shows a notification and play a sound (available here).

Put it in your /Applications folder.


Type this in a shell:

View Sprite-Cutout.shader
Shader "Sprites/Cutout"
[PerRendererData] _MainTex ("Sprite Texture", 2D) = "white" {}
_Color ("Tint", Color) = (1,1,1,1)
[MaterialToggle] PixelSnap ("Pixel snap", Float) = 0
_Cutoff ("Shadow alpha cutoff", Range(0,1)) = 0.5
shawndumas / .gitconfig
Created Aug 5, 2013
Using WinMerge as the git Diff/Merge Tool on Windows 64bit
View .gitconfig
prompt = false
keepBackup = false
keepTemporaries = false
tool = winmerge
[mergetool "winmerge"]
name = WinMerge
# Set the save dialog to be in extended mode by default
defaults write NSGlobalDomain NSNavPanelExpandedStateForSaveMode -bool true
# Set the iCloud-using apps to not save to iCloud by default
# Courtesy of @room34,
defaults write NSGlobalDomain NSDocumentSaveNewDocumentsToCloud -bool false
# Open a new document in TextEdit (& other iCloud-backed app) directly
# instead of presenting the document picker.
defaults write -g NSShowAppCentricOpenPanelInsteadOfUntitledFile -bool false
flarb / AssetGPULoader.cs
Created Jul 22, 2012
Unity3d GPU Pre-loader
View AssetGPULoader.cs
using UnityEngine;
using System.Collections;
using System;
using System.Collections.Generic;
public class AssetGPULoader : MonoBehaviour {
public Camera activeCamera;
RenderTexture _rt;
jotto / google_oauth2_access_token.rb
Created Jun 14, 2012
ruby command line script for generating google oauth2 access token
View google_oauth2_access_token.rb
# (create oauth2 tokens from Google Console)
client_id = ""
client_secret = ""
# (paste the scope of the service you want here)
# e.g.:
scope = ""