Skip to content

Instantly share code, notes, and snippets.

View PhantasmicDev's full-sized avatar

Phantasmic Dev PhantasmicDev

View GitHub Profile
@PhantasmicDev
PhantasmicDev / BuildTargetGroupingGUI.cs
Created March 12, 2023 04:27
A wrapper for EditorGUILayout.BeginBuildTargetSelectionGrouping that allows excluding specified build target platform tabs. It also allows you to display tabs of platforms that are currently not installed.
using System;
using System.Collections;
using System.Linq;
using System.Reflection;
using UnityEditor;
using UnityEditor.Build;
using UnityEngine;
using UnityEngine.Pool;
namespace PhantasmicGames.PlayerLauncherEditor
@PhantasmicDev
PhantasmicDev / PrefabOnlyAttribute.cs
Created November 9, 2021 02:02
An attribute that allows referencing only prefabs in the editor
using UnityEngine;
using System;
#if UNITY_EDITOR
using UnityEditor;
#endif
[AttributeUsage(AttributeTargets.Field)]
public class PrefabOnlyAttribute : PropertyAttribute
{