diff --git a/OpenRA.Game/GameRules/WeaponInfo.cs b/OpenRA.Game/GameRules/WeaponInfo.cs index 82d2193fb1..0c33926e05 100644 --- a/OpenRA.Game/GameRules/WeaponInfo.cs +++ b/OpenRA.Game/GameRules/WeaponInfo.cs @@ -46,8 +46,6 @@ namespace OpenRA.GameRules public readonly bool Charges = false; - public readonly string Palette = "effect"; - [Desc("What types of targets are affected.")] public readonly string[] ValidTargets = { "Ground", "Water" }; diff --git a/OpenRA.Game/Traits/TraitsInterfaces.cs b/OpenRA.Game/Traits/TraitsInterfaces.cs index 0ed83fa185..a4e5561ee5 100644 --- a/OpenRA.Game/Traits/TraitsInterfaces.cs +++ b/OpenRA.Game/Traits/TraitsInterfaces.cs @@ -270,7 +270,7 @@ namespace OpenRA.Traits public interface INotifyBecomingIdle { void OnBecomingIdle(Actor self); } public interface INotifyIdle { void TickIdle(Actor self); } - public interface IBlocksBullets { } + public interface IBlocksProjectiles { } public interface IRenderInfantrySequenceModifier { bool IsModifyingSequence { get; } diff --git a/OpenRA.Mods.Common/Effects/Bullet.cs b/OpenRA.Mods.Common/Effects/Bullet.cs index 0583af7ea3..a24da27985 100644 --- a/OpenRA.Mods.Common/Effects/Bullet.cs +++ b/OpenRA.Mods.Common/Effects/Bullet.cs @@ -22,18 +22,22 @@ namespace OpenRA.Mods.Common.Effects { public class BulletInfo : IProjectileInfo { - [Desc("Projectile speed in WRange / tick, two values indicate variable velocity")] + [Desc("Projectile speed in WRange / tick, two values indicate variable velocity.")] public readonly WRange[] Speed = { new WRange(17) }; - public readonly string Trail = null; - [Desc("Maximum offset at the maximum range")] + [Desc("Maximum offset at the maximum range.")] public readonly WRange Inaccuracy = WRange.Zero; public readonly string Image = null; - [Desc("Check for whether an actor with BlocksBullets: trait blocks fire")] - public readonly bool High = false; + public readonly string Palette = "effect"; public readonly bool Shadow = false; + [Desc("Trail animation.")] + public readonly string Trail = null; + [Desc("Is this blocked by actors with BlocksProjectiles trait.")] + public readonly bool Blockable = true; [Desc("Arc in WAngles, two values indicate variable arc.")] public readonly WAngle[] Angle = { WAngle.Zero }; + [Desc("Interval in ticks between each spawned Trail animation.")] public readonly int TrailInterval = 2; + [Desc("Delay in ticks until trail animaion is spawned.")] public readonly int TrailDelay = 1; public readonly int ContrailLength = 0; public readonly Color ContrailColor = Color.White; @@ -47,11 +51,11 @@ namespace OpenRA.Mods.Common.Effects { readonly BulletInfo info; readonly ProjectileArgs args; + readonly Animation anim; [Sync] readonly WAngle angle; [Sync] readonly WRange speed; - ContrailRenderable trail; - Animation anim; + ContrailRenderable contrail; [Sync] WPos pos, target; [Sync] int length; @@ -68,16 +72,15 @@ namespace OpenRA.Mods.Common.Effects var world = args.SourceActor.World; - if (info.Angle.Length > 1 && info.Speed.Length > 1) - { + if (info.Angle.Length > 1) angle = new WAngle(world.SharedRandom.Next(info.Angle[0].Angle, info.Angle[1].Angle)); - speed = new WRange(world.SharedRandom.Next(info.Speed[0].Range, info.Speed[1].Range)); - } else - { angle = info.Angle[0]; + + if (info.Speed.Length > 1) + speed = new WRange(world.SharedRandom.Next(info.Speed[0].Range, info.Speed[1].Range)); + else speed = info.Speed[0]; - } target = args.PassiveTarget; if (info.Inaccuracy.Range > 0) @@ -99,7 +102,7 @@ namespace OpenRA.Mods.Common.Effects if (info.ContrailLength > 0) { var color = info.ContrailUsePlayerColor ? ContrailRenderable.ChooseColor(args.SourceActor) : info.ContrailColor; - trail = new ContrailRenderable(world, color, info.ContrailLength, info.ContrailDelay, 0); + contrail = new ContrailRenderable(world, color, info.ContrailLength, info.ContrailDelay, 0); } smokeTicks = info.TrailDelay; @@ -133,17 +136,17 @@ namespace OpenRA.Mods.Common.Effects } if (info.ContrailLength > 0) - trail.Update(pos); + contrail.Update(pos); - if (ticks++ >= length || (!info.High && world.ActorMap - .GetUnitsAt(world.Map.CellContaining(pos)).Any(a => a.HasTrait()))) + if (ticks++ >= length || (info.Blockable && world.ActorMap + .GetUnitsAt(world.Map.CellContaining(pos)).Any(a => a.HasTrait()))) Explode(world); } public IEnumerable Render(WorldRenderer wr) { if (info.ContrailLength > 0) - yield return trail; + yield return contrail; if (anim == null || ticks >= length) yield break; @@ -158,7 +161,7 @@ namespace OpenRA.Mods.Common.Effects yield return r; } - var palette = wr.Palette(args.Weapon.Palette); + var palette = wr.Palette(info.Palette); foreach (var r in anim.Render(pos, palette)) yield return r; } @@ -167,7 +170,7 @@ namespace OpenRA.Mods.Common.Effects void Explode(World world) { if (info.ContrailLength > 0) - world.AddFrameEndTask(w => w.Add(new ContrailFader(pos, trail))); + world.AddFrameEndTask(w => w.Add(new ContrailFader(pos, contrail))); world.AddFrameEndTask(w => w.Remove(this)); diff --git a/OpenRA.Mods.Common/Effects/Explosion.cs b/OpenRA.Mods.Common/Effects/Explosion.cs index 93451480ce..4024ec6285 100644 --- a/OpenRA.Mods.Common/Effects/Explosion.cs +++ b/OpenRA.Mods.Common/Effects/Explosion.cs @@ -16,11 +16,11 @@ namespace OpenRA.Mods.Common.Effects { public class Explosion : IEffect { - World world; + readonly World world; + readonly string palette; + readonly Animation anim; WPos pos; CPos cell; - string palette; - Animation anim; public Explosion(World world, WPos pos, string sequence, string palette) { diff --git a/OpenRA.Mods.Common/Effects/GravityBomb.cs b/OpenRA.Mods.Common/Effects/GravityBomb.cs index fc61189bd6..0ad7c35ca6 100644 --- a/OpenRA.Mods.Common/Effects/GravityBomb.cs +++ b/OpenRA.Mods.Common/Effects/GravityBomb.cs @@ -19,8 +19,10 @@ namespace OpenRA.Mods.Common.Effects public class GravityBombInfo : IProjectileInfo { public readonly string Image = null; + public readonly string Palette = "effect"; public readonly bool Shadow = false; public readonly WRange Velocity = WRange.Zero; + [Desc("Value added to velocity every tick.")] public readonly WRange Acceleration = new WRange(15); public IEffect Create(ProjectileArgs args) { return new GravityBomb(this, args); } @@ -28,11 +30,12 @@ namespace OpenRA.Mods.Common.Effects public class GravityBomb : IEffect { - GravityBombInfo info; - Animation anim; - ProjectileArgs args; - WVec velocity; - WPos pos; + readonly GravityBombInfo info; + readonly Animation anim; + readonly ProjectileArgs args; + [Sync] WVec velocity; + [Sync] WPos pos; + [Sync] WVec acceleration; public GravityBomb(GravityBombInfo info, ProjectileArgs args) { @@ -40,6 +43,7 @@ namespace OpenRA.Mods.Common.Effects this.args = args; pos = args.Source; velocity = new WVec(WRange.Zero, WRange.Zero, -info.Velocity); + acceleration = new WVec(WRange.Zero, WRange.Zero, info.Acceleration); anim = new Animation(args.SourceActor.World, info.Image); if (anim.HasSequence("open")) @@ -50,7 +54,7 @@ namespace OpenRA.Mods.Common.Effects public void Tick(World world) { - velocity -= new WVec(WRange.Zero, WRange.Zero, info.Acceleration); + velocity -= acceleration; pos += velocity; if (pos.Z <= args.PassiveTarget.Z) @@ -60,7 +64,8 @@ namespace OpenRA.Mods.Common.Effects args.Weapon.Impact(Target.FromPos(pos), args.SourceActor, args.DamageModifiers); } - anim.Tick(); + if (anim != null) + anim.Tick(); } public IEnumerable Render(WorldRenderer wr) @@ -75,7 +80,7 @@ namespace OpenRA.Mods.Common.Effects yield return r; } - var palette = wr.Palette(args.Weapon.Palette); + var palette = wr.Palette(info.Palette); foreach (var r in anim.Render(pos, palette)) yield return r; } diff --git a/OpenRA.Mods.Common/Effects/LaserZap.cs b/OpenRA.Mods.Common/Effects/LaserZap.cs index 8b30d2a6e3..5068c686a9 100644 --- a/OpenRA.Mods.Common/Effects/LaserZap.cs +++ b/OpenRA.Mods.Common/Effects/LaserZap.cs @@ -39,13 +39,13 @@ namespace OpenRA.Mods.Common.Effects class LaserZap : IEffect { - ProjectileArgs args; - LaserZapInfo info; + readonly ProjectileArgs args; + readonly LaserZapInfo info; + readonly Animation hitanim; int ticks = 0; Color color; bool doneDamage; bool animationComplete; - Animation hitanim; WPos target; public LaserZap(ProjectileArgs args, LaserZapInfo info, Color color) diff --git a/OpenRA.Mods.Common/Effects/Missile.cs b/OpenRA.Mods.Common/Effects/Missile.cs index c41205baac..c72059dd42 100644 --- a/OpenRA.Mods.Common/Effects/Missile.cs +++ b/OpenRA.Mods.Common/Effects/Missile.cs @@ -22,32 +22,34 @@ namespace OpenRA.Mods.Common.Effects { class MissileInfo : IProjectileInfo { + public readonly string Image = null; + public readonly string Palette = "effect"; + public readonly bool Shadow = false; [Desc("Projectile speed in WRange / tick")] public readonly WRange Speed = new WRange(8); [Desc("Maximum vertical pitch when changing altitude.")] public readonly WAngle MaximumPitch = WAngle.FromDegrees(30); [Desc("How many ticks before this missile is armed and can explode.")] public readonly int Arm = 0; - [Desc("Check for whether an actor with BlocksBullets: trait blocks fire")] - public readonly bool High = false; - public readonly bool Shadow = false; - public readonly string Trail = null; + [Desc("Is the missile blocked by actors with BlocksProjectiles: trait.")] + public readonly bool Blockable = true; [Desc("Maximum offset at the maximum range")] public readonly WRange Inaccuracy = WRange.Zero; [Desc("Probability of locking onto and following target.")] public readonly int LockOnProbability = 100; - public readonly string Image = null; - [Desc("Rate of Turning")] - public readonly int ROT = 5; - [Desc("Explode when following the target longer than this.")] + [Desc("In n/256 per tick.")] + public readonly int RateOfTurn = 5; + [Desc("Explode when following the target longer than this many ticks.")] public readonly int RangeLimit = 0; - [Desc("If fired at aircraft, increase speed by 50%.")] - public readonly bool TurboBoost = false; + [Desc("Trail animation.")] + public readonly string Trail = null; + [Desc("Interval in ticks between each spawned Trail animation.")] public readonly int TrailInterval = 2; public readonly int ContrailLength = 0; public readonly Color ContrailColor = Color.White; public readonly bool ContrailUsePlayerColor = false; public readonly int ContrailDelay = 1; + [Desc("Should missile targeting be thrown off by nearby actors with JamsMissiles.")] public readonly bool Jammable = true; [Desc("Explodes when leaving the following terrain type, e.g., Water for torpedoes.")] public readonly string BoundToTerrainType = ""; @@ -66,7 +68,7 @@ namespace OpenRA.Mods.Common.Effects readonly Animation anim; int ticksToNextSmoke; - ContrailRenderable trail; + ContrailRenderable contrail; [Sync] WPos pos; [Sync] int facing; @@ -110,7 +112,7 @@ namespace OpenRA.Mods.Common.Effects if (info.ContrailLength > 0) { var color = info.ContrailUsePlayerColor ? ContrailRenderable.ChooseColor(args.SourceActor) : info.ContrailColor; - trail = new ContrailRenderable(world, color, info.ContrailLength, info.ContrailDelay, 0); + contrail = new ContrailRenderable(world, color, info.ContrailLength, info.ContrailDelay, 0); } } @@ -128,7 +130,8 @@ namespace OpenRA.Mods.Common.Effects public void Tick(World world) { ticks++; - anim.Tick(); + if (anim != null) + anim.Tick(); // Missile tracks target if (args.GuidedTarget.IsValidFor(args.SourceActor) && lockOn) @@ -147,10 +150,8 @@ namespace OpenRA.Mods.Common.Effects else if (!args.GuidedTarget.IsValidFor(args.SourceActor)) desiredFacing = facing; - facing = OpenRA.Traits.Util.TickFacing(facing, desiredFacing, info.ROT); + facing = OpenRA.Traits.Util.TickFacing(facing, desiredFacing, info.RateOfTurn); var move = new WVec(0, -1024, 0).Rotate(WRot.FromFacing(facing)) * info.Speed.Range / 1024; - if (targetPosition.Z > 0 && info.TurboBoost) - move = (move * 3) / 2; if (pos.Z != desiredAltitude) { @@ -168,14 +169,14 @@ namespace OpenRA.Mods.Common.Effects } if (info.ContrailLength > 0) - trail.Update(pos); + contrail.Update(pos); var cell = world.Map.CellContaining(pos); var shouldExplode = (pos.Z < 0) // Hit the ground || (dist.LengthSquared < info.CloseEnough.Range * info.CloseEnough.Range) // Within range || (info.RangeLimit != 0 && ticks > info.RangeLimit) // Ran out of fuel - || (!info.High && world.ActorMap.GetUnitsAt(cell).Any(a => a.HasTrait())) // Hit a wall + || (info.Blockable && world.ActorMap.GetUnitsAt(cell).Any(a => a.HasTrait())) // Hit a wall or other blocking obstacle || !world.Map.Contains(cell) // This also avoids an IndexOutOfRangeException in GetTerrainInfo below. || (!string.IsNullOrEmpty(info.BoundToTerrainType) && world.Map.GetTerrainInfo(cell).Type != info.BoundToTerrainType); // Hit incompatible terrain @@ -186,7 +187,7 @@ namespace OpenRA.Mods.Common.Effects void Explode(World world) { if (info.ContrailLength > 0) - world.AddFrameEndTask(w => w.Add(new ContrailFader(pos, trail))); + world.AddFrameEndTask(w => w.Add(new ContrailFader(pos, contrail))); world.AddFrameEndTask(w => w.Remove(this)); @@ -200,7 +201,7 @@ namespace OpenRA.Mods.Common.Effects public IEnumerable Render(WorldRenderer wr) { if (info.ContrailLength > 0) - yield return trail; + yield return contrail; if (!args.SourceActor.World.FogObscures(wr.World.Map.CellContaining(pos))) { @@ -211,7 +212,7 @@ namespace OpenRA.Mods.Common.Effects yield return r; } - var palette = wr.Palette(args.Weapon.Palette); + var palette = wr.Palette(info.Palette); foreach (var r in anim.Render(pos, palette)) yield return r; } diff --git a/OpenRA.Mods.Common/OpenRA.Mods.Common.csproj b/OpenRA.Mods.Common/OpenRA.Mods.Common.csproj index 260fe44cbd..10be6c4b9a 100644 --- a/OpenRA.Mods.Common/OpenRA.Mods.Common.csproj +++ b/OpenRA.Mods.Common/OpenRA.Mods.Common.csproj @@ -246,7 +246,7 @@ - + diff --git a/OpenRA.Mods.Common/Traits/BlocksBullets.cs b/OpenRA.Mods.Common/Traits/BlocksProjectiles.cs similarity index 71% rename from OpenRA.Mods.Common/Traits/BlocksBullets.cs rename to OpenRA.Mods.Common/Traits/BlocksProjectiles.cs index 113dbcf31b..e93add1764 100644 --- a/OpenRA.Mods.Common/Traits/BlocksBullets.cs +++ b/OpenRA.Mods.Common/Traits/BlocksProjectiles.cs @@ -14,7 +14,7 @@ using OpenRA.Traits; namespace OpenRA.Mods.Common.Traits { // TODO: Add functionality like a customizable Height that is compared to projectile altitude - [Desc("This actor blocks bullets and missiles without 'High' property.")] - public class BlocksBulletsInfo : TraitInfo { } - public class BlocksBullets : IBlocksBullets { } + [Desc("This actor blocks bullets and missiles with 'Blockable' property.")] + public class BlocksProjectilesInfo : TraitInfo { } + public class BlocksProjectiles : IBlocksProjectiles { } } diff --git a/OpenRA.Mods.Common/UtilityCommands/UpgradeRules.cs b/OpenRA.Mods.Common/UtilityCommands/UpgradeRules.cs index 7cd4a1b2ec..9cdd1e0974 100644 --- a/OpenRA.Mods.Common/UtilityCommands/UpgradeRules.cs +++ b/OpenRA.Mods.Common/UtilityCommands/UpgradeRules.cs @@ -829,6 +829,13 @@ namespace OpenRA.Mods.Common.UtilityCommands node.Key = "AmmoPool"; } + if (engineVersion < 20150326) + { + // Rename BlocksBullets to BlocksProjectiles + if (node.Key == "BlocksBullets") + node.Key = "BlocksProjectiles"; + } + UpgradeActorRules(engineVersion, ref node.Value.Nodes, node, depth + 1); } } @@ -1169,6 +1176,51 @@ namespace OpenRA.Mods.Common.UtilityCommands } } + if (engineVersion < 20150326) + { + // Remove TurboBoost from missiles + if (depth == 1 && node.Key == "Projectile" && node.Value.Nodes.Exists(n => n.Key == "TurboBoost")) + { + node.Value.Nodes.RemoveAll(n => n.Key == "TurboBoost"); + Console.WriteLine("'TurboBoost' has been removed."); + Console.WriteLine("If you want to reproduce its behavior, create a duplicate"); + Console.WriteLine("of the weapon in question, change it to be anti-air only,"); + Console.WriteLine("increase its speed, make the original weapon anti-ground only,"); + Console.WriteLine("and add the new weapon as additional armament to the actor."); + } + + // Rename ROT to RateOfTurn + if (depth == 2 && node.Key == "ROT") + node.Key = "RateOfTurn"; + + // Rename High to Blockable + if (depth == 2 && parentKey == "Projectile" && node.Key == "High") + { + var highField = node.Value.Value != null ? FieldLoader.GetValue("High", node.Value.Value) : false; + var blockable = !highField; + + node.Value.Value = blockable.ToString().ToLowerInvariant(); + node.Key = "Blockable"; + } + + // Move Palette from weapon to projectiles + if (depth == 0) + { + var weapons = node.Value.Nodes; + var palette = weapons.FirstOrDefault(p => p.Key == "Palette"); + var projectile = weapons.FirstOrDefault(r => r.Key == "Projectile"); + + if (palette != null) + { + var projectileFields = projectile.Value.Nodes; + var paletteName = palette.Value.Value != null ? FieldLoader.GetValue("Palette", palette.Value.Value) : "effect"; + + projectileFields.Add(new MiniYamlNode("Palette", paletteName.ToString())); + weapons.Remove(palette); + } + } + } + UpgradeWeaponRules(engineVersion, ref node.Value.Nodes, node, depth + 1); } } diff --git a/mods/cnc/rules/defaults.yaml b/mods/cnc/rules/defaults.yaml index 13cb4562a9..19eb076058 100644 --- a/mods/cnc/rules/defaults.yaml +++ b/mods/cnc/rules/defaults.yaml @@ -531,7 +531,7 @@ Crushable: CrushClasses: wall CrushSound: sandbag2.aud - BlocksBullets: + BlocksProjectiles: LineBuild: Range: 8 NodeTypes: wall diff --git a/mods/cnc/rules/ships.yaml b/mods/cnc/rules/ships.yaml index f9e28d7720..a293dbf7ac 100644 --- a/mods/cnc/rules/ships.yaml +++ b/mods/cnc/rules/ships.yaml @@ -70,3 +70,4 @@ LST: MaxWeight: 5 PipCount: 5 PassengerFacing: 0 + diff --git a/mods/cnc/weapons/explosions.yaml b/mods/cnc/weapons/explosions.yaml index 0ff192d4d2..53de2668c5 100644 --- a/mods/cnc/weapons/explosions.yaml +++ b/mods/cnc/weapons/explosions.yaml @@ -83,3 +83,4 @@ Napalm.Crate: Warhead@3Eff: CreateEffect Explosion: med_napalm ImpactSound: flamer2.aud + diff --git a/mods/cnc/weapons/largecaliber.yaml b/mods/cnc/weapons/largecaliber.yaml index 7a190ec3c8..80c7e86071 100644 --- a/mods/cnc/weapons/largecaliber.yaml +++ b/mods/cnc/weapons/largecaliber.yaml @@ -120,7 +120,7 @@ ArtilleryShell: Report: TNKFIRE2.AUD Projectile: Bullet Speed: 204 - High: yes + Blockable: false Angle: 56 Inaccuracy: 1c256 ContrailLength: 30 @@ -139,3 +139,4 @@ ArtilleryShell: Warhead@3Eff: CreateEffect Explosion: poof ImpactSound: XPLOSML2.AUD + diff --git a/mods/cnc/weapons/missiles.yaml b/mods/cnc/weapons/missiles.yaml index 0a6c881aee..aed440106e 100644 --- a/mods/cnc/weapons/missiles.yaml +++ b/mods/cnc/weapons/missiles.yaml @@ -6,10 +6,10 @@ Rockets: ValidTargets: Ground, Air Projectile: Missile Arm: 0 - High: yes + Blockable: false Inaccuracy: 128 Image: DRAGON - ROT: 15 + RateOfTurn: 15 Trail: smokey ContrailLength: 8 Speed: 298 @@ -40,10 +40,10 @@ BikeRockets: BurstDelay: 10 Projectile: Missile Arm: 0 - High: yes + Blockable: false Inaccuracy: 128 Image: DRAGON - ROT: 10 + RateOfTurn: 10 Trail: smokey ContrailLength: 8 Speed: 213 @@ -74,10 +74,10 @@ OrcaAGMissiles: ValidTargets: Ground Projectile: Missile Arm: 0 - High: yes + Blockable: false Inaccuracy: 128 Image: DRAGON - ROT: 20 + RateOfTurn: 20 Trail: smokey ContrailLength: 8 Speed: 298 @@ -107,10 +107,10 @@ OrcaAAMissiles: ValidTargets: Air Projectile: Missile Arm: 0 - High: yes + Blockable: false Inaccuracy: 128 Image: DRAGON - ROT: 20 + RateOfTurn: 20 Trail: smokey ContrailLength: 8 Speed: 298 @@ -138,10 +138,10 @@ MammothMissiles: BurstDelay: 15 Projectile: Missile Arm: 0 - High: yes + Blockable: false Inaccuracy: 128 Image: DRAGON - ROT: 20 + RateOfTurn: 20 Trail: smokey ContrailLength: 8 Speed: 341 @@ -177,12 +177,12 @@ MammothMissiles: ValidTargets: Ground Projectile: Bullet Arm: 5 - High: yes + Blockable: false Shadow: true Inaccuracy: 853 Angle: 62 Image: DRAGON - ROT: 2 + RateOfTurn: 2 ContrailLength: 10 Trail: smokey Speed: 341 @@ -211,10 +211,10 @@ MammothMissiles: ValidTargets: Ground, Air Projectile: Missile Arm: 0 - High: yes + Blockable: false Inaccuracy: 213 Image: DRAGON - ROT: 10 + RateOfTurn: 10 Trail: smokey ContrailLength: 8 Speed: 213 @@ -243,10 +243,10 @@ BoatMissile: Report: ROCKET2.AUD Projectile: Missile Arm: 0 - High: yes + Blockable: false Inaccuracy: 213 Image: DRAGON - ROT: 10 + RateOfTurn: 10 Trail: smokey ContrailLength: 8 Speed: 170 @@ -278,10 +278,10 @@ TowerMissle: ValidTargets: Ground Projectile: Missile Arm: 0 - High: yes + Blockable: false Inaccuracy: 128 Image: DRAGON - ROT: 20 + RateOfTurn: 20 Trail: smokey ContrailLength: 8 Speed: 298 @@ -309,9 +309,9 @@ SAMMissile: ValidTargets: Air Projectile: Missile Arm: 0 - High: yes + Blockable: false Image: MISSILE - ROT: 20 + RateOfTurn: 20 Speed: 426 RangeLimit: 35 Trail: smokey @@ -338,7 +338,7 @@ HonestJohn: Report: ROCKET1.AUD Projectile: Bullet Arm: 10 - High: yes + Blockable: false Shadow: true Inaccuracy: 213 Image: patriot @@ -368,11 +368,11 @@ Patriot: Report: ROCKET2.AUD ValidTargets: Air Projectile: Missile - High: yes + Blockable: false Image: patriot Trail: smokey ContrailLength: 8 - ROT: 20 + RateOfTurn: 20 Speed: 341 RangeLimit: 30 Angle: 88 @@ -391,3 +391,4 @@ Patriot: Warhead@3Eff: CreateEffect Explosion: poof ImpactSound: xplos.aud + diff --git a/mods/cnc/weapons/other.yaml b/mods/cnc/weapons/other.yaml index d97f2312ca..8c57b73007 100644 --- a/mods/cnc/weapons/other.yaml +++ b/mods/cnc/weapons/other.yaml @@ -1,4 +1,3 @@ - Flamethrower: ReloadDelay: 55 Range: 2c512 @@ -74,7 +73,7 @@ Grenade: Report: toss1.aud Projectile: Bullet Speed: 119 - High: yes + Blockable: false Angle: 62 Inaccuracy: 213 Image: BOMB @@ -236,3 +235,4 @@ Demolish: Warhead@2Eff: CreateEffect Explosion: building ImpactSound: xplobig6.aud + diff --git a/mods/cnc/weapons/smallcaliber.yaml b/mods/cnc/weapons/smallcaliber.yaml index a3bc7676f6..f243f6d51d 100644 --- a/mods/cnc/weapons/smallcaliber.yaml +++ b/mods/cnc/weapons/smallcaliber.yaml @@ -38,7 +38,7 @@ HeliAGGun: Report: gun5.aud Projectile: Bullet Speed: 1c682 - High: True + Blockable: false Warhead@1Dam: SpreadDamage Spread: 256 Damage: 20 @@ -61,7 +61,7 @@ HeliAAGun: Report: gun5.aud Projectile: Bullet Speed: 1c682 - High: True + Blockable: false Warhead@1Dam: SpreadDamage Spread: 128 Damage: 20 @@ -183,7 +183,7 @@ APCGun.AA: ValidTargets: Air Projectile: Bullet Speed: 1c682 - High: true + Blockable: false Warhead@1Dam: SpreadDamage Spread: 128 Damage: 25 @@ -192,3 +192,4 @@ APCGun.AA: Heavy: 50 Warhead@2Eff: CreateEffect Explosion: small_frag + diff --git a/mods/cnc/weapons/superweapons.yaml b/mods/cnc/weapons/superweapons.yaml index 6356e1c875..aa563bbf44 100644 --- a/mods/cnc/weapons/superweapons.yaml +++ b/mods/cnc/weapons/superweapons.yaml @@ -97,3 +97,4 @@ IonCannon: SmudgeType: Scorch Size: 2,1 Delay: 6 + diff --git a/mods/d2k/rules/structures.yaml b/mods/d2k/rules/structures.yaml index e5180043b1..2eeb948938 100644 --- a/mods/d2k/rules/structures.yaml +++ b/mods/d2k/rules/structures.yaml @@ -486,7 +486,7 @@ wall: Type: Concrete Crushable: CrushClasses: Concretewall - BlocksBullets: + BlocksProjectiles: LineBuild: Range: 8 NodeTypes: wall, turret diff --git a/mods/d2k/weapons.yaml b/mods/d2k/weapons.yaml index 07ce4901ac..8e2b134dc0 100644 --- a/mods/d2k/weapons.yaml +++ b/mods/d2k/weapons.yaml @@ -32,7 +32,7 @@ Bazooka: ContrailLength: 10 Inaccuracy: 96 Image: RPG - ROT: 5 + RateOfTurn: 5 RangeLimit: 35 Warhead@1Dam: SpreadDamage Spread: 96 @@ -104,7 +104,7 @@ Slung: ValidTargets: Ground Projectile: Bullet Speed: 320 - High: true + Blockable: false Shadow: yes Angle: 88 Inaccuracy: 384 @@ -183,7 +183,7 @@ QuadRockets: Arm: 0 Inaccuracy: 96 Image: RPG - ROT: 10 + RateOfTurn: 10 Speed: 256 RangeLimit: 40 Warhead@1Dam: SpreadDamage @@ -209,7 +209,7 @@ TurretGun: Report: TURRET1.WAV Projectile: Bullet Speed: 704 - High: yes + Blockable: false Shadow: no Inaccuracy: 288 Image: 120mm @@ -238,11 +238,11 @@ TowerMissile: BurstDelay: 15 Projectile: Bullet Arm: 0 - High: yes + Blockable: false Shadow: yes Inaccuracy: 384 Image: MISSILE2 - ROT: 10 + RateOfTurn: 10 Speed: 256 RangeLimit: 50 Angle: 110 @@ -342,12 +342,12 @@ DevBullet: Projectile: Bullet Speed: 358 Arm: 5 - High: yes + Blockable: false Shadow: yes Inaccuracy: 1c416 Angle: 110 Image: MISSILE2 - ROT: 5 + RateOfTurn: 5 ContrailLength: 5 Warhead@1Dam: SpreadDamage Spread: 384 @@ -373,7 +373,7 @@ NerveGasMissile: Report: MISSLE1.WAV Projectile: Bullet Speed: 448 - High: true + Blockable: false Shadow: yes Angle: 110 Inaccuracy: 1c96 @@ -403,7 +403,7 @@ NerveGasMissile: Report: MORTAR1.WAV Projectile: Bullet Speed: 256 - High: true + Blockable: false Shadow: yes Angle: 62 Inaccuracy: 1c256 @@ -451,7 +451,7 @@ ChainGun: Report: 20MMGUN1.WAV Projectile: Bullet Speed: 1c256 - High: true + Blockable: false Warhead@1Dam: SpreadDamage Spread: 96 Damage: 20 @@ -659,7 +659,7 @@ Grenade: Report: Projectile: Bullet Speed: 204 - High: true + Blockable: false Angle: 62 Inaccuracy: 416 Image: BOMBS @@ -689,7 +689,7 @@ Shrapnel: Report: Projectile: Bullet Speed: 50, 125 - High: true + Blockable: false Angle: 91, 264 Inaccuracy: 416 Image: bombs diff --git a/mods/ra/rules/defaults.yaml b/mods/ra/rules/defaults.yaml index fcfe591d69..47b9c78a35 100644 --- a/mods/ra/rules/defaults.yaml +++ b/mods/ra/rules/defaults.yaml @@ -462,7 +462,7 @@ DestroyedSounds: sandbag2.aud Crushable: CrushClasses: wall - BlocksBullets: + BlocksProjectiles: LineBuild: Range: 8 NodeTypes: wall diff --git a/mods/ra/rules/ships.yaml b/mods/ra/rules/ships.yaml index 3c7b4b8f64..c7d0d07a9a 100644 --- a/mods/ra/rules/ships.yaml +++ b/mods/ra/rules/ships.yaml @@ -134,6 +134,10 @@ DD: Weapon: DepthCharge LocalOffset: 0,-100,0, 0,100,0 LocalYaw: 80, -80 + Armament@TERTIARY: + Weapon: StingerAA + LocalOffset: 0,-100,0, 0,100,0 + LocalYaw: 64, -64 AttackTurreted: Selectable: Bounds: 38,38 diff --git a/mods/ra/weapons/explosions.yaml b/mods/ra/weapons/explosions.yaml index 516a07efe8..0391469099 100644 --- a/mods/ra/weapons/explosions.yaml +++ b/mods/ra/weapons/explosions.yaml @@ -251,3 +251,4 @@ OreExplosion: Warhead@3Eff: CreateEffect Explosion: med_explosion ImpactSound: kaboom25.aud + diff --git a/mods/ra/weapons/largecaliber.yaml b/mods/ra/weapons/largecaliber.yaml index fc76ac3d60..f8cc8f1973 100644 --- a/mods/ra/weapons/largecaliber.yaml +++ b/mods/ra/weapons/largecaliber.yaml @@ -143,7 +143,7 @@ TurretGun: Report: TANK5.AUD Projectile: Bullet Speed: 204 - High: true + Blockable: false Angle: 62 Inaccuracy: 1c682 Image: 120MM @@ -176,7 +176,7 @@ TurretGun: Report: TURRET1.AUD Projectile: Bullet Speed: 204 - High: true + Blockable: false Angle: 62 Inaccuracy: 2c938 Image: 120MM @@ -228,3 +228,4 @@ TurretGun: Explosion: small_splash ImpactSound: splash9.aud ValidImpactTypes: Water + diff --git a/mods/ra/weapons/missiles.yaml b/mods/ra/weapons/missiles.yaml index 3113d73dcf..2f01dcb700 100644 --- a/mods/ra/weapons/missiles.yaml +++ b/mods/ra/weapons/missiles.yaml @@ -9,11 +9,11 @@ Maverick: Projectile: Missile Speed: 256 Arm: 2 - High: true + Blockable: false ContrailLength: 10 Inaccuracy: 512 Image: DRAGON - ROT: 5 + RateOfTurn: 5 RangeLimit: 60 Warhead@1Dam: SpreadDamage Spread: 128 @@ -45,12 +45,12 @@ Dragon: Projectile: Missile Speed: 213 Arm: 2 - High: true + Blockable: false Trail: smokey ContrailLength: 10 Inaccuracy: 128 Image: DRAGON - ROT: 5 + RateOfTurn: 5 RangeLimit: 35 Warhead@1Dam: SpreadDamage Spread: 128 @@ -83,11 +83,11 @@ HellfireAG: Projectile: Missile Speed: 256 Arm: 2 - High: true + Blockable: false ContrailLength: 10 Inaccuracy: 128 Image: DRAGON - ROT: 10 + RateOfTurn: 10 RangeLimit: 20 Warhead@1Dam: SpreadDamage Spread: 128 @@ -120,11 +120,11 @@ HellfireAA: Projectile: Missile Speed: 384 Arm: 2 - High: true + Blockable: false ContrailLength: 10 Inaccuracy: 128 Image: DRAGON - ROT: 10 + RateOfTurn: 10 RangeLimit: 20 Warhead@1Dam: SpreadDamage Spread: 128 @@ -156,11 +156,11 @@ MammothTusk: Projectile: Missile Speed: 341 Arm: 2 - High: true + Blockable: false ContrailLength: 10 Inaccuracy: 128 Image: DRAGON - ROT: 15 + RateOfTurn: 15 RangeLimit: 40 Warhead@1Dam: SpreadDamage Spread: 256 @@ -194,10 +194,10 @@ Nike: ValidTargets: Air Projectile: Missile Arm: 3 - High: true + Blockable: false ContrailLength: 10 Image: MISSILE - ROT: 25 + RateOfTurn: 25 RangeLimit: 50 Speed: 341 Warhead@1Dam: SpreadDamage @@ -224,10 +224,10 @@ RedEye: ValidTargets: Air Projectile: Missile Arm: 3 - High: true + Blockable: false ContrailLength: 10 Image: MISSILE - ROT: 20 + RateOfTurn: 20 RangeLimit: 30 Speed: 298 Warhead@1Dam: SpreadDamage @@ -253,7 +253,7 @@ SubMissile: Report: MISSILE6.AUD Projectile: Bullet Speed: 102 - High: true + Blockable: false Angle: 165 Inaccuracy: 2c938 Image: MISSILE @@ -285,15 +285,14 @@ Stinger: Report: MISSILE6.AUD Burst: 2 BurstDelay: 0 - ValidTargets: Air, Ground, Water + ValidTargets: Ground, Water Projectile: Missile Arm: 3 - High: true + Blockable: false ContrailLength: 10 Image: DRAGON - ROT: 20 + RateOfTurn: 20 RangeLimit: 50 - TurboBoost: true Speed: 170 Warhead@1Dam: SpreadDamage Spread: 128 @@ -320,12 +319,51 @@ Stinger: ImpactSound: splash9.aud ValidImpactTypes: Water +StingerAA: + ReloadDelay: 60 + Range: 9c0 + Report: MISSILE6.AUD + Burst: 2 + BurstDelay: 0 + ValidTargets: Air + Projectile: Missile + Arm: 3 + Blockable: false + ContrailLength: 10 + Image: DRAGON + RateOfTurn: 20 + RangeLimit: 50 + Speed: 255 + Warhead@1Dam: SpreadDamage + Spread: 128 + Damage: 30 + DeathType: 4 + ValidTargets: Air, Ground, Water + Versus: + None: 30 + Wood: 75 + Light: 75 + Concrete: 50 + Warhead@2Smu: LeaveSmudge + SmudgeType: Crater + Warhead@3Eff: CreateEffect + Explosion: med_explosion + ImpactSound: kaboom25.aud + InvalidImpactTypes: Water, Air, AirHit + Warhead@5EffAir: CreateEffect + Explosion: med_explosion_air + ImpactSound: kaboom25.aud + ValidImpactTypes: Air, AirHit + Warhead@4EffWater: CreateEffect + Explosion: med_splash + ImpactSound: splash9.aud + ValidImpactTypes: Water + TorpTube: ReloadDelay: 100 Range: 9c0 Report: TORPEDO1.AUD ValidTargets: Water, Underwater, Bridge - Palette: shadow Burst: 2 BurstDelay: 20 Projectile: Missile @@ -333,9 +371,10 @@ TorpTube: Arm: 3 Speed: 85 Trail: bubbles - ROT: 1 + RateOfTurn: 1 RangeLimit: 160 BoundToTerrainType: Water + Palette: shadow Warhead@1Dam: SpreadDamage Spread: 426 Damage: 180 @@ -368,7 +407,7 @@ SCUD: Report: MISSILE1.AUD Projectile: Bullet Speed: 170 - High: true + Blockable: false Shadow: false Trail: smokey TrailDelay: 5 @@ -404,12 +443,12 @@ APTusk: Projectile: Missile Speed: 298 Arm: 2 - High: true + Blockable: false Trail: smokey ContrailLength: 10 Inaccuracy: 128 Image: DRAGON - ROT: 10 + RateOfTurn: 10 RangeLimit: 22 Warhead@1Dam: SpreadDamage Spread: 128 @@ -431,3 +470,4 @@ APTusk: Explosion: med_splash ImpactSound: splash9.aud ValidImpactTypes: Water + diff --git a/mods/ra/weapons/other.yaml b/mods/ra/weapons/other.yaml index 7d9d4a1bac..c2132697f4 100644 --- a/mods/ra/weapons/other.yaml +++ b/mods/ra/weapons/other.yaml @@ -56,7 +56,7 @@ Napalm: Projectile: Bullet Image: BOMBLET Speed: 85 - High: yes + Blockable: false Warhead@1Dam: SpreadDamage Spread: 170 Damage: 100 @@ -83,7 +83,7 @@ Grenade: Report: grenade1.aud Projectile: Bullet Speed: 136 - High: true + Blockable: false Angle: 62 Inaccuracy: 554 Image: BOMB @@ -115,7 +115,7 @@ DepthCharge: Speed: 85 Image: BOMB Angle: 62 - High: true + Blockable: false Inaccuracy: 128 Warhead@1Dam: SpreadDamage Spread: 128 @@ -295,3 +295,4 @@ MADTankDetonate: Warhead@3Eff: CreateEffect Explosion: med_explosion ImpactSound: mineblo1.aud + diff --git a/mods/ra/weapons/smallcaliber.yaml b/mods/ra/weapons/smallcaliber.yaml index 5cbae45870..9c542ea9ba 100644 --- a/mods/ra/weapons/smallcaliber.yaml +++ b/mods/ra/weapons/smallcaliber.yaml @@ -30,7 +30,7 @@ ZSU-23: ValidTargets: Air Projectile: Bullet Speed: 3c340 - High: true + Blockable: false Warhead@1Dam: SpreadDamage Spread: 213 Damage: 12 @@ -162,7 +162,7 @@ ChainGun: Report: GUN13.AUD Projectile: Bullet Speed: 1c682 - High: true + Blockable: false Warhead@1Dam: SpreadDamage Spread: 128 Damage: 30 @@ -187,7 +187,7 @@ ChainGun.Yak: Report: GUN13.AUD Projectile: Bullet Speed: 1c682 - High: true + Blockable: false Warhead@1Dam: SpreadDamage Spread: 128 Damage: 40 @@ -300,7 +300,7 @@ FLAK-23: ValidTargets: Air, Ground, Water Projectile: Bullet Speed: 1c682 - High: true + Blockable: false Warhead@1Dam: SpreadDamage Spread: 213 Damage: 20 @@ -337,3 +337,4 @@ Sniper: Light: 0 Heavy: 0 Concrete: 0 + diff --git a/mods/ra/weapons/superweapons.yaml b/mods/ra/weapons/superweapons.yaml index 3f5ac2a578..5781d04bb3 100644 --- a/mods/ra/weapons/superweapons.yaml +++ b/mods/ra/weapons/superweapons.yaml @@ -111,3 +111,4 @@ Atomic: SmudgeType: Scorch Size: 5 Delay: 20 + diff --git a/mods/ts/rules/defaults.yaml b/mods/ts/rules/defaults.yaml index decdcae1dc..f99c07b2ef 100644 --- a/mods/ts/rules/defaults.yaml +++ b/mods/ts/rules/defaults.yaml @@ -110,7 +110,7 @@ DestroyedSounds: crmble2.aud Crushable: CrushClasses: wall - BlocksBullets: + BlocksProjectiles: LineBuild: Range: 8 NodeTypes: wall diff --git a/mods/ts/weapons.yaml b/mods/ts/weapons.yaml index 00c66931c0..99595c9091 100644 --- a/mods/ts/weapons.yaml +++ b/mods/ts/weapons.yaml @@ -55,7 +55,7 @@ Grenade: Range: 4c512 Projectile: Bullet Speed: 85 - High: yes + Blockable: false Shadow: true Angle: 62 Inaccuracy: 554 @@ -88,18 +88,18 @@ Bazooka: MinRange: 0c512 Report: RKETINF1.AUD ValidTargets: Ground, Air - Palette: ra Projectile: Missile Speed: 213 Arm: 3 - High: true + Blockable: false Shadow: true Inaccuracy: 128 Image: DRAGON - ROT: 8 + RateOfTurn: 8 RangeLimit: 50 CloseEnough: 256 LockOnProbability: 80 + Palette: ra Warhead@1Dam: SpreadDamage Spread: 128 Damage: 35 @@ -131,16 +131,16 @@ MultiCluster: Range: 6c0 Report: MISL1.AUD ValidTargets: Ground - Palette: ra Projectile: Missile Speed: 170 Arm: 2 - High: yes + Blockable: false Shadow: true Inaccuracy: 128 Image: DRAGON - ROT: 8 + RateOfTurn: 8 RangeLimit: 35 + Palette: ra Warhead@1Dam: SpreadDamage Spread: 128 Damage: 65 @@ -249,7 +249,7 @@ CyCannon: ValidTargets: Ground Projectile: Bullet Speed: 192 - High: yes + Blockable: false Shadow: true Image: TORPEDO Warhead@1Dam: SpreadDamage @@ -352,13 +352,13 @@ FiendShard: Burst: 3 Range: 5c0 Report: FIEND2.AUD - Palette: greentiberium Projectile: Bullet Speed: 213 Image: CRYSTAL4 Inaccuracy: 512 Shadow: true Angle: 88 + Palette: greentiberium Warhead@1Dam: SpreadDamage Damage: 35 DeathType: 1 @@ -403,16 +403,16 @@ HoverMissile: Range: 8c0 Report: HOVRMIS1.AUD ValidTargets: Ground, Air - Palette: ra Projectile: Missile Speed: 213 Arm: 2 - High: yes + Blockable: false Shadow: true Inaccuracy: 128 Image: DRAGON - ROT: 8 + RateOfTurn: 8 RangeLimit: 35 + Palette: ra Warhead@1Dam: SpreadDamage Spread: 128 Damage: 30 @@ -445,12 +445,12 @@ HoverMissile: Report: 120MMF.AUD Burst: 2 BurstDelay: 5 - Palette: ra Projectile: Bullet Speed: 682 Image: 120mm Shadow: true Angle: 62 + Palette: ra Warhead@1Dam: SpreadDamage Spread: 128 Damage: 50 @@ -478,16 +478,16 @@ MammothTusk: Report: MISL1.AUD ValidTargets: Air Burst: 2 - Palette: ra Projectile: Missile Arm: 0 - High: yes + Blockable: false Shadow: true Inaccuracy: 128 Image: DRAGON - ROT: 10 + RateOfTurn: 10 Speed: 170 RangeLimit: 35 + Palette: ra Warhead@1Dam: SpreadDamage Spread: 171 Damage: 40 @@ -638,16 +638,16 @@ BikeMissile: Range: 5c0 Report: MISL1.AUD ValidTargets: Ground - Palette: ra Projectile: Missile Arm: 2 - High: yes + Blockable: false Shadow: true Inaccuracy: 128 Image: DRAGON - ROT: 8 + RateOfTurn: 8 Speed: 213 RangeLimit: 35 + Palette: ra Warhead@1Dam: SpreadDamage Spread: 256 Damage: 40 @@ -742,16 +742,16 @@ Dragon: Burst: 2 Report: MISL1.AUD ValidTargets: Ground, Air - Palette: ra Projectile: Missile Speed: 213 Arm: 2 - High: yes + Blockable: false Shadow: true Inaccuracy: 128 Image: DRAGON - ROT: 8 + RateOfTurn: 8 RangeLimit: 35 + Palette: ra Warhead@1Dam: SpreadDamage Spread: 128 Damage: 30 @@ -782,12 +782,12 @@ Dragon: ReloadDelay: 50 Range: 6c768 Report: 120MMF.AUD - Palette: ra Projectile: Bullet Speed: 682 Image: 120mm Shadow: true Angle: 62 + Palette: ra Warhead@1Dam: SpreadDamage Spread: 128 Damage: 36 @@ -813,13 +813,13 @@ Dragon: ReloadDelay: 110 Range: 18c0 Report: 120MMF.AUD - Palette: ra Projectile: Bullet Speed: 170 Image: 120mm Angle: 165 Shadow: true - High: yes + Blockable: false + Palette: ra MinRange: 5c0 Warhead@1Dam: SpreadDamage Spread: 298 @@ -849,16 +849,16 @@ Hellfire: Report: ORCAMIS1.AUD Burst: 2 ValidTargets: Ground, Air - Palette: ra Projectile: Missile Speed: 256 Arm: 2 - High: yes + Blockable: false Shadow: true Inaccuracy: 128 Image: DRAGON - ROT: 8 + RateOfTurn: 8 RangeLimit: 35 + Palette: ra Warhead@1Dam: SpreadDamage Spread: 85 Damage: 30 @@ -888,11 +888,11 @@ Hellfire: Bomb: ReloadDelay: 10 Range: 5c0 - Palette: player Projectile: Bullet Speed: 170 Image: canister Shadow: true + Palette: player Warhead@1Dam: SpreadDamage Spread: 298 Damage: 160 @@ -924,11 +924,11 @@ Proton: Projectile: Missile Speed: 256 Arm: 2 - High: yes + Blockable: false Shadow: true Inaccuracy: 128 Image: TORPEDO - ROT: 1 + RateOfTurn: 1 RangeLimit: 35 Warhead@1Dam: SpreadDamage Spread: 128 @@ -1064,13 +1064,13 @@ RPGTower: ReloadDelay: 80 Range: 8c0 Report: GLNCH4.AUD - Palette: player Projectile: Bullet Speed: 384 - High: yes + Blockable: false Shadow: true Angle: 62 Image: canister + Palette: player Warhead@1Dam: SpreadDamage Spread: 128 Damage: 110 @@ -1098,16 +1098,16 @@ SAMTower: Range: 15c0 Report: SAMSHOT1.AUD ValidTargets: Air - Palette: ra Projectile: Missile Speed: 298 Arm: 2 - High: yes + Blockable: false Shadow: true Inaccuracy: 128 Image: DRAGON - ROT: 5 + RateOfTurn: 5 RangeLimit: 60 + Palette: ra Warhead@1Dam: SpreadDamage Spread: 128 Damage: 33 @@ -1149,7 +1149,7 @@ EMPulseCannon: Report: PLSECAN2.AUD Projectile: Bullet Speed: 425 - High: yes + Blockable: false Shadow: true Angle: 62 Image: pulsball @@ -1266,3 +1266,4 @@ ClusterMissile: SmudgeType: SmallScorch Size: 5 Delay: 20 +