Skip to content

Instantly share code, notes, and snippets.

@Marsgames
Marsgames / GameManager.cs
Last active September 2, 2020 07:48
Exemple of static Instance for a GameManager, SoundManager, etc... in Unity + GameManager version ready for ads
#region Author
/////////////////////////////////////////
// RAPHAËL DAUMAS --> GameManager
// https://raphdaumas.wixsite.com/portfolio
// https://github.com/Marsgames
/////////////////////////////////////////
#endregion
using UnityEngine;
[HelpURL("https://gist.github.com/Marsgames/f5808a289f2ee135ac08930937787c68")]
@Marsgames
Marsgames / csc.rsp
Created November 28, 2019 17:06
Warnings as error for Unity (Just download this file and put it in your Assets folder)
-warnaserror+
@Marsgames
Marsgames / 01_Snippets_Unity.md
Last active December 25, 2024 20:15
Some useful functions snippet for Unity

Useful Unity snippets

A simple lerp from x value to y value in z seconds.

A function that allow a 2D GameObject to look at another GameObject, rotating only around Z axis.

A class (only 1 function is really important) that allow you to move a GameObject describing a simple Bezier curve (Only one tangent point).

@Marsgames
Marsgames / 1-Scripting__MonoBehaviour Script-NewMonoBehaviourScript.cs
Last active December 25, 2024 23:38
This is my own version of Unity MonoBehavior script Template
#region Author
/////////////////////////////////////////
// RAPHAEL DAUMAS --> #SCRIPTNAME#
// https://headcrab.fr
// https://github.com/Marsgames
/////////////////////////////////////////
#endregion
using UnityEngine;
public sealed class #SCRIPTNAME# : BaseEntity