Load [Aftermath] setttings from aftrmath.ini; use ChronoTankDuration in ChronoshiftDeploy
This commit is contained in:
@@ -18,6 +18,7 @@ namespace OpenRa.Game
|
||||
public static InfoLoader<ProjectileInfo> ProjectileInfo;
|
||||
public static InfoLoader<VoiceInfo> VoiceInfo;
|
||||
public static GeneralInfo General;
|
||||
public static AftermathInfo Aftermath;
|
||||
public static TechTree TechTree;
|
||||
public static Map Map;
|
||||
public static TileSet TileSet;
|
||||
@@ -46,6 +47,9 @@ namespace OpenRa.Game
|
||||
General = new GeneralInfo();
|
||||
FieldLoader.Load(General, AllRules.GetSection("General"));
|
||||
|
||||
Aftermath = new AftermathInfo();
|
||||
FieldLoader.Load(Aftermath, AllRules.GetSection("Aftermath"));
|
||||
|
||||
LoadCategories(
|
||||
"Building",
|
||||
"Defense",
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProductVersion>9.0.30729</ProductVersion>
|
||||
<ProductVersion>9.0.21022</ProductVersion>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<ProjectGuid>{0DFB103F-2962-400F-8C6D-E2C28CCBA633}</ProjectGuid>
|
||||
<OutputType>WinExe</OutputType>
|
||||
@@ -85,6 +85,7 @@
|
||||
<Compile Include="Effects\TeslaZap.cs" />
|
||||
<Compile Include="Exts.cs" />
|
||||
<Compile Include="GameRules\ActorInfo.cs" />
|
||||
<Compile Include="GameRules\AftermathInfo.cs" />
|
||||
<Compile Include="GameRules\GeneralInfo.cs" />
|
||||
<Compile Include="GameRules\TechTree.cs" />
|
||||
<Compile Include="GameRules\VoiceInfo.cs" />
|
||||
@@ -163,7 +164,9 @@
|
||||
<Compile Include="Traits\AttackTurreted.cs" />
|
||||
<Compile Include="Traits\AutoTarget.cs" />
|
||||
<Compile Include="Traits\Building.cs" />
|
||||
<Compile Include="Traits\Explodes.cs" /> <Compile Include="Traits\ChronoshiftDeploy.cs" /> <Compile Include="Traits\Harvester.cs" />
|
||||
<Compile Include="Traits\Explodes.cs" />
|
||||
<Compile Include="Traits\ChronoshiftDeploy.cs" />
|
||||
<Compile Include="Traits\Harvester.cs" />
|
||||
<Compile Include="Traits\Helicopter.cs" />
|
||||
<Compile Include="Traits\ProductionQueue.cs" />
|
||||
<Compile Include="Traits\RenderBuildingCharge.cs" />
|
||||
|
||||
@@ -6,8 +6,8 @@ namespace OpenRa.Game.Traits
|
||||
{
|
||||
public ChronoshiftDeploy(Actor self) { }
|
||||
bool chronoshiftActive = false; // Is the chronoshift engine active?
|
||||
const int chargeTime = 100; // How many frames between uses?
|
||||
int remainingChargeTime = 0;
|
||||
int remainingChargeTime = 0; // How long until we can chronoshift again?
|
||||
int chargeTime = (int)(Rules.Aftermath.ChronoTankDuration * 60 * 25); // How long between shifts?
|
||||
|
||||
public void Tick(Actor self)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user