Use expression body syntax

This commit is contained in:
teinarss
2021-02-25 20:52:13 +01:00
committed by Paul Chote
parent 555c43843b
commit 4a1e4f3e16
403 changed files with 1342 additions and 2031 deletions

View File

@@ -116,7 +116,7 @@ namespace OpenRA.Mods.Common.Traits
protected DeveloperMode developerMode;
protected TechTree techTree;
public Actor Actor { get { return self; } }
public Actor Actor => self;
[Sync]
public bool Enabled { get; protected set; }
@@ -603,14 +603,9 @@ namespace OpenRA.Mods.Common.Traits
public int TotalTime { get; private set; }
public int RemainingTime { get; private set; }
public int RemainingCost { get; private set; }
public int RemainingTimeActual
{
get
{
return (pm == null || pm.PowerState == PowerState.Normal) ? RemainingTime :
RemainingTime * Queue.Info.LowPowerModifier / 100;
}
}
public int RemainingTimeActual =>
(pm == null || pm.PowerState == PowerState.Normal) ? RemainingTime :
RemainingTime * Queue.Info.LowPowerModifier / 100;
public bool Paused { get; private set; }
public bool Done { get; private set; }