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
Shader "Atmosphere/Atmospheric Scattering" | |
{ | |
Properties | |
{ | |
_LightIntensity("Light Intensity", Float) = 30 | |
_LightColor("Light Color", Color) = (1,1,1) | |
_LightDirection("Light Direction", Vector) = (0,0,1) | |
_PlanetRadius("Planet Radius", Float) = 47 | |
_AtmosphereRadius("Atmosphere Radius", Float) = 50 | |
_Steps ("Steps", Int) = 20 |
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
// Source : https://www.twitch.tv/videos/519292916?filter=all&sort=time | |
#region Author | |
///////////////////////////////////////// | |
// RAPHAËL DAUMAS --> ICanRewind | |
// https://raphdaumas.wixsite.com/portfolio | |
// https://github.com/Marsgames | |
///////////////////////////////////////// | |
#endregion | |
public interface ICanRewind |
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
Shader "Unlit/SimpleInkPaint" | |
{ | |
Properties{ | |
_MainTex("MainTex", 2D) = "white" // メインテクスチャ | |
_Brush("Brush", 2D) = "white" // ブラシテクスチャ | |
_BrushScale("BrushScale", FLOAT) = 0.1 // ブラシサイズ | |
_ControlColor("ControlColor", VECTOR) = (0, 0, 0, 0) // ブラシの色 | |
_PaintUV("Hit UV Position", VECTOR) = (0, 0, 0, 0) // ブラシで塗りたい位置 | |
} |
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
// Upgrade NOTE: replaced '_World2Object' with 'unity_WorldToObject' | |
Shader "Custom/CrackedEarthShader" { | |
Properties { | |
_Color ("Color", Color) = (1,1,1,1) | |
_MainTex ("Albedo (RGB)", 2D) = "white" {} | |
_Glossiness ("Smoothness", Range(0,1)) = 0.5 | |
_Metallic ("Metallic", Range(0,1)) = 0.0 | |
_TriPlanarScale ("Triplanar Scale", Float) = 5 | |
_EmissionStrength ("Emission", Float) = 1 |
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
public interface ITimeControl | |
{ | |
void Initialize(); | |
void AdjustTimeScale(float timeScale); | |
} |
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
using UnityEngine; | |
using Vectrosity; | |
using System.Collections.Generic; | |
using UnityEngine.UI; | |
using System.IO; | |
using System.Collections; | |
using UnityEngine.SceneManagement; | |
public class DrawingView : MonoBehaviour { | |
public Text _Console; |
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
using System.Collections; | |
using System.Diagnostics; | |
using UnityEngine; | |
public enum TimeLayer { | |
//Unity's time | |
GameTime, | |
//Custom time layer for UI | |
MenuTime, | |
//Unity's unscaled time |
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
using System.IO; | |
using System; | |
using System.Text; | |
public class SimpleCSVDebug | |
{ | |
string GetPathFile() | |
{ | |
string path = Environment.GetFolderPath(Environment.SpecialFolder.Desktop); | |
string file = "output.csv"; |
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
//Enable this if you want it to work in NUNIT, see the test example at the bottom | |
//#define UNIT_TESTING | |
/** | |
* | |
* https://i.imgur.com/GoH9rkv.png | |
* | |
* One of the frustrating things about Unity is that there are a spate of magic methods that can be | |
* called from the runtime. They do not have an interface defined, which by itself is pretty frustrating, | |
* but it can allow some valid c# that is bad Unity mojo. Consider a private 'OnEnable' function unity |
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
using UnityEngine; | |
using System.Collections; | |
/// <summary> | |
/// A class for taking spectrum data & calculating the volume of various frequency bands. | |
/// | |
/// Notes: | |
/// This doesn't do any smoothing, so wherever you leverage these values you'll probably want to do something. | |
/// In my project I immediately jump to any higher value, and then have it decay over time at a fixed rate. | |
/// </summary> |
NewerOlder