Remove deprecated Order.TargetActor and Target.FromOrder.
This commit is contained in:
@@ -50,11 +50,6 @@ namespace OpenRA
|
||||
public bool SuppressVisualFeedback;
|
||||
public Target VisualFeedbackTarget;
|
||||
|
||||
/// <summary>
|
||||
/// DEPRECATED: Use Target instead.
|
||||
/// </summary>
|
||||
public Actor TargetActor { get { return Target.SerializableActor; } }
|
||||
|
||||
/// <summary>
|
||||
/// DEPRECATED: Use Target instead.
|
||||
/// </summary>
|
||||
@@ -326,7 +321,7 @@ namespace OpenRA
|
||||
{
|
||||
return ("OrderString: \"{0}\" \n\t Subject: \"{1}\". \n\t TargetActor: \"{2}\" \n\t TargetLocation: {3}." +
|
||||
"\n\t TargetString: \"{4}\".\n\t IsImmediate: {5}.\n\t Player(PlayerName): {6}\n").F(
|
||||
OrderString, Subject, TargetActor != null ? TargetActor.Info.Name : null, TargetLocation,
|
||||
OrderString, Subject, Target.Type == TargetType.Actor ? Target.Actor.Info.Name : null, TargetLocation,
|
||||
TargetString, IsImmediate, Player != null ? Player.PlayerName : null);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -41,17 +41,6 @@ namespace OpenRA.Traits
|
||||
};
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// DEPRECATED: Use Order.Target instead.
|
||||
/// This method is kept to maintain compatibility with legacy code that may not understand TargetType.FrozenActor.
|
||||
/// </summary>
|
||||
public static Target FromOrder(World w, Order o)
|
||||
{
|
||||
return o.TargetActor != null
|
||||
? FromActor(o.TargetActor)
|
||||
: FromCell(w, o.TargetLocation);
|
||||
}
|
||||
|
||||
public static Target FromActor(Actor a)
|
||||
{
|
||||
if (a == null)
|
||||
|
||||
Reference in New Issue
Block a user