Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add money crates to GDI08a and GDI09 #17881

Merged
merged 5 commits into from Apr 17, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -85,10 +85,13 @@ void UnpackTileData(MemoryStream ms)
static string[] overlayActors = new string[]
{
// Fences
"sbag", "cycl", "brik", "fenc", "wood", "wood",
"sbag", "cycl", "brik", "fenc", "wood",

// Fields
"v12", "v13", "v14", "v15", "v16", "v17", "v18"
"v12", "v13", "v14", "v15", "v16", "v17", "v18",

// Crates
"wcrate", "scrate"
};

void UnpackOverlayData(MemoryStream ms)
Expand Down
Expand Up @@ -73,10 +73,13 @@ void UnpackTileData(Stream ms)
static string[] overlayActors = new string[]
{
// Fences
"sbag", "cycl", "brik", "fenc", "wood", "wood",
"sbag", "cycl", "brik", "fenc", "wood",

// Fields
"v12", "v13", "v14", "v15", "v16", "v17", "v18"
"v12", "v13", "v14", "v15", "v16", "v17", "v18",

// Crates
"wcrate", "scrate"
};

void ReadOverlay(IniFile file)
Expand Down Expand Up @@ -137,7 +140,7 @@ public override void LoadPlayer(IniFile file, string section)
faction = "gdi";
break;
case "BadGuy":
color = "red"; // TODO: use the grey unit color theme for missions
color = "red";
faction = "nod";
break;
case "Special":
Expand Down
3 changes: 3 additions & 0 deletions mods/cnc/maps/gdi04a/map.yaml
Expand Up @@ -405,6 +405,9 @@ Actors:
Owner: Nod
Facing: 192
SubCell: 3
Actor101: moneycrate
Location: 56,23
Owner: Neutral
HandOfNod: hand
Location: 30,53
Owner: Nod
Expand Down
2 changes: 0 additions & 2 deletions mods/cnc/maps/gdi05a/rules.yaml
Expand Up @@ -165,10 +165,8 @@ OBLI:
Prerequisites: ~disabled

MoneyCrate:
Inherits: ^Crate
GiveCashCrateAction:
Amount: 500
UseCashTick: true

airstrike.proxy:
AirstrikePower:
Expand Down
3 changes: 3 additions & 0 deletions mods/cnc/maps/gdi05b/map.yaml
Expand Up @@ -483,6 +483,9 @@ Actors:
Owner: Nod
Facing: 160
SubCell: 4
Actor167: moneycrate
Location: 26,42
Owner: Neutral
waypoint27: waypoint
Location: 32,41
Owner: Neutral
Expand Down
3 changes: 3 additions & 0 deletions mods/cnc/maps/gdi08a/map.yaml
Expand Up @@ -882,5 +882,8 @@ Actors:
waypoint0: waypoint
Location: 19,53
Owner: Neutral
Actor239: moneycrate
Owner: Neutral
Location: 5,42

Rules: cnc|rules/campaign-maprules.yaml, cnc|rules/campaign-tooltips.yaml, cnc|rules/campaign-palettes.yaml, rules.yaml
3 changes: 3 additions & 0 deletions mods/cnc/maps/gdi09/map.yaml
Expand Up @@ -776,6 +776,9 @@ Actors:
GDIHeliLZ: waypoint
Location: 41,44
Owner: Neutral
Actor224: moneycrate
Owner: Neutral
Location: 5,48

Rules: cnc|rules/campaign-maprules.yaml, cnc|rules/campaign-tooltips.yaml, cnc|rules/campaign-palettes.yaml, rules.yaml

Expand Down
4 changes: 4 additions & 0 deletions mods/cnc/maps/nod07a/nod07a.lua
Expand Up @@ -177,6 +177,10 @@ WorldLoaded = function()
EliminateGDI = Nod.AddObjective("Eliminate all GDI forces in the area.")
BuildSAMs = Nod.AddObjective("Build 3 SAMs to fend off the GDI bombers.", "Secondary", false)
GDIObjective = GDI.AddObjective("Eliminate all Nod forces in the area.")

Trigger.OnKilled(GDIProc, function()
Actor.Create("moneycrate", true, { Owner = GDI, Location = CPos.New(24, 54) })
end)
end

Tick = function()
Expand Down
6 changes: 0 additions & 6 deletions mods/cnc/maps/nod08a/rules.yaml
Expand Up @@ -156,12 +156,6 @@ FACTOUT.IN:
Capturable:
Types: building

MoneyCrate:
Inherits: ^Crate
GiveCashCrateAction:
Amount: 2000
UseCashTick: true

NUKEOUT.IN:
Inherits: NUKE
RenderSprites:
Expand Down
6 changes: 0 additions & 6 deletions mods/cnc/maps/nod08b/rules.yaml
Expand Up @@ -189,12 +189,6 @@ FACTOUT.IN:
Capturable:
Types: building

MoneyCrate:
Inherits: ^Crate
GiveCashCrateAction:
Amount: 2000
UseCashTick: true

NUKEOUT.IN:
Inherits: NUKE
RenderSprites:
Expand Down
3 changes: 3 additions & 0 deletions mods/cnc/maps/nod09/map.yaml
Expand Up @@ -696,6 +696,9 @@ Actors:
Location: 54,6
Facing: 92
TurretFacing: 92
Actor245: moneycrate
Location: 5,6
Owner: Neutral
waypoint27: waypoint
Location: 32,32
Owner: Neutral
Expand Down
11 changes: 11 additions & 0 deletions mods/cnc/rules/campaign-maprules.yaml
Expand Up @@ -63,6 +63,17 @@ airstrike.proxy:
CircleSequence: circles
SupportPowerPaletteOrder: 10

MoneyCrate:
Inherits: ^Crate
Tooltip:
Name: Money Crate
GiveCashCrateAction:
Amount: 2000
Sequence: dollar
UseCashTick: true
RenderSprites:
Image: wcrate

TRUCK:
Buildable:
Prerequisites: ~disabled
8 changes: 8 additions & 0 deletions mods/cnc/sequences/misc.yaml
Expand Up @@ -175,6 +175,14 @@ crate:
idle:
ZOffset: -511

scrate:
idle:
ZOffset: -511

wcrate:
idle:
ZOffset: -511

xcratea:
idle: xcrate
ZOffset: -511
Expand Down