X-Git-Url: http://git.xonotic.org/?a=blobdiff_plain;ds=sidebyside;f=qcsrc%2Fserver%2Fsv_main.qc;h=538dcc62c624b173caa59b1ff53686a39dd50109;hb=0ab9d7c6bef3e848b1d2fed20674a1a8aabd15e4;hp=007c6369ede68e3e5239d1b774076b1cf65e3840;hpb=fbec7533403217021a56aad87aae328283178c0f;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/server/sv_main.qc b/qcsrc/server/sv_main.qc index 007c6369e..538dcc62c 100644 --- a/qcsrc/server/sv_main.qc +++ b/qcsrc/server/sv_main.qc @@ -43,7 +43,18 @@ void CreatureFrame (void) { self.dmgtime = time + autocvar_g_balance_contents_damagerate; - if (!projectile) + if (projectile) + { + if (self.watertype == CONTENT_LAVA) + { + Damage (self, world, world, autocvar_g_balance_contents_projectiledamage * autocvar_g_balance_contents_damagerate * self.waterlevel, DEATH_LAVA, self.origin, '0 0 0'); + } + else if (self.watertype == CONTENT_SLIME) + { + Damage (self, world, world, autocvar_g_balance_contents_projectiledamage * autocvar_g_balance_contents_damagerate * self.waterlevel, DEATH_SLIME, self.origin, '0 0 0'); + } + } + else { if (self.watertype == CONTENT_LAVA) { @@ -64,10 +75,6 @@ void CreatureFrame (void) Damage (self, world, world, autocvar_g_balance_contents_playerdamage_slime * autocvar_g_balance_contents_damagerate * self.waterlevel, DEATH_SLIME, self.origin, '0 0 0'); } } - else if ((self.watertype == CONTENT_LAVA) || (self.watertype == CONTENT_SLIME)) - { - Damage (self, world, world, autocvar_g_balance_contents_projectiledamage * autocvar_g_balance_contents_damagerate * self.waterlevel, DEATH_SLIME, self.origin, '0 0 0'); - } } } else @@ -146,7 +153,6 @@ Called before each frame by the server float game_delay; float game_delay_last; -void RuneMatchGivePoints(); float RedirectionThink(); entity SelectSpawnPoint (float anypoint); void StartFrame (void) @@ -169,9 +175,9 @@ void StartFrame (void) c_seen = 0; FOR_EACH_CLIENT(cl) { - if(clienttype(cl) == CLIENTTYPE_REAL) + if(IS_REAL_CLIENT(cl)) ++c_seeing; - if(cl.classname == "player") + if(IS_PLAYER(cl)) ++c_seen; } print("CEFC calls per second: ", ftos(c_seeing * (c_seen - 1) / t), "; "); @@ -203,19 +209,13 @@ void StartFrame (void) skill = autocvar_skill; - count_players(); - if(g_ca || g_freezetag) - count_alive_players(); - Arena_Warmup(); - Spawnqueue_Check(); - // detect when the pre-game countdown (if any) has ended and the game has started game_delay = (time < game_starttime) ? TRUE : FALSE; if(game_delay_last == TRUE) if(game_delay == FALSE) if(autocvar_sv_eventlog) - GameLogEcho(":startdelay_ended"); + GameLogEcho(":startdelay_ended"); game_delay_last = game_delay; @@ -231,9 +231,6 @@ void StartFrame (void) CreatureFrame (); CheckRules_World (); - AuditTeams(); - - RuneMatchGivePoints(); bot_serverframe(); FOR_EACH_PLAYER(self)