namespace Zinnia.Rule
{
using UnityEngine;
///
/// Simplifies implementing s that only accept s.
///
public abstract class Vector2Rule : Rule
{
///
public override bool Accepts(object target)
{
if (ShouldAutoRejectDueToState())
{
return false;
}
Vector2? targetVector2 = target as Vector2?;
return targetVector2 != null && Accepts((Vector2)targetVector2);
}
///
/// Determines whether a is accepted.
///
/// The to check.
/// if is accepted, otherwise.
protected abstract bool Accepts(Vector2 targetVector2);
}
}