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 Unity.Cinemachine; | |
using UnityEngine; | |
using UnityEngine.Splines; | |
[Serializable] | |
public class SmoothFollow : SplineAutoDolly.ISplineAutoDolly { | |
[Tooltip("Maximum speed of the dolly along the spline.")] | |
public float MaxSpeed = 0.5f; |
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 Cysharp.Threading.Tasks; | |
/// <summary> | |
/// Provides helper methods for working with UniTask, including methods to await multiple tasks | |
/// and capture their results or exceptions. | |
/// </summary> | |
public class UniTaskHelpers { | |
/// <summary> | |
/// Awaits two UniTasks and returns a tuple containing the results or exceptions for each task. |
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.Generic; | |
using UnityEditor; | |
using UnityEngine; | |
// Put this in an Editor folder | |
[InitializeOnLoad] | |
public class FixUnityBrokenSelectionBase : Editor { | |
static List<Object> newSelection; | |
static Object[] lastSelection = { }; |
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.Collections.Generic; | |
using System.IO; | |
using System.Threading.Tasks; | |
using UnityEditor; | |
using UnityEditor.PackageManager; | |
using UnityEditor.PackageManager.Requests; | |
using UnityEngine; | |
using static System.Environment; |
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 UnityUtils; | |
[RequireComponent(typeof(TriggerArea))] | |
public class GravityWell : MonoBehaviour { | |
TriggerArea triggerArea; | |
void Start() { | |
triggerArea = GetComponent<TriggerArea>(); | |
} |
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.Animations; | |
using UnityEngine.Playables; | |
using UnityEngine; | |
[Serializable] | |
public class AnimationConfig { | |
public Animator animator; | |
public AnimationClip idleClip; | |
public AnimationClip walkClip; |
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.Collections.Generic; | |
using UnityEngine; | |
using UnityEngine.Animations; | |
using UnityEngine.Playables; | |
using MEC; // Uses More Effective Coroutines from the Unity Asset Store | |
public class AnimationSystem { | |
PlayableGraph playableGraph; | |
readonly AnimationMixerPlayable topLevelMixer; |
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 UnityEditor; | |
using UnityEditor.Animations; | |
public static class AnimatorControllerCloneTool { | |
[MenuItem("Assets/Clone Animator Controller", true)] | |
static bool CanCloneAnimatorController() { | |
return Selection.activeObject is AnimatorController; | |
} | |
[MenuItem("Assets/Clone Animator Controller")] |
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.IO; | |
using Unity.Collections; | |
using Unity.Collections.LowLevel.Unsafe; | |
using Unity.Profiling; | |
using Unity.Profiling.Memory; | |
using UnityEngine; | |
public class MemorySnapshotter { | |
const string capturesFolder = "MemoryCaptures"; |
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 UnityEditorInternal; | |
using UnityEngine; | |
using UnityEditor; | |
using System; | |
using System.Collections.Generic; | |
/// <summary> | |
/// A Unity editor extension for copying and pasting all components between GameObjects. | |
/// The tool supports handling multiple components of the same type and correctly restores |
NewerOlder