Skip to content

Instantly share code, notes, and snippets.

View kirillrybin's full-sized avatar

Kirill Rybin kirillrybin

  • Yaroslavl', Russia
  • 11:00 (UTC +03:00)
View GitHub Profile
@Romaleks360
Romaleks360 / SerializedDictionary.cs
Last active April 26, 2023 19:38
Serialized Dictionary for Unity
using System.Collections.Generic;
using UnityEngine;
namespace Utils
{
[System.Serializable]
public class SerializedDictionary<TKey, TValue> : Dictionary<TKey, TValue>, ISerializationCallbackReceiver
{
[SerializeField] List<Pair> _pairs;
@yasirkula
yasirkula / FontAssetSaveDisabler.cs
Created August 21, 2024 18:50
Prevent dynamic TMP_FontAssets from constantly showing up in your source control
using System;
using TMPro;
using TMPro.EditorUtilities;
using UnityEditor;
using UnityEngine;
[CustomEditor(typeof(TMP_FontAsset))]
public class FontAssetSaveDisabler : TMP_FontAssetEditor
{
private static bool FontAssetsLocked