Merge pull request #11120 from teees/fix-barrels
Fix barrel recoil being set immediately, not when actually firing
This commit is contained in:
@@ -233,14 +233,14 @@ namespace OpenRA.Mods.Common.Traits
|
|||||||
|
|
||||||
if (args.Weapon.Report != null && args.Weapon.Report.Any())
|
if (args.Weapon.Report != null && args.Weapon.Report.Any())
|
||||||
Game.Sound.Play(args.Weapon.Report.Random(self.World.SharedRandom), self.CenterPosition);
|
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)
|
if (--Burst > 0)
|
||||||
FireDelay = Weapon.BurstDelay;
|
FireDelay = Weapon.BurstDelay;
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user