Compat for Micro Slaughter Community Project MAP13 (excessive number of cell packs).
87 lines
2.9 KiB
Text
87 lines
2.9 KiB
Text
// level compatibility scripts
|
|
// sometimes shit breaks because of old and wrong scripting
|
|
// usually stuff that uses CheckInventory to look for keys, instead of, y'know,
|
|
// using ACS_LockedExecute
|
|
|
|
Class SWWMLevelCompatibility : LevelPostProcessor
|
|
{
|
|
protected void Apply( Name checksum, String mapname )
|
|
{
|
|
int numcol = 6;
|
|
switch ( checksum )
|
|
{
|
|
case 'none':
|
|
return;
|
|
// ZPack E1M2
|
|
case 'BA13454A41D931685B6A4B28E6946B6B':
|
|
// script uses checkinventory for red key
|
|
SetLineSpecial(225,ACS_LockedExecuteDoor,-Int('ZPACK_E1M2_SCRIPT6'),0,0,0,1);
|
|
SetLineSpecial(228,ACS_LockedExecuteDoor,-Int('ZPACK_E1M2_SCRIPT6'),0,0,0,1);
|
|
break;
|
|
// ZPack E3M2
|
|
case '17BD38E0B2FB8E760885FE46325DFF3A':
|
|
// script uses checkinventory for red skull
|
|
SetLineSpecial(5913,ACS_LockedExecute,-Int('ZPACK_E3M2_SCRIPT9'),0,0,0,4);
|
|
break;
|
|
// ZPack E3M8
|
|
case '13C5952A04014122271F50134DB4521F':
|
|
// script uses checkinventory for yellow skull
|
|
SetLineSpecial(22610,ACS_LockedExecute,-Int('ZPACK_E3M8_SCRIPT15'),0,0,0,6);
|
|
break;
|
|
// okuplok
|
|
case 'F7F353146676920238935A8D0D1B6E8E':
|
|
// add 7 more backpacks on top of existing one, for a full embiggening
|
|
// (players will need it)
|
|
for ( int i=0; i<7; i++ ) AddThing(8,(11808,-2016,384));
|
|
break;
|
|
// holy hell revealed
|
|
case '83569A062B5261C6BB4A034BA8245D24':
|
|
// remove boss brain and re-spawn it when end is reached, prevents cheesing the map with the ynykron
|
|
SetThingEdNum(50183,9001);
|
|
SetThingID(50183,666);
|
|
SetLineSpecial(21964,ACS_Execute,-Int('HHR_BRAINWALL'));
|
|
break;
|
|
// NRFTL MAP08
|
|
case '7EB864A03948C3F918F9223B2D1F8911':
|
|
// prevent easy cheesing of the exit teleporter
|
|
AddSectorTag(155,24);
|
|
OffsetSectorPlane(155,1,-80.);
|
|
SetLineSpecial(652,ACS_Execute,-Int('NERVE_EXITOPEN'));
|
|
break;
|
|
// Micro Slaughter Community Project MAP13
|
|
case 'E45AA3BE411845AA0DEE7CA5DAAB65FE':
|
|
// reduce OBSCENELY EXCESSIVE number of cell packs in voodoo doll conveyors (400), which will cause immense lag when replaced with mod ammo
|
|
// unsurprisingly, this actually makes the map go from completely unplayable to having perfectly smooth performance (gee, I wonder why)
|
|
int ncellsa = 0, ncellsb = 0;
|
|
for ( int i=0; i<GetThingCount(); i++ )
|
|
{
|
|
int tn = GetThingEdNum(i);
|
|
if ( tn != 17 ) continue;
|
|
Vector3 pos = GetThingPos(i);
|
|
if ( pos.y != 480. ) continue;
|
|
if ( pos.x == -5472. )
|
|
{
|
|
ncellsa++;
|
|
if ( ncellsa > 20 ) SetThingEdNum(i,0);
|
|
}
|
|
else if ( pos.x == -5344. )
|
|
{
|
|
ncellsb++;
|
|
if ( ncellsb > 20 ) SetThingEdNum(i,0);
|
|
}
|
|
}
|
|
break;
|
|
// Kinsie's Test Map (HERETIC)
|
|
case '0EADB2F82732A968B8513E4DC6138439':
|
|
numcol = 7;
|
|
// Kinsie's Test Map (HEXEN)
|
|
case 'D70250F93C6B6072DA39D9672B37F236':
|
|
numcol = 11;
|
|
// Kinsie's Test Map (DOOM)
|
|
case '959A613006CC3AA912C4A22908B7566A':
|
|
for ( int i=0; i<numcol; i++ )
|
|
AddThing(4206900+i,(1472+64*i,640,0));
|
|
break;
|
|
}
|
|
}
|
|
}
|