Initial commit: OpenRA game engine
Some checks failed
Continuous Integration / Linux (.NET 8.0) (push) Has been cancelled
Continuous Integration / Windows (.NET 8.0) (push) Has been cancelled

Fork from OpenRA/OpenRA with one-click launch script (start-ra.cmd)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
let5sne.win10
2026-01-10 21:46:54 +08:00
commit 9cf6ebb986
4065 changed files with 635973 additions and 0 deletions

Binary file not shown.

View File

@@ -0,0 +1,5 @@
## rules.yaml
briefing =
Tomorrow, the attack on Germany begins, but today, we must protect our facility from Allied attacks.
Keep the Command Center intact at all costs, and destroy any Allied fortifications you might find.

Binary file not shown.

After

Width:  |  Height:  |  Size: 23 KiB

View File

@@ -0,0 +1,516 @@
MapFormat: 12
RequiresMod: ra
Title: 02a: The Thin Red Line
Author: Westwood Studios
Tileset: TEMPERAT
MapSize: 128,128
Bounds: 36,38,50,40
Visibility: MissionSelector
Categories: Campaign
LockPreview: True
Players:
PlayerReference@USSR:
Name: USSR
Playable: True
AllowBots: False
Required: True
LockFaction: True
Faction: soviet
LockColor: True
Color: FE1100
LockSpawn: True
LockTeam: True
Enemies: Greece
PlayerReference@Greece:
Name: Greece
Faction: allies
Color: E2E6F5
Enemies: USSR
Bot: campaign
PlayerReference@Neutral:
Name: Neutral
OwnsWorld: True
NonCombatant: True
Faction: allies
Actors:
Actor0: t02
Location: 37,45
Owner: Neutral
Actor1: t06
Location: 50,63
Owner: Neutral
Actor2: t06
Location: 59,71
Owner: Neutral
Actor3: tc01
Location: 52,76
Owner: Neutral
Actor4: tc01
Location: 37,66
Owner: Neutral
Actor5: tc03
Location: 37,65
Owner: Neutral
Actor6: t16
Location: 37,63
Owner: Neutral
Actor7: t12
Location: 37,70
Owner: Neutral
Actor8: t08
Location: 36,70
Owner: Neutral
Actor9: t07
Location: 36,68
Owner: Neutral
Actor10: tc04
Location: 40,74
Owner: Neutral
Actor11: tc05
Location: 42,69
Owner: Neutral
Actor12: t10
Location: 50,50
Owner: Neutral
Actor13: t17
Location: 68,47
Owner: Neutral
Actor14: t13
Location: 39,69
Owner: Neutral
Actor15: t01
Location: 69,60
Owner: Neutral
Actor16: t01
Location: 77,39
Owner: Neutral
Actor17: tc01
Location: 72,42
Owner: Neutral
Actor18: t15
Location: 76,64
Owner: Neutral
Actor19: t01
Location: 56,44
Owner: Neutral
Actor20: t03
Location: 61,41
Owner: Neutral
Actor21: t01
Location: 66,73
Owner: Neutral
Actor22: t02
Location: 66,71
Owner: Neutral
Actor23: t01
Location: 67,57
Owner: Neutral
Actor24: t05
Location: 69,51
Owner: Neutral
Actor25: tc03
Location: 47,48
Owner: Neutral
Actor26: t05
Location: 70,66
Owner: Neutral
Actor27: t01
Location: 59,51
Owner: Neutral
Actor28: t06
Location: 62,57
Owner: Neutral
Actor29: tc05
Location: 73,37
Owner: Neutral
Actor30: tc04
Location: 70,37
Owner: Neutral
Actor31: tc04
Location: 83,37
Owner: Neutral
Actor32: tc03
Location: 84,40
Owner: Neutral
Actor33: t17
Location: 82,39
Owner: Neutral
Actor34: fact
Location: 72,52
Owner: USSR
Actor35: weap
Location: 41,50
Owner: Greece
Actor37: fact
Location: 39,54
Owner: Greece
Actor39: powr
Location: 36,55
Owner: Greece
Actor40: powr
Location: 36,52
Owner: Greece
Tent: tent
Location: 41,58
Owner: Greece
Actor42: gun
Location: 39,61
Owner: Greece
Facing: 384
Actor44: powr
Location: 36,49
Owner: Greece
Actor45: gun
Location: 50,55
Owner: Greece
Facing: 384
Actor46: gun
Location: 50,59
Owner: Greece
Facing: 128
Actor47: brl3
Location: 38,48
Owner: Greece
Actor48: v19
Location: 39,48
Owner: Greece
Actor49: v19
Location: 40,46
Owner: Greece
Actor50: brl3
Location: 40,47
Owner: Greece
Actor51: barl
Location: 39,49
Owner: Greece
Actor52: brl3
Location: 40,48
Owner: Greece
Actor53: barl
Location: 38,49
Owner: Greece
Actor54: brl3
Location: 39,50
Owner: Greece
Actor55: barl
Location: 38,51
Owner: Greece
Actor56: barl
Location: 38,52
Owner: Greece
Actor57: brl3
Location: 39,53
Owner: Greece
Actor58: barl
Location: 38,54
Owner: Greece
Actor59: brl3
Location: 38,53
Owner: Greece
Actor60: brl3
Location: 41,45
Owner: Greece
Actor61: barl
Location: 41,46
Owner: Greece
Actor62: brl3
Location: 58,54
Owner: Greece
Actor63: v19
Location: 59,53
Owner: Greece
Actor64: barl
Location: 58,52
Owner: Greece
Actor66: barl
Location: 60,53
Owner: Greece
Actor67: brl3
Location: 58,53
Owner: Greece
Actor68: barl
Location: 59,51
Owner: Greece
Actor70: barl
Location: 60,59
Owner: Greece
Actor71: v19
Location: 61,59
Owner: Greece
Actor73: barl
Location: 60,61
Owner: Greece
Actor74: powr
Location: 79,52
Owner: USSR
Actor75: powr
Location: 82,52
Owner: USSR
Actor76: powr
Location: 83,56
Owner: USSR
Actor77: afld
Location: 79,56
Owner: USSR
Actor78: afld
Location: 75,56
Owner: USSR
Actor80: jeep
Location: 57,43
Owner: Greece
Facing: 384
Actor81: jeep
Location: 46,70
Owner: Greece
Facing: 384
Actor82: jeep
Location: 42,48
Owner: Greece
Facing: 128
Actor83: e1
Location: 70,52
Owner: USSR
Facing: 640
SubCell: 4
Actor84: e1
Location: 70,55
Owner: USSR
Facing: 768
SubCell: 3
Actor86: e1
Location: 44,67
Owner: Greece
Facing: 256
SubCell: 0
Actor87: e1
Location: 68,53
Owner: USSR
Facing: 768
SubCell: 2
Actor88: e1
Location: 69,54
Owner: USSR
Facing: 640
SubCell: 0
Actor89: e1
Location: 70,56
Owner: USSR
Facing: 640
SubCell: 4
Actor90: e1
Location: 69,57
Owner: USSR
Facing: 768
SubCell: 2
Actor91: e1
Location: 69,55
Owner: USSR
Facing: 640
SubCell: 3
Actor92: dog
Location: 77,58
Owner: USSR
Facing: 768
SubCell: 3
Actor93: dog
Location: 82,50
Owner: USSR
Facing: 768
SubCell: 0
Actor96: dog
Location: 73,50
Owner: USSR
Facing: 128
SubCell: 3
Actor97: dog
Location: 73,58
Owner: USSR
Facing: 640
SubCell: 1
Actor98: e3
Location: 47,44
Owner: Greece
Facing: 384
SubCell: 0
Actor99: e3
Location: 49,57
Owner: Greece
Facing: 256
SubCell: 1
Actor100: e3
Location: 44,49
Owner: Greece
Facing: 384
SubCell: 0
Actor101: e3
Location: 39,51
Owner: Greece
Facing: 384
SubCell: 4
Actor102: e3
Location: 43,60
Owner: Greece
Facing: 256
SubCell: 0
Actor103: e3
Location: 42,56
Owner: Greece
Facing: 256
SubCell: 3
Actor104: e1
Location: 48,43
Owner: Greece
Facing: 384
SubCell: 1
Actor113: e1
Location: 71,50
Owner: USSR
SubCell: 2
Actor114: e1
Location: 74,50
Owner: USSR
SubCell: 3
Actor121: fenc
Location: 68,59
Owner: USSR
Actor122: fenc
Location: 68,58
Owner: USSR
Actor123: fenc
Location: 68,57
Owner: USSR
Actor124: fenc
Location: 68,56
Owner: USSR
Actor125: fenc
Location: 68,52
Owner: USSR
Actor126: fenc
Location: 68,51
Owner: USSR
Actor127: fenc
Location: 70,51
Owner: USSR
Actor128: fenc
Location: 75,51
Owner: USSR
Actor129: fenc
Location: 76,51
Owner: USSR
Actor130: fenc
Location: 77,51
Owner: USSR
Actor131: fenc
Location: 78,51
Owner: USSR
Actor132: fenc
Location: 79,51
Owner: USSR
Actor133: fenc
Location: 69,51
Owner: USSR
CommandCenter: fcom
Location: 76,52
Owner: USSR
AlliedDome: dome
Location: 45,50
Owner: Greece
AlliedProc: proc
Location: 43,53
Owner: Greece
Barrel: brl3
Location: 60,60
Owner: Greece
BridgeBarrel1: brl3
Location: 61,58
Owner: Greece
BridgeBarrel2: brl3
Location: 59,54
Owner: Greece
Follower: e1
Location: 69,53
Owner: USSR
Facing: 640
SubCell: 2
Fleeing1: e1
Location: 62,52
Owner: Greece
Facing: 256
SubCell: 4
Fleeing2: e1
Location: 63,53
Owner: Greece
Facing: 256
SubCell: 4
Attacker1: e1
Location: 59,44
Owner: Greece
Facing: 384
SubCell: 4
Attacker2: e1
Location: 60,44
Owner: Greece
Facing: 256
SubCell: 1
Attacker3: e1
Location: 59,43
Owner: Greece
Facing: 256
SubCell: 4
Attacker4: e1
Location: 59,44
Owner: Greece
Facing: 256
SubCell: 1
Hunter1: e3
Location: 74,67
Owner: Greece
SubCell: 3
Hunter2: e1
Location: 73,68
Owner: Greece
SubCell: 3
Hunter3: e1
Location: 72,67
Owner: Greece
SubCell: 4
Hunter4: e1
Location: 54,74
Owner: Greece
SubCell: 2
CameraWaypoint: waypoint
Location: 68,54
Owner: Neutral
ParadropLZ: waypoint
Location: 45,43
Owner: Neutral
AttackWaypoint1: waypoint
Location: 73,49
Owner: Neutral
AttackWaypoint2: waypoint
Location: 73,76
Owner: Neutral
RifleRetreat: waypoint
Location: 57,59
Owner: Neutral
Box1: waypoint
Location: 66,53
Owner: Neutral
Box2: waypoint
Location: 42,59
Owner: Neutral
Rules: ra|rules/campaign-rules.yaml, ra|rules/campaign-tooltips.yaml, ra|rules/campaign-palettes.yaml, rules.yaml
FluentMessages: ra|fluent/lua.ftl, ra|fluent/campaign.ftl, map.ftl

