Skip to content

Instantly share code, notes, and snippets.

Avatar

Peter petereichinger

View GitHub Profile
@petereichinger
petereichinger / Sprites-Emission.shader
Created Jul 7, 2016
Sprite shader with an emission map in the material
View Sprites-Emission.shader
Shader "Sprites/Diffuse Emit"
{
Properties
{
[PerRendererData] _MainTex ("Sprite Texture", 2D) = "white" {}
_EmissionTex ("Emission Texture", 2D) = "white"{}
_Color ("Tint", Color) = (1,1,1,1)
[MaterialToggle] PixelSnap ("Pixel snap", Float) = 0
}
@petereichinger
petereichinger / ShowUsages.cs
Last active May 22, 2016
Show Usages of MonoBehaviours
View ShowUsages.cs
using UnityEngine;
using UnityEditor;
using System.Collections.Generic;
using System;
/// <summary>
/// Add the 'Show Usages' menu item which lists all usages of a script in prefabs.
/// This is useful to check if a script is still used anywhere.
/// </summary>
@petereichinger
petereichinger / markdown-to-pdf.py
Last active Aug 29, 2015 — forked from Beyamor/markdown-to-pdf.py
markdown to pdf with additional packages
View markdown-to-pdf.py
import os, sys
markdown_name = sys.argv[1]
name = markdown_name.split(".")[0]
latex_name = name + ".tex"
os.system("pandoc -f markdown -t latex %s -o %s" % (markdown_name, latex_name))
with open(latex_name, "r") as latex_file:
latex_content = latex_file.read()
You can’t perform that action at this time.