get rid of Sellable.Selling state

This commit is contained in:
Chris Forbes
2012-09-13 07:09:44 +12:00
parent c253e59c57
commit b0b0fac847
2 changed files with 1 additions and 9 deletions

View File

@@ -22,11 +22,9 @@ namespace OpenRA.Mods.RA
public class Sellable : IResolveOrder
{
[Sync] public bool Selling = false;
public void ResolveOrder(Actor self, Order order)
{
if (order.OrderString == "Sell" && !Selling)
if (order.OrderString == "Sell")
{
var capturing = self.TraitOrDefault<Capturable>();
if (capturing != null && capturing.CaptureInProgress)
@@ -35,8 +33,6 @@ namespace OpenRA.Mods.RA
if (!self.Trait<Building>().Lock())
return;
Selling = true;
foreach( var ns in self.TraitsImplementing<INotifySold>() )
ns.Selling( self );