View File

@@ -0,0 +1,93 @@
Player:
PlayerResources:
DefaultCash: 5000
World:
LuaScript:
Scripts: campaign.lua, utils.lua, soviet02a.lua
MissionData:
Briefing: briefing
BriefingVideo: soviet2.vqa
StartVideo: spotter.vqa
WinVideo: sovtstar.vqa
LossVideo: sovcemet.vqa
SPEN:
Buildable:
Prerequisites: ~disabled
DOME:
Buildable:
Prerequisites: ~disabled
WEAP:
Buildable:
Prerequisites: ~disabled
FIX:
Buildable:
Prerequisites: ~disabled
APWR:
Buildable:
Prerequisites: ~disabled
STEK:
Buildable:
Prerequisites: ~disabled
BRIK:
Buildable:
Prerequisites: ~disabled
TSLA:
Buildable:
Prerequisites: ~disabled
SAM:
Buildable:
Prerequisites: ~disabled
IRON:
Buildable:
Prerequisites: ~disabled
MSLO:
Buildable:
Prerequisites: ~disabled
E3:
Buildable:
Prerequisites: ~tent
E4:
Buildable:
Prerequisites: ~disabled
E6:
Buildable:
Prerequisites: ~disabled
SHOK:
Buildable:
Prerequisites: ~disabled
THF:
Buildable:
Prerequisites: ~disabled
MIG:
Buildable:
Prerequisites: ~disabled
AFLD:
Buildable:
Prerequisites: ~disabled
AirstrikePower@spyplane:
Prerequisites: ~disabled
ParatroopersPower@paratroopers:
Prerequisites: ~disabled
powerproxy.paratroopers:
ParatroopersPower:
DropItems: E2,E2,E2,E2,E2

