From: Samual Lenks Date: Tue, 14 May 2013 02:20:41 +0000 (-0400) Subject: Update the server side cvar, fix something X-Git-Tag: xonotic-v0.7.0~50^2~1 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=593a99515fdaa0f534b0b5e7946c15cff0b46920;p=xonotic%2Fxonotic-data.pk3dir.git Update the server side cvar, fix something --- diff --git a/defaultXonotic.cfg b/defaultXonotic.cfg index 9bbc16b81..9af7a1f86 100644 --- a/defaultXonotic.cfg +++ b/defaultXonotic.cfg @@ -390,7 +390,6 @@ set g_weaponarena_random "0" "if set to a number, only that weapon count is give set g_weaponarena_random_with_laser "1" "additionally, always provide the laser in random weapon arena games" set g_midair 0 "if set to 1 you can only apply damage to your opponent while he is airborne" set g_midair_shieldtime 0.3 "number of seconds you are still invincible since you lost contact to the ground" -set g_spawnsound 1 "set to 0 if you don't want to hear the spawn sound when a player spawns" set g_spawnpoints_auto_move_out_of_solid 0 "if set to 1 you will see a warning if a spawn point was placed inside a solid" set g_forced_respawn 0 "if set to 1 and a player died, that player gets automatically respawned once seconds are over" set g_fullbrightplayers 0 "brightens up player models (note that the color, skin or model of the players does not change!)" @@ -469,6 +468,7 @@ set sv_dodging_height_threshold 10 "the maximum height above ground where to all set sv_dodging_wall_distance_threshold 10 "the maximum distance from a wall that still allows dodging" set sv_dodging_sound 1 "if 1 dodging makes a sound. if 0 dodging is silent" +set g_spawn_alloweffects 1 "allow clients to enable spawn point and event effects such as particles and sounds, see cl_spawn_ cvars for more info" set g_spawn_furthest 1 "this amount of the spawns shall be far away from any players" set g_spawn_useallspawns 0 "use all spawns, e.g. also team spawns in non-teamplay, and all spawns, even enemy spawns, in teamplay" set g_spawn_near_teammate 0 "if set, players prefer spawns near a team mate" diff --git a/qcsrc/client/Main.qc b/qcsrc/client/Main.qc index c4dec4c55..fb3106c29 100644 --- a/qcsrc/client/Main.qc +++ b/qcsrc/client/Main.qc @@ -707,12 +707,12 @@ void Ent_ReadSpawnPoint(float is_new) // entity for spawnpoint self.origin_x = ReadShort(); self.origin_y = ReadShort(); self.origin_z = ReadShort(); - - setsize(self, PL_MIN, PL_MAX); - droptofloor(); if(is_new) { + setsize(self, PL_MIN, PL_MAX); + droptofloor(); + if(autocvar_cl_spawn_point_particles) { switch(teamnum) @@ -737,7 +737,7 @@ void Ent_ReadSpawnPoint(float is_new) // entity for spawnpoint }*/ } - print(sprintf("Ent_ReadSpawnPoint(is_new = %d); origin = %s, team = %d, effect = %d\n", is_new, vtos(self.origin), teamnum, self.cnt)); + //print(sprintf("Ent_ReadSpawnPoint(is_new = %d); origin = %s, team = %d, effect = %d\n", is_new, vtos(self.origin), teamnum, self.cnt)); } void Ent_ReadSpawnEvent(float is_new) @@ -788,7 +788,7 @@ void Ent_ReadSpawnEvent(float is_new) } } - print(sprintf("Ent_ReadSpawnEvent(is_new = %d); origin = %s, entnum = %d, localentnum = %d\n", is_new, vtos(self.origin), entnum, player_localentnum)); + //print(sprintf("Ent_ReadSpawnEvent(is_new = %d); origin = %s, entnum = %d, localentnum = %d\n", is_new, vtos(self.origin), entnum, player_localentnum)); } // CSQC_Ent_Update : Called every frame that the server has indicated an update to the SSQC / CSQC entity has occured. diff --git a/qcsrc/server/autocvars.qh b/qcsrc/server/autocvars.qh index d1603c0af..91b891686 100644 --- a/qcsrc/server/autocvars.qh +++ b/qcsrc/server/autocvars.qh @@ -971,11 +971,11 @@ float autocvar_g_shootfromclient; float autocvar_g_shootfromeye; string autocvar_g_shootfromfixedorigin; float autocvar_g_showweaponspawns; +float autocvar_g_spawn_alloweffects; float autocvar_g_spawn_furthest; float autocvar_g_spawn_useallspawns; float autocvar_g_spawnpoints_auto_move_out_of_solid; #define autocvar_g_spawnshieldtime cvar("g_spawnshieldtime") -float autocvar_g_spawnsound; #define autocvar_g_start_weapon_laser cvar("g_start_weapon_laser") float autocvar_g_tdm_team_spawns; float autocvar_g_tdm_teams; diff --git a/qcsrc/server/spawnpoints.qc b/qcsrc/server/spawnpoints.qc index bf1a49a9f..a5bd4ee57 100644 --- a/qcsrc/server/spawnpoints.qc +++ b/qcsrc/server/spawnpoints.qc @@ -16,7 +16,7 @@ float SpawnEvent_Send(entity to, float sf) WriteByte(MSG_ENTITY, ENT_CLIENT_SPAWNEVENT); - if(autocvar_g_spawnsound) + if(autocvar_g_spawn_alloweffects) { WriteByte(MSG_ENTITY, num_for_edict(self.owner)); WriteShort(MSG_ENTITY, self.owner.origin_x);