diff --git a/mods/ra/maps/allies-03a/allies03a.lua b/mods/ra/maps/allies-03a/allies03a.lua index d914365daa..a230e87b20 100644 --- a/mods/ra/maps/allies-03a/allies03a.lua +++ b/mods/ra/maps/allies-03a/allies03a.lua @@ -10,6 +10,13 @@ WaterTransportTriggerArea = { CPos.New(39, 54), CPos.New(40, 54), CPos.New(41, 5 ParadropTriggerArea = { CPos.New(81, 60), CPos.New(82, 60), CPos.New(83, 60), CPos.New(63, 63), CPos.New(64, 63), CPos.New(65, 63), CPos.New(66, 63), CPos.New(67, 63), CPos.New(68, 63), CPos.New(69, 63), CPos.New(70, 63), CPos.New(71, 63), CPos.New(72, 63) } ReinforcementsTriggerArea = { CPos.New(96, 55), CPos.New(97, 55), CPos.New(97, 56), CPos.New(98, 56) } +if Map.Difficulty == "Easy" then + TanyaType = "e7" +else + TanyaType = "e7.noautotarget" + ChangeStance = true +end + IdleHunt = function(actor) Trigger.OnIdle(actor, actor.Hunt) end ProduceUnits = function(factory, count) @@ -32,36 +39,20 @@ ProduceUnits = function(factory, count) end end -countFreed = 0 -FreePrisoner = function(unit, type) - if not unit.IsDead then - local newUnit = Actor.Create(type, true, { Owner = player, Location = unit.Location, CenterPosition = unit.CenterPosition }) - unit.Destroy() - Trigger.AfterDelay(15, function() - if not newUnit.IsDead then - if not DefendPrisoners then - DefendPrisoners = player.AddSecondaryObjective("Keep all rescued Allied soldiers alive.") - end - Trigger.OnKilled(newUnit, function() player.MarkFailedObjective(DefendPrisoners) end) - else - player.MarkFailedObjective(FreePrisoners) - end - - countFreed = countFreed + 1 - if countFreed == 3 then - player.MarkCompletedObjective(FreePrisoners) - end - end) - end -end - SendAlliedUnits = function() Camera.Position = TanyaWaypoint.CenterPosition local Artillery = Actor.Create("arty", true, { Owner = player, Location = AlliedUnitsEntry.Location }) - local Tanya = Actor.Create("e7", true, { Owner = player, Location = AlliedUnitsEntry.Location }) - Tanya.Stance = "HoldFire" + local Tanya = Actor.Create(TanyaType, true, { Owner = player, Location = AlliedUnitsEntry.Location }) + + if ChangeStance then + Tanya.Stance = "HoldFire" + Trigger.AfterDelay(DateTime.Seconds(2), function() + Media.DisplayMessage("According to the rules of engagement I need your explicit orders to fire, Commander!", "Tanya") + end) + end Artillery.Stance = "HoldFire" + Tanya.Move(TanyaWaypoint.Location) Artillery.Move(ArtilleryWaypoint.Location) @@ -110,7 +101,7 @@ InitObjectives = function() KillBridges = player.AddPrimaryObjective("Destroy all bridges.") TanyaSurvive = player.AddPrimaryObjective("Tanya must survive.") KillUSSR = player.AddSecondaryObjective("Destroy all soviet Oil Pumps.") - FreePrisoners = player.AddSecondaryObjective("Free all imprisoned Allied soldiers.") + FreePrisoners = player.AddSecondaryObjective("Free all Allied soldiers and keep them alive.") ussr.AddPrimaryObjective("Bridges must not be destroyed.") Trigger.OnObjectiveCompleted(player, function(p, id) @@ -141,9 +132,6 @@ InitTriggers = function() Trigger.OnAnyKilled(Prisoners, function() player.MarkFailedObjective(FreePrisoners) end) - Trigger.OnKilled(PGuard1, function() FreePrisoner(PrisonedMedi1, "medi") end) - Trigger.OnKilled(PGuard2, function() FreePrisoner(PrisonedMedi2, "medi") FreePrisoner(PrisonedEngi, "hacke6") end) - Trigger.OnKilled(USSRTechCenter, function() Actor.Create("moneycrate", true, { Owner = ussr, Location = USSRMoneyCrateSpawn.Location }) end) @@ -247,7 +235,7 @@ InitTriggers = function() Trigger.OnAllKilled(bridges, function() player.MarkCompletedObjective(KillBridges) player.MarkCompletedObjective(TanyaSurvive) - if DefendPrisoners then player.MarkCompletedObjective(DefendPrisoners) end + player.MarkCompletedObjective(FreePrisoners) end) local oilPumps = Map.ActorsInBox(Map.TopLeft, Map.BottomRight, function(self) return self.Type == "v19" end) diff --git a/mods/ra/maps/allies-03a/map.yaml b/mods/ra/maps/allies-03a/map.yaml index 4006ca1e45..4d4b84c40d 100644 --- a/mods/ra/maps/allies-03a/map.yaml +++ b/mods/ra/maps/allies-03a/map.yaml @@ -28,6 +28,7 @@ Options: FragileAlliances: False StartingCash: 0 ConfigurableStartingUnits: False + Difficulties: Easy, Normal Players: PlayerReference@Neutral: @@ -981,7 +982,7 @@ Actors: Owner: USSR Facing: 160 SubCell: 1 - PrisonedMedi2: pmedi + PrisonedMedi2: medi Location: 57,67 Owner: Greece Facing: 128 @@ -996,7 +997,7 @@ Actors: Owner: USSR Facing: 96 SubCell: 2 - PrisonedEngi: pe6 + PrisonedEngi: hacke6 Location: 57,67 Owner: Greece Facing: 96 @@ -1081,7 +1082,7 @@ Actors: Owner: USSR Facing: 160 SubCell: 2 - PrisonedMedi1: pmedi + PrisonedMedi1: medi Location: 58,60 Owner: Greece Facing: 0 @@ -1356,6 +1357,12 @@ Actors: USSRMoneyCrateSpawn: waypoint Location: 59,72 Owner: Neutral + Jail1: prison + Location: 58,60 + Owner: Greece + Jail2: prison + Location: 57,67 + Owner: Greece Smudges: @@ -1418,10 +1425,33 @@ Rules: CaptureTypes: building RenderInfantry: Image: E6 - E7: + Cloak@JAIL: + UpgradeTypes: jail + UpgradeMinEnabledLevel: 1 + InitialDelay: 0 + CloakDelay: 0 + Palette: + MEDI: + Cloak@JAIL: + UpgradeTypes: jail + UpgradeMinEnabledLevel: 1 + InitialDelay: 0 + CloakDelay: 0 + Palette: + E7.noautotarget: + Inherits: E7 + RenderInfantry: + Image: E7 AutoTarget: EnableStances: false -AttackMove: + PRISON: + Immobile: + OccupiesSpace: false + BodyOrientation: + UpgradeActorsNear: + Upgrades: jail + Range: 1c0 CAMERA: RevealsShroud: Range: 8c7 @@ -1434,24 +1464,6 @@ Rules: Name: Crate WithCrateBody: Images: scrate - PE6: - Inherits: E6 - -RepairsBridges: - -ExternalCaptures: - Captures: - CaptureTypes: building - RejectsOrders: - AutoTargetIgnore: - -Huntable: - RenderInfantry: - Image: e6 - PMEDI: - Inherits: MEDI - RejectsOrders: - AutoTargetIgnore: - -Huntable: - RenderInfantry: - Image: medi E1.Autotarget: Inherits: E1 Buildable: @@ -1473,8 +1485,6 @@ Rules: RenderInfantry: Image: E2 DOG: - Buildable: - Prerequisites: ~disabled RevealsShroud: Range: 9c0 AutoTarget: