using MultiversalDiplomacy.Model;
namespace MultiversalDiplomacy.Orders;
///
/// An order for a unit to move to another province.
///
public class MoveOrder : UnitOrder
{
///
/// The destination season to which the unit should move.
///
public Season Season { get; }
///
/// The destination location to which the unit should move.
///
public Location Location { get; }
public MoveOrder(Power power, Unit unit, Season season, Location location)
: base (power, unit)
{
this.Season = season;
this.Location = location;
}
public bool IsOpposing(MoveOrder other)
=> this.Season == other.Unit.Season
&& other.Season == this.Unit.Season
&& this.Location.Province == other.Unit.Location.Province
&& other.Location.Province == this.Unit.Location.Province;
}