This commit is contained in:
Chris Forbes
2009-12-28 14:25:36 +13:00
10 changed files with 97 additions and 98 deletions

View File

@@ -81,7 +81,7 @@ namespace OpenRa.Game.Traits.Activities
var nextCell = PopPath( self, mobile );
if( nextCell == null )
return NextActivity;
return this;
int2 dir = nextCell.Value - mobile.fromCell;
var firstFacing = Util.GetFacing( dir, unit.Facing );

View File

@@ -5,10 +5,10 @@ using OpenRa.Game.GameRules;
namespace OpenRa.Game.Traits
{
class Infantry : ICrushable
class SquishByTank : ICrushable
{
readonly Actor self;
public Infantry(Actor self)
public SquishByTank(Actor self)
{
this.self = self;
}
@@ -26,7 +26,6 @@ namespace OpenRa.Game.Traits
public bool IsCrushableBy(UnitMovementType umt, Player player)
{
if (player == Game.LocalPlayer) return false;
if (!(self.Info as InfantryInfo).Crushable) return false;
switch (umt)
{
case UnitMovementType.Track: return true;