Skip to content

Instantly share code, notes, and snippets.

View TheoSabattie's full-sized avatar
🏝️

Théo Sabattié TheoSabattie

🏝️
View GitHub Profile
@TheoSabattie
TheoSabattie / BehaviourButtonsEditor
Created November 16, 2016 08:05
Add editor buttons to your MonoBehaviours methods
using UnityEditor;
using UnityEngine;
namespace BitStrap
{
/// <summary>
/// Custom editor for all MonoBehaviour scripts in order to draw buttons for all button attributes (<see cref="ButtonAttribute"/>).
/// </summary>
[CustomEditor( typeof( MonoBehaviour ), true, isFallback = true )]
[CanEditMultipleObjects]