move counter-capture logic down into Capturable; remove spurious interlock on CaptureInProgress

This commit is contained in:
Chris Forbes
2012-09-13 07:14:56 +12:00
parent c012ea90dd
commit 0b665bc35b
2 changed files with 4 additions and 5 deletions

View File

@@ -40,7 +40,10 @@ namespace OpenRA.Mods.RA
public bool BeginCapture(Actor self, Actor captor)
{
if (!self.Trait<Building>().Lock())
if (!CaptureInProgress && !self.Trait<Building>().Lock())
return false;
if (CaptureInProgress && Captor.Owner.Stances[captor.Owner] == Stance.Ally)
return false;
CaptureProgressTime = 0;