X-Git-Url: http://git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fserver%2Fg_world.qc;h=f635bff2a2f6399e209588a9487536201c340646;hb=4d88a13318f21331b958f0d7e374c132869a2b85;hp=b93d4f53d7aca7cdf52e922673067dd076cd3e90;hpb=9531e6a07b13cbccf27113f1dcb6e5ccacc6fbb4;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/server/g_world.qc b/qcsrc/server/g_world.qc index b93d4f53d..f635bff2a 100644 --- a/qcsrc/server/g_world.qc +++ b/qcsrc/server/g_world.qc @@ -253,7 +253,6 @@ void cvar_changes_init() // mapinfo BADCVAR("fraglimit"); - BADCVAR("g_arena"); BADCVAR("g_assault"); BADCVAR("g_ca"); BADCVAR("g_ca_teams"); @@ -304,7 +303,6 @@ void cvar_changes_init() // does nothing visible BADCVAR("captureleadlimit_override"); - BADCVAR("g_arena_point_leadlimit"); BADCVAR("g_balance_kill_delay"); BADCVAR("g_ca_point_leadlimit"); BADCVAR("g_ctf_captimerecord_always"); @@ -544,6 +542,7 @@ void spawnfunc___init_dedicated_server(void) // needs to be done so early because of the constants they create CALL_ACCUMULATED_FUNCTION(RegisterWeapons); + CALL_ACCUMULATED_FUNCTION(RegisterMonsters); CALL_ACCUMULATED_FUNCTION(RegisterGametypes); CALL_ACCUMULATED_FUNCTION(RegisterNotifications); CALL_ACCUMULATED_FUNCTION(RegisterDeathtypes); @@ -592,6 +591,7 @@ void spawnfunc_worldspawn (void) // needs to be done so early because of the constants they create CALL_ACCUMULATED_FUNCTION(RegisterWeapons); + CALL_ACCUMULATED_FUNCTION(RegisterMonsters); CALL_ACCUMULATED_FUNCTION(RegisterGametypes); CALL_ACCUMULATED_FUNCTION(RegisterNotifications); CALL_ACCUMULATED_FUNCTION(RegisterDeathtypes); @@ -804,6 +804,10 @@ void spawnfunc_worldspawn (void) addstat(STAT_SECRETS_TOTAL, AS_FLOAT, stat_secrets_total); addstat(STAT_SECRETS_FOUND, AS_FLOAT, stat_secrets_found); + // monsters + addstat(STAT_MONSTERS_TOTAL, AS_FLOAT, stat_monsters_total); + addstat(STAT_MONSTERS_KILLED, AS_FLOAT, stat_monsters_killed); + // misc addstat(STAT_RESPAWN_TIME, AS_FLOAT, stat_respawn_time); @@ -814,6 +818,7 @@ void spawnfunc_worldspawn (void) // set up information replies for clients and server to use maplist_reply = strzone(getmaplist()); lsmaps_reply = strzone(getlsmaps()); + monsterlist_reply = strzone(getmonsterlist()); for(i = 0; i < 10; ++i) { s = getrecords(i); @@ -1401,7 +1406,7 @@ void DumpStats(float final) { s = strcat(":player:see-labels:", GetPlayerScoreString(other, 0), ":"); s = strcat(s, ftos(rint(time - other.jointime)), ":"); - if(IS_PLAYER(other) || g_arena || other.caplayer == 1 || g_lms) + if(IS_PLAYER(other) || other.caplayer == 1 || g_lms) s = strcat(s, ftos(other.team), ":"); else s = strcat(s, "spectator:"); @@ -1571,7 +1576,7 @@ float InitiateSuddenDeath() // - for this timelimit_overtime needs to be >0 of course // - also check the winning condition calculated in the previous frame and only add normal overtime // again, if at the point at which timelimit would be extended again, still no winner was found - if (!autocvar_g_campaign && (checkrules_overtimesadded >= 0) && (checkrules_overtimesadded < autocvar_timelimit_overtimes) && autocvar_timelimit_overtime && !(g_race && !g_race_qualifying)) + if (!autocvar_g_campaign && (checkrules_overtimesadded >= 0) && (checkrules_overtimesadded < autocvar_timelimit_overtimes || autocvar_timelimit_overtimes < 0) && autocvar_timelimit_overtime && !(g_race && !g_race_qualifying)) { return 1; // need to call InitiateOvertime later } @@ -1855,7 +1860,7 @@ float WinningCondition_Scores(float limit, float leadlimit) if(WinningConditionHelper_zeroisworst) leadlimit = 0; // not supported in this mode - if(g_dm || g_tdm || g_arena || g_ca || (g_race && !g_race_qualifying) || g_nexball) + if(g_dm || g_tdm || g_ca || g_freezetag || (g_race && !g_race_qualifying) || g_nexball) // these modes always score in increments of 1, thus this makes sense { if(leaderfrags != WinningConditionHelper_topscore) @@ -2725,6 +2730,8 @@ string GotoMap(string m) void EndFrame() { + anticheat_endframe(); + float altime; FOR_EACH_REALCLIENT(self) {