Merge pull request #11120 from teees/fix-barrels

Fix barrel recoil being set immediately, not when actually firing
This commit is contained in:
Matthias Mailänder
2016-04-17 09:52:06 +02:00

View File

@@ -233,14 +233,14 @@ namespace OpenRA.Mods.Common.Traits
if (args.Weapon.Report != null && args.Weapon.Report.Any())
Game.Sound.Play(args.Weapon.Report.Random(self.World.SharedRandom), self.CenterPosition);
foreach (var na in self.TraitsImplementing<INotifyAttack>())
na.Attacking(self, target, this, barrel);
Recoil = Info.Recoil;
}
});
foreach (var na in self.TraitsImplementing<INotifyAttack>())
na.Attacking(self, target, this, barrel);
Recoil = Info.Recoil;
if (--Burst > 0)
FireDelay = Weapon.BurstDelay;
else