Skip to content

Commit

Permalink
Merge pull request #20 from DARwins1/v2.4.1
Browse files Browse the repository at this point in the history
V2.4.1
  • Loading branch information
DARwins1 authored Nov 3, 2021
2 parents b3cfdee + 09a9dd4 commit 2ac4d58
Show file tree
Hide file tree
Showing 6 changed files with 67 additions and 24 deletions.
23 changes: 22 additions & 1 deletion Changelog.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,26 @@
Changelog:

Refactored v2.4.1

Just a small patch that tweaks a few levels.

Changes:
- Changed the Intelligence Display entry for NEXUS Resistance Circuits to not mention protection for Hero ranked units (since they're already protected by default)

Level Specific Changes:
Alpha 5 (First NP Encounter)
- Flamers now spawn among NP reinforcements on Insane difficulty.
Alpha 8 (Synaptic Link)
- Updated level scripts, and fixed a small bug.
Gamma 3 (Gamma Base Rescue)
- That truck added from the last update now builds Ground Shakers for realsies.
Gamma Final
- Fixed NEXUS trucks building non-NEXUS sensor towers.
- Tweaked NEXUS' super-special-suprise-birthday-party attack:
- The initial absorption attack is now twice as likely to convert, but will only affect structures.
- Player VTOL's are now only insta-KO'd on Hard/Insane.


Refactored v2.4.0

Hurray for Warzone 2100 4.2.0!
Expand All @@ -10,7 +31,7 @@ Changes:
- Behind the scenes script tweaking to get stuff up to video functions up to standard.

Level Specific Changes:
Alpha Final:
Alpha Final
- NP hover units use new patrol scheme from standard camBalance.
Some Beta missions
- Tweaked with Collective truck build times.
Expand Down
2 changes: 1 addition & 1 deletion messages/resmessages3.json
Original file line number Diff line number Diff line change
Expand Up @@ -491,7 +491,7 @@
"Computer Technology Breakthrough",
"Improved NEXUS resistance circuitry",
"Reduced chance of NEXUS take-over",
"Hero and Special rank units are protected"
"Special rank units are protected"
]
},
"RES_SY_RESU3": {
Expand Down
2 changes: 1 addition & 1 deletion script/campaign/cam1-3.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ function NPReinforce()
{
var list = [];
var count = 5 + camRand(5);
var scouts = [cTempl.nphmg, cTempl.npblc, cTempl.nppod, cTempl.nphmg, cTempl.npblc];
var scouts = [cTempl.nphmg, cTempl.npflam, cTempl.nppod, cTempl.nphmg, cTempl.npflam];

for (var i = 0; i < count; ++i)
{
Expand Down
48 changes: 33 additions & 15 deletions script/campaign/cam1-5.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,26 +15,43 @@ const SCAVENGER_RES = [
"R-Wpn-MG-Damage03", "R-Wpn-Rocket-Damage02", "R-Wpn-Cannon-Damage02",
];

var useHeavyReinforcement;

//Get some droids for the New Paradigm transport
function getDroidsForNPLZ(args)
{
var scouts = [ cTempl.npsens, cTempl.nppod, cTempl.nphmg ];
var heavies = [ cTempl.npsbb, cTempl.npmmct, cTempl.npmrl ];

var numScouts = camRand(5) + 1;
var heavy = heavies[camRand(heavies.length)];
const LIGHT_ATTACKER_LIMIT = 8;
const HEAVY_ATTACKER_LIMIT = 3;
var unitTemplates;
var list = [];

for (var i = 0; i < numScouts; ++i)
if (useHeavyReinforcement)
{
var artillery = [cTempl.npmor];
var other = [cTempl.npmmct];
if (camRand(2) > 0)
{
//Add a sensor if artillery was chosen for the heavy units
list.push(cTempl.npsens);
unitTemplates = artillery;
}
else
{
unitTemplates = other;
}
}
else
{
list[list.length] = scouts[camRand(scouts.length)];
unitTemplates = [cTempl.nppod, cTempl.npmrl, cTempl.npsmc];
}

for (var a = numScouts; a < 8; ++a)
var lim = useHeavyReinforcement ? HEAVY_ATTACKER_LIMIT : LIGHT_ATTACKER_LIMIT;
for (var i = 0; i < lim; ++i)
{
list[list.length] = heavy;
list.push(unitTemplates[camRand(unitTemplates.length)]);
}

useHeavyReinforcement = !useHeavyReinforcement; //switch it
return list;
}

Expand Down Expand Up @@ -74,14 +91,15 @@ camAreaEvent("NPFactoryTrigger", function(droid)
//Land New Paradigm transport in the LZ area (protected by four hardpoints in the New Paradigm base)
camAreaEvent("NPLZTrigger", function()
{
sendNPTransport();
setTimer("sendNPTransport", camChangeOnDiff(camMinutesToMilliseconds(3)));
sendNPTransport();
});

function sendNPTransport()
{
var tPos = getObject("NPTransportPos");
var nearbyDefense = enumRange(tPos.x, tPos.y, 6, NEW_PARADIGM, false);
var nearbyDefense = enumArea("LandingZone2", NEW_PARADIGM, false).filter(function(obj) {
return (obj.type === STRUCTURE && obj.stattype === DEFENSE);
});

if (nearbyDefense.length > 0)
{
Expand Down Expand Up @@ -136,6 +154,7 @@ function eventStartLevel()
annihilate: true
});

useHeavyReinforcement = false; //Start with a light unit reinforcement first
var lz = getObject("LandingZone1"); //player lz
var lz2 = getObject("LandingZone2"); //new paradigm lz
var tent = getObject("TransporterEntry");
Expand All @@ -155,7 +174,6 @@ function eventStartLevel()
camCompleteRequiredResearch(NEW_PARADIGM_RES, NEW_PARADIGM);
camCompleteRequiredResearch(SCAVENGER_RES, SCAV_7);


camSetEnemyBases({
"ScavNorthGroup": {
cleanup: "ScavNorth",
Expand Down Expand Up @@ -197,7 +215,7 @@ function eventStartLevel()
order: CAM_ORDER_ATTACK,
groupSize: 4,
throttle: camChangeOnDiff(camSecondsToMilliseconds(40)),
templates: [ cTempl.npmrl, cTempl.npmmct, cTempl.npsbb, cTempl.nphmg, cTempl.npflam ],
templates: [ cTempl.npmrl, cTempl.npmmct, cTempl.npsmc, cTempl.nppod ],
data: {
regroup: false,
repair: 40,
Expand All @@ -209,7 +227,7 @@ function eventStartLevel()
order: CAM_ORDER_ATTACK,
groupSize: 4,
throttle: camChangeOnDiff(camSecondsToMilliseconds(50)),
templates: [ cTempl.npmor, cTempl.npsens, cTempl.npsbb, cTempl.nphmg, cTempl.npflam ],
templates: [ cTempl.npmor, cTempl.npsens, cTempl.npsmc, cTempl.npflam ],
data: {
regroup: false,
repair: 40,
Expand Down
14 changes: 9 additions & 5 deletions script/campaign/cam3-4.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,15 +59,19 @@ function firstAbsorbAttack()
for (var i = 0, len = objects.length; i < len; ++i)
{
var obj = objects[i];
//Destroy all the VTOLs to prevent a player from instantly defeating the HQ in a rush.
if (obj.type === DROID && isVTOL(obj))
//Destroy all the VTOLs to prevent a player from instantly defeating the HQ in a rush. (Only on Hard+)
if (obj.type === DROID && isVTOL(obj) && (difficulty >= HARD))
{
camSafeRemoveObject(obj, true);
continue;
}
if ((camRand(100) < 10) && !donateObject(obj, NEXUS))
//Absorb some structures from the player
if (obj.type === STRUCTURE)
{
camSafeRemoveObject(obj, true);
if ((camRand(100) < 20) && !donateObject(obj, NEXUS))
{
camSafeRemoveObject(obj, true);
}
}
}
}
Expand Down Expand Up @@ -163,7 +167,7 @@ function truckDefense()
var list = [
"Sys-NEXUSLinkTOW", "P0-AASite-SAM2", "Emplacement-PrisLas",
"NX-Tower-ATMiss", "Sys-NX-CBTower", "Emplacement-HvART-pit",
"Sys-SensoTower02"
"Sys-NX-SensorTower"
];

for (var i = 0; i < truckNum; ++i)
Expand Down
2 changes: 1 addition & 1 deletion script/campaign/cam3-b.js
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ function truckDefense()
return;
}

var list = ["Emplacement-Howitzer105", "Emplacement-HvART-pit", "Emplacement-RotHow"];
var list = ["Emplacement-Howitzer150", "Emplacement-HvART-pit", "Emplacement-RotHow"];
var position;

if (truckLocCounter === 0)
Expand Down

0 comments on commit 2ac4d58

Please sign in to comment.