naming fixes
This commit is contained in:
@@ -75,7 +75,7 @@ namespace OpenRA
|
|||||||
|
|
||||||
case DamageModel.PerCell:
|
case DamageModel.PerCell:
|
||||||
{
|
{
|
||||||
foreach (var t in world.FindTilesInCircle(targetTile, warhead.SmudgeSize[0]))
|
foreach (var t in world.FindTilesInCircle(targetTile, warhead.Size[0]))
|
||||||
foreach (var unit in world.FindUnits(Game.CellSize * t, Game.CellSize * (t + new float2(1,1))))
|
foreach (var unit in world.FindUnits(Game.CellSize * t, Game.CellSize * (t + new float2(1,1))))
|
||||||
unit.InflictDamage(args.firedBy,
|
unit.InflictDamage(args.firedBy,
|
||||||
(int)(warhead.Damage * warhead.EffectivenessAgainst(
|
(int)(warhead.Damage * warhead.EffectivenessAgainst(
|
||||||
|
|||||||
@@ -34,13 +34,13 @@ namespace OpenRA.GameRules
|
|||||||
public readonly bool Ore = false; // can this damage ore?
|
public readonly bool Ore = false; // can this damage ore?
|
||||||
public readonly int Explosion = 0; // explosion effect to use
|
public readonly int Explosion = 0; // explosion effect to use
|
||||||
public readonly SmudgeType SmudgeType = SmudgeType.None; // type of smudge to apply
|
public readonly SmudgeType SmudgeType = SmudgeType.None; // type of smudge to apply
|
||||||
public readonly int[] SmudgeSize = { 0, 0 }; // bounds of the smudge. first value is the outer radius; second value is the inner radius.
|
public readonly int[] Size = { 0, 0 }; // size of the explosion. provide 2 values for a ring effect (outer/inner)
|
||||||
public readonly int InfDeath = 0; // infantry death animation to use
|
public readonly int InfDeath = 0; // infantry death animation to use
|
||||||
public readonly string ImpactSound = null; // sound to play on impact
|
public readonly string ImpactSound = null; // sound to play on impact
|
||||||
public readonly string WaterImpactSound = null; // sound to play on impact with water
|
public readonly string WaterImpactSound = null; // sound to play on impact with water
|
||||||
public readonly int Damage = 0; // how much (raw) damage to deal
|
public readonly int Damage = 0; // how much (raw) damage to deal
|
||||||
public readonly int Delay = 0; // delay in ticks before dealing the damage. 0=instant (old model)
|
public readonly int Delay = 0; // delay in ticks before dealing the damage. 0=instant (old model)
|
||||||
public readonly DamageModel DamageModel = DamageModel.Normal; //
|
public readonly DamageModel DamageModel = DamageModel.Normal; // which damage model to use
|
||||||
|
|
||||||
public float EffectivenessAgainst(ArmorType at) { return Verses[(int)at]; }
|
public float EffectivenessAgainst(ArmorType at) { return Verses[(int)at]; }
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -48,11 +48,11 @@ namespace OpenRA
|
|||||||
public static void AddSmudge(this Map map, int2 targetTile, WarheadInfo warhead)
|
public static void AddSmudge(this Map map, int2 targetTile, WarheadInfo warhead)
|
||||||
{
|
{
|
||||||
if (warhead.SmudgeType == SmudgeType.None) return;
|
if (warhead.SmudgeType == SmudgeType.None) return;
|
||||||
if (warhead.SmudgeSize[0] == 0 && warhead.SmudgeSize[1] == 0)
|
if (warhead.Size[0] == 0 && warhead.Size[1] == 0)
|
||||||
map.AddSmudge(warhead.SmudgeType == SmudgeType.Crater, targetTile.X, targetTile.Y);
|
map.AddSmudge(warhead.SmudgeType == SmudgeType.Crater, targetTile.X, targetTile.Y);
|
||||||
else
|
else
|
||||||
foreach (var t in Game.world.FindTilesInCircle(targetTile, warhead.SmudgeSize[0]))
|
foreach (var t in Game.world.FindTilesInCircle(targetTile, warhead.Size[0]))
|
||||||
if ((t - targetTile).LengthSquared >= warhead.SmudgeSize[1] * warhead.SmudgeSize[1])
|
if ((t - targetTile).LengthSquared >= warhead.Size[1] * warhead.Size[1])
|
||||||
if (Game.world.GetTerrainType(t) != TerrainType.Water)
|
if (Game.world.GetTerrainType(t) != TerrainType.Water)
|
||||||
map.AddSmudge(warhead.SmudgeType == SmudgeType.Crater, t.X, t.Y);
|
map.AddSmudge(warhead.SmudgeType == SmudgeType.Crater, t.X, t.Y);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -637,21 +637,11 @@ Atomic:
|
|||||||
Verses: 90%,100%,60%,25%,50%
|
Verses: 90%,100%,60%,25%,50%
|
||||||
Explosion: 6
|
Explosion: 6
|
||||||
InfDeath: 4
|
InfDeath: 4
|
||||||
Warhead@inner-nuke:
|
Warhead@areanuke:
|
||||||
DamageModel: PerCell
|
DamageModel: PerCell
|
||||||
Damage: 150
|
Damage: 250
|
||||||
SmudgeSize: 3,2
|
|
||||||
Wall: true
|
|
||||||
Wood: true
|
|
||||||
Ore: true
|
|
||||||
Verses: 90%,100%,60%,25%,50%
|
|
||||||
Delay: 3
|
|
||||||
InfDeath: 4
|
|
||||||
Warhead@outer-nuke:
|
|
||||||
DamageModel: PerCell
|
|
||||||
Damage: 150
|
|
||||||
SmudgeType: Scorch
|
SmudgeType: Scorch
|
||||||
SmudgeSize: 5,4
|
Size: 5,4
|
||||||
Wall: true
|
Wall: true
|
||||||
Wood: true
|
Wood: true
|
||||||
Ore: true
|
Ore: true
|
||||||
|
|||||||
Reference in New Issue
Block a user