Remove AftermathInfo and move some Rules.GeneralInfo settings onto traits

This commit is contained in:
Paul Chote
2010-02-07 14:15:05 +13:00
parent 31881edade
commit 2e97f3d308
10 changed files with 66 additions and 56 deletions

View File

@@ -1,14 +0,0 @@

namespace OpenRa.GameRules
{
public class AftermathInfo
{
public readonly int MTankDistance = 0;
public readonly float QuakeUnitDamage = 0f;
public readonly float QuakeBuildingDamage = 0f;
public readonly float QuakeInfantryDamage = 0f;
public readonly int QuakeDelay = 0;
public readonly int CarrierLaunchDelay = 0;
public readonly int ChronoTankDuration = 0;
}
}

View File

@@ -4,19 +4,6 @@ namespace OpenRa.GameRules
{
public class GeneralInfo
{
/* Crates */
public readonly int CrateMinimum = 0;
public readonly int CrateMaximum = 0;
public readonly float CrateRadius = 0;
public readonly float CrateRegen = 0;
public readonly string UnitCrateType = null; /* =none, if any */
public readonly float WaterCrateChance = 0;
public readonly int SoloCrateMoney = 2000;
public readonly string SilverCrate = null; /* solo play crate contents */
public readonly string WaterCrate = null;
public readonly string WoodCrate = null;
/* Special Weapons */
public readonly float GapRegenInterval =0;
public readonly int BadgerBombCount = 1;
@@ -40,9 +27,6 @@ namespace OpenRa.GameRules
/* Combat & Damage */
public readonly float TurboBoost = 1.5f;
public readonly int APMineDamage = 0;
public readonly int AVMineDamage = 0;
public readonly int AtomDamage = 0;
public readonly float BallisticScatter = 0;
public readonly float C4Delay = 0;
public readonly float ExpSpread = 0;
@@ -58,7 +42,6 @@ namespace OpenRa.GameRules
public readonly int Incoming = 0;
/* Income & Production */
public readonly int BailCount = 0;
public readonly float BuildSpeed = 0;
public readonly float BuildupTime = 0;
public readonly int GemValue = 0;

View File

@@ -16,7 +16,6 @@ namespace OpenRa
public static InfoLoader<ProjectileInfo> ProjectileInfo;
public static InfoLoader<VoiceInfo> VoiceInfo;
public static GeneralInfo General;
public static AftermathInfo Aftermath;
public static TechTree TechTree;
public static Dictionary<string, ActorInfo> Info;
@@ -30,11 +29,6 @@ namespace OpenRa
General = new GeneralInfo();
FieldLoader.Load(General, AllRules.GetSection("General"));
// dirty hack. all of this needs to either die or go to traitinfos
Aftermath = new AftermathInfo();
if (AllRules.GetSection("Aftermath", true).Count() > 0)
FieldLoader.Load(Aftermath, AllRules.GetSection("Aftermath"));
LoadCategories(
"Weapon",
"Warhead",

View File

@@ -5,7 +5,6 @@ namespace OpenRa.GameRules
{
// Debug settings
public readonly bool UnitDebug = false;
public readonly bool BuildingDebug = false;
public readonly bool PathDebug = false;
public readonly bool PerfGraph = true;
@@ -19,7 +18,6 @@ namespace OpenRa.GameRules
public readonly int SheetSize = 512;
// External game settings
public readonly bool UseAftermath = false;
public readonly string NetworkHost = "";
public readonly int NetworkPort = 0;
public readonly string Map = "scm12ea.ini";
@@ -29,6 +27,7 @@ namespace OpenRa.GameRules
public readonly string[] InitialMods = { "ra" };
// Gameplay options
// TODO: These need to die
public readonly bool RepairRequiresConyard = true;
public readonly bool PowerDownBuildings = true;
}