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; | |
public sealed class BehaviorSubject<TValue> | |
{ | |
private TValue lastValue; | |
public Action<TValue> action = default; | |
public Action actionVoid = default; | |
public BehaviorSubject( TValue initValue = default ) | |
{ | |
lastValue = initValue; | |
} |
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; | |
using System.Linq; | |
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
using XavHelpTo; | |
using XavHelpTo.Get; | |
using XavHelpTo.Set; | |
using XavHelpTo.Know; |
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; | |
using UnityEngine; | |
using XavHelpTo.Set; | |
[Serializable] | |
public struct SmoothTransition | |
{ | |
#region Variables | |
public const float MIN_RANGE = .1f; | |
public const float MAX_RANGE = 10f; |
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
#if UNITY_EDITOR | |
using System.IO; | |
using UnityEditor; | |
using UnityEditor.PackageManager; | |
using UnityEditor.PackageManager.Requests; | |
public static class PackageCreator | |
{ | |
public static void CreateTgzPackage(string packagePath, string sourcePath) | |
{ | |
PackRequest packRequest = Client.Pack(sourcePath, packagePath); |
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
name: Generate UML | |
on: | |
push: | |
branches: | |
- master | |
workflow_dispatch: | |
jobs: | |
generate-uml: | |
name: 'Generate UML' |
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 "Custom/GradientWave2" { | |
Properties { | |
_MainTex ("Texture", 2D) = "white" {} | |
_ColorStart ("Start Color", Color) = (1, 1, 1, 1) | |
_ColorEnd ("End Color", Color) = (0, 0, 0, 1) | |
_Speed ("Speed", Range(0, 10)) = 1 | |
_WaveSpeedH ("Wave Speed Horizontal", Range(-10, 10)) = 0.5 | |
_WaveSpeedV ("Wave Speed Vertical", Range(-10, 10)) = 0.5 | |
_WaveAmountH ("Wave Amount Horizontal", Range(0, 1)) = 0.1 | |
_WaveAmountV ("Wave Amount Vertical", Range(0, 1)) = 0.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
Shader "Custom/UI Gradient" { | |
Properties { | |
_MainTex ("Texture", 2D) = "white" {} | |
_GradientDirection ("Gradient Direction", Range(0, 360)) = 0 | |
_Color1 ("Color 1", Color) = (1,1,1,1) | |
_Color2 ("Color 2", Color) = (0,0,0,1) | |
} | |
SubShader { | |
Tags { "Queue"="Transparent" "RenderType"="Transparent" } |
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
// c# companion script | |
// SpriteUVToShader.cs -------------------------------------------------------------------------------------------------------------------------------- // | |
// Save you your project, add to your SpriteRenderer gameObject | |
using UnityEngine; | |
using System.Collections; | |
using System.Collections.Generic; | |
[ExecuteInEditMode] |
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.Collections.Generic; | |
using UnityEngine; | |
using System.Threading.Tasks; | |
public static class AsyncExtensorUtils | |
{ | |
public static IEnumerator ToCoroutine(this Task _task) | |
{ | |
while (!_task.IsCompleted) yield return null; |
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.Collections.Generic; | |
using UnityEngine; | |
using System.Threading.Tasks; | |
public static class AsyncExtensorUtils | |
{ | |
public static IEnumerator ToCoroutine(this Task _task) | |
{ | |
while (!_task.IsCompleted) yield return null; |
OlderNewer