Permalink
Browse files

Fix cam3-b mission victory.

Make sure Gamma base is considered an enemy so that the base detects
structures properly.

The mock battle can last longer and the first land reinforcement queue
now is five minutes. New factory assembly positions from alfred007.
  • Loading branch information...
KJeff01 committed Jan 3, 2018
1 parent beba57f commit 8e053d20c7c2057503c4cc8fc57c834839c6d14f
Showing with 31 additions and 14 deletions.
  1. +6 −1 data/base/script/campaign/cam2-b.js
  2. +23 −11 data/base/script/campaign/cam3-b.js
  3. +2 −2 data/base/wrf/cam3/cam3b/labels.json
@@ -80,7 +80,12 @@ function vtolAttack()
"vtolAppearPosW",
"vtolAppearPosN",
];
camSetVtolData(THE_COLLECTIVE, POSITIONS, "vtolRemove", list, camChangeOnDiff(300000), "COCommandCenter"); //5 min
var ext = {
limit: [4, 4], //paired with list array
alternate: true,
altIdx: 0
};
camSetVtolData(THE_COLLECTIVE, POSITIONS, "vtolRemove", list, camChangeOnDiff(300000), "COCommandCenter", ext); //5 min
}
function truckDefense()
@@ -3,6 +3,7 @@ include("script/campaign/templates.js");
include("script/campaign/transitionTech.js");
var trapActive;
var gammaAttackCount;
const GAMMA = 1; // Player 1 is Gamma team.
const NEXUS_RES = [
"R-Defense-WallUpgrade08", "R-Struc-Materials08", "R-Struc-Factory-Upgrade06",
@@ -106,15 +107,18 @@ function sendNXTransporter()
pos = "nexusWestTransportPos";
}
camSendReinforcement(NEXUS, camMakePos(pos), list,
CAM_REINFORCE_TRANSPORT, {
message: LZ_ALIAS + lzNum,
entry: { x: 63, y: 4 },
exit: { x: 63, y: 4 }
}
);
queue("sendNXTransporter", camChangeOnDiff(180000)); //3 min
if (camDef(pos))
{
camSendReinforcement(NEXUS, camMakePos(pos), list,
CAM_REINFORCE_TRANSPORT, {
message: LZ_ALIAS + lzNum,
entry: { x: 63, y: 4 },
exit: { x: 63, y: 4 }
}
);
queue("sendNXTransporter", camChangeOnDiff(180000)); //3 min
}
}
//Send Nexus land units
@@ -203,7 +207,7 @@ function trapSprung()
camCallOnce("activateNexusGroups");
enableAllFactories();
queue("sendNXlandReinforcements", camChangeOnDiff(240000)); // 4 min
queue("sendNXlandReinforcements", camChangeOnDiff(300000)); //5 min
sendNXTransporter();
changePlayerColour(GAMMA, NEXUS); // Black painting.
playSound(SYNAPTICS_ACTIVATED);
@@ -216,15 +220,21 @@ function setupCapture()
function eventAttacked(victim, attacker)
{
if (!trapActive && victim.player === GAMMA)
if (!trapActive && gammaAttackCount > 4)
{
camCallOnce("setupCapture");
}
if (victim.player === GAMMA && attacker.player === NEXUS)
{
gammaAttackCount = gammaAttackCount + 1;
}
}
function eventStartLevel()
{
trapActive = false;
gammaAttackCount = 0;
const MISSION_TIME = camChangeOnDiff(1200); //20 minutes. Rescue part.
var startpos = getObject("startPosition");
var lz = getObject("landingZone");
@@ -242,6 +252,7 @@ function eventStartLevel()
camCompleteRequiredResearch(GAMMA_ALLY_RES, GAMMA);
camCompleteRequiredResearch(NEXUS_RES, GAMMA); //They get even more research.
setAlliance(GAMMA, CAM_HUMAN_PLAYER, false);
setAlliance(GAMMA, NEXUS, true);
camSetArtifacts({
@@ -305,6 +316,7 @@ function eventStartLevel()
camPlayVideos(["MB3_B_MSG", "MB3_B_MSG2"]);
changePlayerColour(GAMMA, 0);
setAlliance(GAMMA, CAM_HUMAN_PLAYER, true);
queue("transferPower", 3000);
queue("vtolAttack", camChangeOnDiff(300000)); //5 min
@@ -77,11 +77,11 @@
},
"position_19": {
"label": "gammaFactoryAssembly",
"pos": [1216, 2112]
"pos": [1472, 2112]
},
"position_20": {
"label": "gammaCyborgFactoryAssembly",
"pos": [1856, 2112]
"pos": [2112, 2112]
},
"area_0": {

0 comments on commit 8e053d2

Please sign in to comment.