This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- | |
Dark theme Visual Studio 2022 style syntax highlighter for Unity Shaderlab + jbooth's Better Shaders. | |
Derived from ShaderLab highlighter by redcool007: | |
https://github.com/notepad-plus-plus/userDefinedLanguages/blob/master/UDLs/ShadeLab_by-redcool007.xml | |
This is my first time making a N++ UDL; feel free to make suggestions for improvements. Will add attributes | |
and other keywords as I go. | |
--> | |
<NotepadPlus> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static class MathM | |
{ | |
public const float PI = (float)System.Math.PI; | |
public const float TwoPI = PI * 2; | |
public const float HalfPI = PI * 0.5f; | |
public static float Sin(float x) | |
{ | |
float x3 = x * x * x; | |
float x5 = x3 * x * x; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// gist by Roystan (IronWarrior): https://gist.github.com/IronWarrior/005f649e443bf51b656729231d0b8af4 | |
// Video demo: https://twitter.com/DavigoGame/status/1300842800964018178 | |
// | |
// CONTRIBUTIONS: | |
// Mac and Linux support added by Creature Coding: https://creaturecoding.com/ | |
// | |
// PURPOSE: | |
// Unity does not permit a project to be open in two different editor instances. | |
// This can be frustrating when building projects with multiplayer networking, | |
// as it would require you to create a build every time you wish you test your netcode. |