View File

@@ -0,0 +1,166 @@
--[[
Copyright (c) The OpenRA Developers and Contributors
This file is part of OpenRA, which is free software. It is made
available to you under the terms of the GNU General Public License
as published by the Free Software Foundation, either version 3 of
the License, or (at your option) any later version. For more
information, see COPYING.
]]
CameraTriggerArea = { CPos.New(42, 45), CPos.New(43, 45), CPos.New(44, 45), CPos.New(45, 45), CPos.New(46, 45), CPos.New(47, 45), CPos.New(48, 45), CPos.New(48, 56), CPos.New(48, 57), CPos.New(48, 58), CPos.New(48, 59), CPos.New(40, 63), CPos.New(41, 63), CPos.New(42, 63), CPos.New(43, 63), CPos.New(44, 63), CPos.New(45, 63), CPos.New(46, 63), CPos.New(47, 63) }
PassingBridgeLocation = { CPos.New(59, 56), CPos.New(60, 56) }
CmdAtk = { Attacker1, Attacker2, Attacker3, Attacker4 }
FleeingUnits = { Fleeing1, Fleeing2 }
HuntingUnits = { Hunter1, Hunter2, Hunter3, Hunter4 }
AttackWaypoints = { AttackWaypoint1, AttackWaypoint2 }
AttackGroup = { }
AttackGroupSize = 3
AlliedInfantry = { "e1", "e1", "e3" }
SendAttackGroup = function()
if #AttackGroup < AttackGroupSize then
return
end
local way = Utils.Random(AttackWaypoints)
Utils.Do(AttackGroup, function(unit)
if not unit.IsDead then
unit.AttackMove(way.Location)
Trigger.OnIdle(unit, unit.Hunt)
end
end)
AttackGroup = { }
end
ProduceInfantry = function()
if Tent.IsDead then
return
end
Greece.Build({ Utils.Random(AlliedInfantry) }, function(units)
table.insert(AttackGroup, units[1])
SendAttackGroup()
Trigger.AfterDelay(DateTime.Seconds(10), ProduceInfantry)
end)
end
WorldLoaded = function()
USSR = Player.GetPlayer("USSR")
Greece = Player.GetPlayer("Greece")
InitObjectives(USSR)
CommandCenterIntact = AddPrimaryObjective(USSR, "protect-command-center")
DestroyAllAllied = AddPrimaryObjective(USSR, "destroy-allied-units-structures")
Camera.Position = CameraWaypoint.CenterPosition
Trigger.OnKilled(CommandCenter, function()
USSR.MarkFailedObjective(CommandCenterIntact)
end)
Trigger.AfterDelay(0, function()
local buildings = Utils.Where(Map.ActorsInWorld, function(self) return self.Owner == Greece and self.HasProperty("StartBuildingRepairs") end)
Utils.Do(buildings, function(actor)
Trigger.OnDamaged(actor, function(building, attacker)
if building.Owner == Greece and building.Health < building.MaxHealth * 0.8 then
building.StartBuildingRepairs()
if attacker.Type ~= "yak" and not AlreadyHunting then
AlreadyHunting = true
Utils.Do(Greece.GetGroundAttackers(), function(unit)
Trigger.OnIdle(unit, unit.Hunt)
end)
end
end
end)
end)
-- Find the bridge actors
BridgePart1 = Map.ActorsInBox(Box1.CenterPosition, Box2.CenterPosition, function(self) return self.Type == "br1" end)[1]
BridgePart2 = Map.ActorsInBox(Box1.CenterPosition, Box2.CenterPosition, function(self) return self.Type == "br2" end)[1]
end)
-- Discover the area around the bridge exposing the two german soldiers
-- When the two infantry near the bridge are discovered move them across the bridge to waypoint4
-- in the meanwhile one USSR soldier hunts them down
Trigger.AfterDelay(DateTime.Seconds(1), function()
Actor.Create("camera", true, { Owner = USSR, Location = Box1.Location })
Utils.Do(FleeingUnits, function(unit)
unit.Move(RifleRetreat.Location)
end)
Follower.AttackMove(RifleRetreat.Location)
end)
-- To make it look more smooth we will blow up the bridge when the barrel closest to it blows up
Trigger.OnAnyKilled({ BridgeBarrel1, BridgeBarrel2 }, function()
-- Destroy the bridge
if not BridgePart1.IsDead then
BridgePart1.Kill()
end
if not BridgePart2.IsDead then
BridgePart2.Kill()
end
end)
-- If player passes over the bridge, blow up the barrel and destroy the bridge
Trigger.OnEnteredFootprint(PassingBridgeLocation, function(unit, id)
if unit.Owner == USSR then
Trigger.RemoveFootprintTrigger(id)
-- Also don't if the bridge is already dead
if BridgePart1.IsDead and BridgePart2.IsDead then
return
end
-- Don't "shoot" at the barrels if there is no-one to shoot
if not FleeingUnits[1].IsDead then
FleeingUnits[1].Attack(Barrel, true, true)
elseif not FleeingUnits[2].IsDead then
FleeingUnits[2].Attack(Barrel, true, true)
end
end
end)
-- Four infantry from the small island move towards the USSR command center and attack it after 24 Seconds
Trigger.AfterDelay(DateTime.Seconds(24), function()
Utils.Do(CmdAtk, function(unit)
unit.AttackMove(AttackWaypoint1.Location)
Trigger.OnIdle(unit, unit.Hunt)
end)
end)
-- Start hunting
Hunter4.AttackMove(AttackWaypoint2.Location) -- Move the unit in the correct direction first
Utils.Do(HuntingUnits, function(unit)
Trigger.OnIdle(unit, unit.Hunt)
end)
-- When destroying the allied radar dome or the refinery drop 2 badgers with 5 grenadiers each
Trigger.OnAnyKilled({ AlliedDome, AlliedProc }, function()
local powerproxy = Actor.Create("powerproxy.paratroopers", true, { Owner = USSR })
powerproxy.TargetParatroopers(ParadropLZ.CenterPosition, Angle.South)
powerproxy.TargetParatroopers(ParadropLZ.CenterPosition, Angle.SouthEast)
powerproxy.Destroy()
end)
Greece.Resources = 2000
Trigger.AfterDelay(DateTime.Seconds(30), ProduceInfantry)
end
Tick = function()
if Greece.HasNoRequiredUnits() then
USSR.MarkCompletedObjective(CommandCenterIntact)
USSR.MarkCompletedObjective(DestroyAllAllied)
end
if USSR.HasNoRequiredUnits() then
USSR.MarkFailedObjective(DestroyAllAllied)
end
if Greece.Resources > Greece.ResourceCapacity / 2 then
Greece.Resources = Greece.ResourceCapacity / 2
end
end