Convert QuantizeFacing to WAngle facings.

This commit is contained in:
Paul Chote
2020-05-25 21:35:01 +01:00
committed by reaperrr
parent bfb6c671fb
commit c999b2d778
11 changed files with 34 additions and 34 deletions

View File

@@ -72,11 +72,11 @@ namespace OpenRA.Mods.Common.Activities
// Turn to one of the harvestable facings
if (harvInfo.HarvestFacings != 0)
{
var current = facing.Facing;
var current = WAngle.FromFacing(facing.Facing);
var desired = body.QuantizeFacing(current, harvInfo.HarvestFacings);
if (desired != current)
{
QueueChild(new Turn(self, desired));
QueueChild(new Turn(self, desired.Facing));
return false;
}
}