unity-atoms/Packages/Core/Runtime/Variables/GameObjectVariable.cs
2019-10-02 17:36:20 +02:00

16 lines
557 B
C#

using System;
using UnityEngine;
namespace UnityAtoms
{
[UseIcon("atom-icon-lush")]
[CreateAssetMenu(menuName = "Unity Atoms/Variables/GameObject", fileName = "GameObjectVariable")]
public sealed class GameObjectVariable : AtomVariable<GameObject, GameObjectEvent, GameObjectGameObjectEvent>
{
protected override bool AreEqual(GameObject first, GameObject second)
{
return (first == null && second == null) || first != null && second != null && first.GetInstanceID() == second.GetInstanceID();
}
}
}