Convert weapons to world coords.

This commit is contained in:
Paul Chote
2013-12-24 23:10:05 +13:00
parent aca897fa76
commit ecdae4cbbe
13 changed files with 44 additions and 64 deletions

View File

@@ -31,9 +31,7 @@ namespace OpenRA.Mods.RA
if (arm == null)
return;
// TODO: Define weapon ranges as WRange
var range = new WRange((int)(1024*arm.Weapon.Range));
if (!target.IsInRange(self.CenterPosition, range))
if (!target.IsInRange(self.CenterPosition, arm.Weapon.Range))
return;
var facing = self.TraitOrDefault<IFacing>();