Skip to content

Instantly share code, notes, and snippets.

View MattRix's full-sized avatar

Matt Rix MattRix

View GitHub Profile
@MattRix
MattRix / EditorCoroutineRunner.cs
Created April 18, 2017 19:24 — forked from LotteMakesStuff/EditorCoroutineRunner.cs
Run stuff in the editor with all the convenience of co-routines! Add a status UI super easily to see readouts what your long running code is actually doing! nice~ There is a short API demo at the top of the class. This is a prefect companion for my inspector buttons https://gist.github.com/LotteMakesStuff/dd785ff49b2a5048bb60333a6a125187
using UnityEngine;
using UnityEditor;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Reflection;
public class EditorCoroutineRunner
{
[MenuItem("Window/Lotte's Coroutine Runner: Demo")]
@MattRix
MattRix / InspectorButtonsTest.cs
Created April 18, 2017 19:23 — forked from LotteMakesStuff/InspectorButtonsTest.cs
Code running pack! two property drawing scripts that make it super easy to trigger code via buttons in the inspector, and get feedback! [TestButton] draws you little buttons that call a method on your MonoBehaviour, and [ProgressBar] give you a great way to show feedback from long running methods. These are *super* helpful for things like proced…
using UnityEngine;
using System.Collections;
public class InspectorButtonsTest : MonoBehaviour
{
[TestButton("Generate world", "DoProcGen", isActiveInEditor = false)]
[TestButton("Clear world", "ClearWorld", 2, isActiveInEditor = false)]
[ProgressBar(hideWhenZero = true, label = "procGenFeedback")]
public float procgenProgress = -1;
@MattRix
MattRix / readme.txt
Created May 15, 2014 23:14 — forked from anonymous/readme.txt
Cake Monsters!
Play this game by pasting the script in http://www.puzzlescript.net/editor.html
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
using System;
using System.Linq;
using System.Text;
using System.Reflection;