This repository has been archived on 2025-04-11. You can view files and clone it, but cannot push or open issues or pull requests.
angels-and-demons/Angels and Demons/Assets/Editor/MergeActionExistence.cs
2018-05-09 20:42:22 -05:00

23 lines
No EOL
781 B
C#

using UnityEngine;
using UnityEditor;
namespace GitMerge
{
/// <summary>
/// The abstract base MergeAction for all MergeActions that manage whether or not an object exists
/// </summary>
public abstract class MergeActionExistence : MergeAction
{
public MergeActionExistence(GameObject ours, GameObject theirs)
: base(ours, theirs)
{
ObjectDictionaries.AddToSchroedingersObjects(ours ?? theirs, this);
}
/// <summary>
/// Apply whatever version that has the object existing, since it might be needed somewhere.
/// When overriding, call either UseOurs or UseTheirs to make sure to trigger the side effects.
/// </summary>
public abstract void EnsureExistence();
}
}