From: Rudolf Polzer Date: Wed, 22 Oct 2014 09:37:36 +0000 (+0200) Subject: Remove COMPAT_XON010_CHANNELS. X-Git-Tag: xonotic-v0.8.0~177 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=f5991c3713189cd59fad4249bfada408e4bdfe32;p=xonotic%2Fxonotic-data.pk3dir.git Remove COMPAT_XON010_CHANNELS. --- diff --git a/qcsrc/common/constants.qh b/qcsrc/common/constants.qh index e02fad45f..d68e9005c 100644 --- a/qcsrc/common/constants.qh +++ b/qcsrc/common/constants.qh @@ -280,23 +280,6 @@ const vector eZ = '0 0 1'; #define SP_SCORE 3 // game mode specific indices are not in common/, but in server/scores_rules.qc! -#ifdef COMPAT_XON010_CHANNELS -const float CH_INFO = 0; // only on world and csqc -const float CH_TRIGGER = 0; // only on players; compat: FALSELY CONTROLLED BY "Info" -const float CH_WEAPON_A = 1; // only on players and entities -const float CH_WEAPON_SINGLE = 5; // only on players and entities -const float CH_VOICE = 2; // only on players -const float CH_BGM_SINGLE = 2; // only on csqc; compat: FALSELY CONTROLLED BY "Voice" -const float CH_AMBIENT = 2; // only on csqc; compat: FALSELY CONTROLLED BY "Voice" -const float CH_TRIGGER_SINGLE = 3; // only on players, entities, csqc -const float CH_SHOTS = 4; // only on players, entities, csqc -const float CH_SHOTS_SINGLE = 4; // only on players, entities, csqc -const float CH_WEAPON_B = 5; // only on players and entities -const float CH_PAIN = 6; // only on players and csqc -const float CH_PAIN_SINGLE = 6; // only on players and csqc -const float CH_PLAYER = 7; // only on players and entities -const float CH_TUBA = 5; // only on csqc -#else const float CH_INFO = 0; const float CH_TRIGGER = -3; const float CH_WEAPON_A = -1; @@ -312,7 +295,6 @@ const float CH_PAIN = -6; const float CH_PAIN_SINGLE = 6; const float CH_PLAYER = -7; const float CH_TUBA = 5; -#endif const float ATTEN_NONE = 0; const float ATTEN_MIN = 0.015625; diff --git a/qcsrc/common/util-pre.qh b/qcsrc/common/util-pre.qh index f39c30c00..4e8e1b59c 100644 --- a/qcsrc/common/util-pre.qh +++ b/qcsrc/common/util-pre.qh @@ -9,7 +9,6 @@ #ifndef NOCOMPAT //# define WORKAROUND_XON010 -//# define COMPAT_XON010_CHANNELS //# define COMPAT_XON050_ENGINE # define COMPAT_NO_MOD_IS_XONOTIC # define COMPAT_XON060_DONTCRASH_CHECKPVS diff --git a/qcsrc/common/util.qh b/qcsrc/common/util.qh index 503aa2d2a..9b969134a 100644 --- a/qcsrc/common/util.qh +++ b/qcsrc/common/util.qh @@ -305,9 +305,9 @@ const float XENCODE_LEN = 5; string xencode(float f); float xdecode(string s); -#ifndef COMPAT_XON010_CHANNELS +// Play all sounds via sound7, for access to the extra channels. +// Otherwise, channels 8 to 15 would be blocked for a weird QW feature. #define sound(e,c,s,v,a) sound7(e,c,s,v,a,0,0) -#endif float lowestbit(float f); diff --git a/qcsrc/server/miscfunctions.qc b/qcsrc/server/miscfunctions.qc index 5dc6f2e39..3cb28bc84 100644 --- a/qcsrc/server/miscfunctions.qc +++ b/qcsrc/server/miscfunctions.qc @@ -1082,15 +1082,6 @@ float sound_allowed(float dest, entity e) return TRUE; } -#ifdef COMPAT_XON010_CHANNELS -void(entity e, float chan, string samp, float vol, float atten) builtin_sound = #8; -void sound(entity e, float chan, string samp, float vol, float atten) -{ - if (!sound_allowed(MSG_BROADCAST, e)) - return; - builtin_sound(e, chan, samp, vol, atten); -} -#else #undef sound void sound(entity e, float chan, string samp, float vol, float atten) { @@ -1098,7 +1089,6 @@ void sound(entity e, float chan, string samp, float vol, float atten) return; sound7(e, chan, samp, vol, atten, 0, 0); } -#endif void soundtoat(float dest, entity e, vector o, float chan, string samp, float vol, float atten) {