Name | Author | Game Mode | Rating | |||||
---|---|---|---|---|---|---|---|---|
Two DOM mutators | Violet CLM | Mutator | N/A |
#pragma name "Proportionate DOM /maxscore"
#pragma description "Sets the maximum score for each level in Domination games to a number based directly on the number of control points in that level, so that all rounds last roughly the same length."
const uint MinimumMinutes = 3;
void onLevelBegin() {
if (!jjIsServer || jjGameCustom != GAME::DOM)
return;
uint controlPointCount = 0;
for (int x = jjLayerWidth[4]; --x >= 0;)
for (int y = jjLayerHeight[4]; --y >= 0;) {
const auto difficulty = jjParameterGet(x,y, -4, 2);
if (difficulty == 1 || difficulty == 2 || jjEventGet(x,y) == OBJECT::CTFBASE)
controlPointCount += 1;
}
if (controlPointCount != 0) {
const uint secondsPerScoreIncrement = ((controlPointCount + 3) / 4) * 5;
jjChat("/maxscore " + (MinimumMinutes * 60 * controlPointCount / secondsPerScoreIncrement));
}
}
Jazz2Online © 1999-INFINITY (Site Credits). We have a Privacy Policy. Jazz Jackrabbit, Jazz Jackrabbit 2, Jazz Jackrabbit Advance and all related trademarks and media are ™ and © Epic Games. Lori Jackrabbit is © Dean Dodrill. J2O development powered by Loops of Fury and Chemical Beats.
Eat your lima beans, Johnny.