From: Florian Paul Schmidt Date: Sun, 21 Mar 2010 15:34:03 +0000 (+0100) Subject: DODGING: adjust defaults to make more sense with tracebox X-Git-Tag: xonotic-v0.1.0preview~680^2~7 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=0fe40598c616fa8348bc4ecb7db4c3d5a92da3f8;p=xonotic%2Fxonotic-data.pk3dir.git DODGING: adjust defaults to make more sense with tracebox DODGING: use tracebox instead of traceline --- diff --git a/defaultXonotic.cfg b/defaultXonotic.cfg index 94450522c..9b2d45be7 100644 --- a/defaultXonotic.cfg +++ b/defaultXonotic.cfg @@ -521,8 +521,8 @@ set sv_dodging_delay 0.5 "determines how long a player has to wait to be able to set sv_dodging_up_speed 200 "the jump velocity of the dodge" set sv_dodging_horiz_speed 350 "the horizontal velocity of the dodge" set sv_dodging_ramp_time 0.1 "a ramp so that the horizontal part of the dodge is added smoothly (seconds)" -set sv_dodging_height_threshold 40 "the maximum height above ground where to allow dodging" -set sv_dodging_wall_distance_threshold 40 "the maximum distance from a wall that still allows dodging" +set sv_dodging_height_threshold 10 "the maximum height above ground where to allow dodging" +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 leadlimit 0 diff --git a/qcsrc/server/mutators/mutator_dodging.qc b/qcsrc/server/mutators/mutator_dodging.qc index 6f2fe557c..4b3111634 100644 --- a/qcsrc/server/mutators/mutator_dodging.qc +++ b/qcsrc/server/mutators/mutator_dodging.qc @@ -113,26 +113,22 @@ float check_close_to_wall(float threshold) { trace_end = self.origin + (1000*v_right); - traceline(trace_start, trace_end, TRUE, self); - + tracebox(trace_start, self.mins, self.maxs, trace_end, TRUE, self); if (trace_fraction < 1 && vlen (self.origin - trace_endpos) < threshold) return 1; trace_end = self.origin - (1000*v_right); - traceline(trace_start, trace_end, TRUE, self); - + tracebox(trace_start, self.mins, self.maxs, trace_end, TRUE, self); if (trace_fraction < 1 && vlen (self.origin - trace_endpos) < threshold) return 1; trace_end = self.origin + (1000*v_forward); - traceline(trace_start, trace_end, TRUE, self); - + tracebox(trace_start, self.mins, self.maxs, trace_end, TRUE, self); if (trace_fraction < 1 && vlen (self.origin - trace_endpos) < threshold) return 1; trace_end = self.origin - (1000*v_forward); - traceline(trace_start, trace_end, TRUE, self); - + tracebox(trace_start, self.mins, self.maxs, trace_end, TRUE, self); if (trace_fraction < 1 && vlen (self.origin - trace_endpos) < threshold) return 1; @@ -165,7 +161,7 @@ MUTATOR_HOOKFUNCTION(dodging_GetPressedKeys) { trace_start = self.origin; trace_end = self.origin - (1000*v_up); - traceline(trace_start, trace_end, TRUE, self); + tracebox(trace_start, self.mins, self.maxs, trace_end, TRUE, self); // check if the trace hit anything at all if (trace_fraction > 1)