Skip to content

Instantly share code, notes, and snippets.

View romgerman's full-sized avatar
🥔
botato

romgerman

🥔
botato
View GitHub Profile
@romgerman
romgerman / MonoBehaviourSingleton.cs
Created April 16, 2023 17:39 — forked from rickyah/MonoBehaviourSingleton.cs
MonoBehaviour Singleton
using System;
using UnityEngine;
/// <summary>
/// This is a generic Singleton implementation for Monobehaviours.
/// Create a derived class where the type T is the script you want to "Singletonize"
/// Upon loading it will call DontDestroyOnLoad on the gameobject where this script is contained
/// so it persists upon scene changes.
/// </summary>
/// <remarks>

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example