Replace various Aircraft fields with FlightDynamics

Replaces various booleans with a FlightDynamics flag list.
This commit is contained in:
reaperrr
2019-06-14 10:36:54 +02:00
committed by abcdefg30
parent 824db72a4c
commit 0ebeb30880
8 changed files with 65 additions and 64 deletions

View File

@@ -75,7 +75,7 @@ namespace OpenRA.Mods.Common.Activities
if (dat < aircraft.Info.CruiseAltitude)
{
// If we're a VTOL, rise before flying forward
if (aircraft.Info.VTOL)
if (aircraft.Info.FlightDynamics.HasFlag(FlightDynamic.VTOL))
{
Fly.VerticalTakeOffOrLandTick(self, aircraft, aircraft.Facing, aircraft.Info.CruiseAltitude);
return false;
@@ -90,7 +90,7 @@ namespace OpenRA.Mods.Common.Activities
// Checking for NextActivity == null again in case another activity was queued while taking off
if (moveToRallyPoint && NextActivity == null)
{
if (!aircraft.Info.VTOL && assignTargetOnFirstRun)
if (!aircraft.Info.FlightDynamics.HasFlag(FlightDynamic.VTOL) && assignTargetOnFirstRun)
return true;
QueueChild(new AttackMoveActivity(self, () => move.MoveToTarget(self, target)));