X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fserver%2Fsv_main.qc;h=3a879952c9e86e8af73050b9f2f52bb1401877d8;hb=19908b418a17743f83666a6720a53ccafa6e61f8;hp=66579bc9c92807ef2cfc11cbf3164b47ee20c2e1;hpb=48a9eb74e54b8e703797522a2591c65d19596915;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/server/sv_main.qc b/qcsrc/server/sv_main.qc index 66579bc9c..3a879952c 100644 --- a/qcsrc/server/sv_main.qc +++ b/qcsrc/server/sv_main.qc @@ -10,6 +10,7 @@ void CreatureFrame (void) float vehic = (self.vehicle_flags & VHF_ISVEHICLE); float projectile = (self.flags & FL_PROJECTILE); + float monster = (self.flags & FL_MONSTER); if (self.watertype <= CONTENT_WATER && self.waterlevel > 0) // workaround a retarded bug made by id software :P (yes, it's that old of a bug) { @@ -19,7 +20,7 @@ void CreatureFrame (void) self.dmgtime = 0; } - if(!vehic && !projectile) // vehicles and projectiles don't drown + if(!vehic && !projectile && !monster) // vehicles, monsters and projectiles don't drown { if (self.waterlevel != WATERLEVEL_SUBMERGED) { @@ -43,7 +44,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 +76,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 +154,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) @@ -203,9 +210,12 @@ 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; @@ -228,9 +238,6 @@ void StartFrame (void) CreatureFrame (); CheckRules_World (); - AuditTeams(); - - RuneMatchGivePoints(); bot_serverframe(); FOR_EACH_PLAYER(self)