From 52b08a769d29d5dfc2dc571da7bdaf85f54b1a60 Mon Sep 17 00:00:00 2001 From: Paul Chote Date: Sun, 28 May 2017 19:36:35 +0000 Subject: [PATCH] Update d2k AutoTarget definitions. --- mods/d2k/maps/atreides-05/rules.yaml | 8 ++++++-- mods/d2k/rules/defaults.yaml | 15 ++++++++++++--- mods/d2k/rules/infantry.yaml | 8 +++++--- mods/d2k/rules/structures.yaml | 3 ++- mods/d2k/rules/vehicles.yaml | 15 +++++++++------ 5 files changed, 34 insertions(+), 15 deletions(-) diff --git a/mods/d2k/maps/atreides-05/rules.yaml b/mods/d2k/maps/atreides-05/rules.yaml index b7524a1976..55c4e5951e 100644 --- a/mods/d2k/maps/atreides-05/rules.yaml +++ b/mods/d2k/maps/atreides-05/rules.yaml @@ -33,13 +33,17 @@ barracks.harkonnen: Buildable: Prerequisites: ~disabled -MustBeDestroyed: - AutoTargetIgnore: + Targetable: + TargetTypes: Ground, C4, Structure, NoAutoTarget starport: ExternalCondition@lua: Condition: captured - AutoTargetIgnore: + Targetable: + RequiresCondition: captured + Targetable@AUTOTARGET: RequiresCondition: !captured + TargetTypes: Ground, C4, Structure, NoAutoTarget concreteb: Buildable: diff --git a/mods/d2k/rules/defaults.yaml b/mods/d2k/rules/defaults.yaml index 9522151542..2a9d60f51b 100644 --- a/mods/d2k/rules/defaults.yaml +++ b/mods/d2k/rules/defaults.yaml @@ -120,6 +120,18 @@ RequiresCondition: rank-elite ZOffset: 256 +^AutoTargetGround: + AutoTarget: + AutoTargetPriority@DEFAULT: + ValidTargets: Infantry, Vehicle, Water, Structure, Defense + InvalidTargets: NoAutoTarget + +^AutoTargetAll: + AutoTarget: + AutoTargetPriority@DEFAULT: + ValidTargets: Infantry, Vehicle, Water, Air, Structure, Defense + InvalidTargets: NoAutoTarget + ^Vehicle: Inherits@1: ^ExistsInWorld Inherits@2: ^GainsExperience @@ -190,7 +202,6 @@ Type: CenterPosition Tooltip: Name: Wreck - AutoTargetIgnore: ScriptTriggers: WithFacingSpriteBody: HitShape: @@ -278,7 +289,6 @@ SmallExplosionDeath: 3 BulletDeath: 4 CrushedSequence: die-crushed - AutoTarget: AttackMove: DrawLineToTarget: Passenger: @@ -395,7 +405,6 @@ Inherits: ^Building WithSpriteTurret: AttackTurreted: - AutoTarget: RenderRangeCircle: DetectCloaked: Range: 1c768 diff --git a/mods/d2k/rules/infantry.yaml b/mods/d2k/rules/infantry.yaml index 80bd56c611..92573a608e 100644 --- a/mods/d2k/rules/infantry.yaml +++ b/mods/d2k/rules/infantry.yaml @@ -1,5 +1,6 @@ light_inf: Inherits: ^Infantry + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Infantry BuildPaletteOrder: 10 @@ -43,13 +44,13 @@ engineer: Captures: CaptureTypes: building, husk PlayerExperience: 50 - -AutoTarget: -RevealOnFire: Voiced: VoiceSet: EngineerVoice trooper: Inherits: ^Infantry + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Infantry BuildPaletteOrder: 20 @@ -78,7 +79,6 @@ trooper: thumper: Inherits: ^Infantry - -AutoTarget: -RevealOnFire: Buildable: Queue: Infantry @@ -121,6 +121,7 @@ thumper: fremen: Inherits: ^Infantry + Inherits@AUTOTARGET: ^AutoTargetGround Tooltip: Name: Fremen Buildable: @@ -164,6 +165,7 @@ fremen: grenadier: Inherits: ^Infantry + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Infantry BuildPaletteOrder: 80 @@ -194,6 +196,7 @@ grenadier: sardaukar: Inherits: ^Infantry + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Infantry BuildPaletteOrder: 80 @@ -244,7 +247,6 @@ saboteur: DetonationDelay: 0 Flashes: 0 EnterBehaviour: Suicide - -AutoTarget: -RevealOnFire: Cloak: InitialDelay: 85 diff --git a/mods/d2k/rules/structures.yaml b/mods/d2k/rules/structures.yaml index 1e89f19044..9727cd1d13 100644 --- a/mods/d2k/rules/structures.yaml +++ b/mods/d2k/rules/structures.yaml @@ -700,7 +700,6 @@ wall: Targetable: TargetTypes: Ground, Wall WithWallSpriteBody: - AutoTargetIgnore: Sellable: SellSounds: CHUNG.WAV Guardable: @@ -718,6 +717,7 @@ wall: medium_gun_turret: Inherits: ^Defense + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Building Prerequisites: barracks @@ -761,6 +761,7 @@ medium_gun_turret: large_gun_turret: Inherits: ^Defense Inherits@IDISABLE: ^DisabledOverlay + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Building Prerequisites: outpost, upgrade.conyard, ~techlevel.medium diff --git a/mods/d2k/rules/vehicles.yaml b/mods/d2k/rules/vehicles.yaml index 1648d5250e..a7aff7a07b 100644 --- a/mods/d2k/rules/vehicles.yaml +++ b/mods/d2k/rules/vehicles.yaml @@ -100,6 +100,7 @@ harvester: trike: Inherits: ^Vehicle + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Vehicle BuildPaletteOrder: 10 @@ -131,7 +132,6 @@ trike: LocalOffset: -544,0,0 MuzzleSequence: muzzle AttackFrontal: - AutoTarget: Explodes: Weapon: UnitExplodeSmall EmptyWeapon: UnitExplodeSmall @@ -140,6 +140,7 @@ trike: quad: Inherits: ^Vehicle + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Vehicle Prerequisites: upgrade.light, ~techlevel.medium @@ -164,7 +165,6 @@ quad: Weapon: Rocket LocalOffset: 128,64,64, 128,-64,64 AttackFrontal: - AutoTarget: Explodes: Weapon: UnitExplodeSmall EmptyWeapon: UnitExplodeSmall @@ -175,6 +175,7 @@ quad: siege_tank: Inherits: ^Tank + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Armor Prerequisites: upgrade.heavy, ~techlevel.medium @@ -221,6 +222,7 @@ siege_tank: missile_tank: Inherits: ^Tank + Inherits@AUTOTARGET: ^AutoTargetAll Tooltip: Name: Missile Tank Buildable: @@ -259,6 +261,7 @@ missile_tank: sonic_tank: Inherits: ^Vehicle + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Armor BuildPaletteOrder: 100 @@ -283,7 +286,6 @@ sonic_tank: Weapon: Sound LocalOffset: 600,0,427 AttackFrontal: - AutoTarget: Explodes: Weapon: UnitExplodeLarge EmptyWeapon: UnitExplodeLarge @@ -294,6 +296,7 @@ sonic_tank: devastator: Inherits: ^Tank + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Armor BuildPaletteOrder: 100 @@ -322,7 +325,6 @@ devastator: AttackFrontal: WithMuzzleOverlay: IgnoreOffset: true - AutoTarget: Explodes: Weapon: UnitExplodeLarge EmptyWeapon: UnitExplodeLarge @@ -339,6 +341,7 @@ devastator: raider: Inherits: ^Vehicle + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Vehicle BuildPaletteOrder: 10 @@ -368,7 +371,6 @@ raider: LocalOffset: 170,0,0 MuzzleSequence: muzzle AttackFrontal: - AutoTarget: Explodes: Weapon: UnitExplodeSmall EmptyWeapon: UnitExplodeSmall @@ -405,6 +407,7 @@ stealth_raider: deviator: Inherits: ^Tank + Inherits@AUTOTARGET: ^AutoTargetGround Valued: Cost: 1000 Tooltip: @@ -441,6 +444,7 @@ deviator: ^combat_tank: Inherits: ^Tank + Inherits@AUTOTARGET: ^AutoTargetGround Buildable: Queue: Armor BuildPaletteOrder: 40 @@ -472,7 +476,6 @@ deviator: AttackTurreted: WithMuzzleOverlay: WithSpriteTurret: - AutoTarget: Explodes: Weapon: UnitExplodeMed EmptyWeapon: UnitExplodeMed