About the secret level fart sound: rather than replacing the actors per level, it'd be better to introduce a feature to replace sounds per level.
Or, once you get an ACS VM, use a script like this:
Code: Select all
script "A_DeathScream" (void) // Death scream
{
bool secretlevel = false;
if (Level == 19 || Level == 20 || (Level == 10 && !GAME_SOD))
secretlevel = true;
if (secretlevel && (rnd_table[Random(0,255)] == 0))
{
SetResultValue(true);
// FormGen didn't have enough humor to have deathfarts.
// So this could check for a level above 200 and then
// use GUARDSCREAM6 instead. Which is the gunbat's death.
ActivatorSound("DEATHSCREAM6", 127);
} else SetResultValue(false);
}
with DECORATE code kinda like that:
Code: Select all
Death:
WBRN J 5 ACS_NamedExecuteAlways("PlaceItemType", 0, ITEM_CLIP)
WBRN K 0 A_JumpIf(CallACS("A_DeathScream"), 2)
WBRN K 0 A_Scream
WBRN K 5
WBRN L 5
WBRN M 5 A_GiveToTarget("Points", 100)
WBRN N -1 // A_NoBlocking
Stop
The simplest, closest to the original idea, method would be to add a "SecretDeathSound" actor property and have the DeathScream function use that one, if defined, when on a secret level.