]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Make this branch semi work with GMQCC
authorSamual Lenks <samual@xonotic.org>
Sun, 6 Jan 2013 19:19:12 +0000 (14:19 -0500)
committerSamual Lenks <samual@xonotic.org>
Sun, 6 Jan 2013 19:19:12 +0000 (14:19 -0500)
qcsrc/client/autocvars.qh
qcsrc/client/hud.qc
qcsrc/common/command/generic.qc
qcsrc/common/notifications.qc
qcsrc/server/autocvars.qh
qcsrc/server/g_damage.qc
qcsrc/server/w_tuba.qc

index cb06932e45e00eefaa25e29dd3abf2e25df753c4..387cf44c5dd2d129c41d395010f3035cabfe5c37 100644 (file)
@@ -251,7 +251,6 @@ float autocvar_hud_panel_notify;
 float autocvar_hud_panel_notify_fadetime;
 float autocvar_hud_panel_notify_flip;
 float autocvar_hud_panel_notify_fontsize;
-float autocvar_hud_panel_notify_print;
 float autocvar_hud_panel_notify_time;
 float autocvar_hud_panel_physics;
 float autocvar_hud_panel_physics_acceleration_progressbar_mode;
index 74a726d68850272f30b658ff350d01db447cdd64..d9f783583cf573f90b097df2f71457fed690210b 100644 (file)
@@ -2190,7 +2190,7 @@ void HUD_Notify(void)
        float width_attacker;
        string attacker, victim, icon;
 
-       float i, j, w, type, step, limit;
+       float i, j, step, limit;
        if(autocvar_hud_panel_notify_flip) //order items from the top down
        {
                i = 0;
index e97745cfb2aa608af64770eec7bc0c218fc6b917..0bc5ededea7b18de6d4e2f4c3940bfad022a75ad 100644 (file)
@@ -232,7 +232,7 @@ void GenericCommand_dumpnotifs(float request)
        {
                case CMD_REQUEST_COMMAND:
                {
-                       float fh, alsoprint;
+                       float fh, alsoprint = FALSE;
                        
                        string filename = argv(1);
                        
index 89fe61d3c0cf8acc3b723198d9d5b74e22acafc8..b4b38e870b99a3bd7ffb45bf49c164712ea1a648 100644 (file)
@@ -449,7 +449,7 @@ float NOTIF_WEAPON_COUNT;
 float NOTIF_DEATH_COUNT;
 float NOTIF_CPID_COUNT;
 
-#define MSG_INFO_NOTIF(name,strnum,flnum,args,icon,normal,gentle) \
+#define MSG_INFO_NOTIF(name,strnum,flnum,args,hudargs,icon,normal,gentle) \
        ADD_CSQC_AUTOCVAR(name) \
        float name; \
        void RegisterNotification_##name() \
@@ -530,7 +530,7 @@ float notif_checkstring(string input)
 
 float notif_stringcount(string s1, string s2)
 {
-       float stringcount;
+       float stringcount = 0;
        if(s1 != NO_STR_ARG) ++stringcount;
        if(s2 != NO_STR_ARG) ++stringcount;
        return stringcount;
@@ -538,7 +538,7 @@ float notif_stringcount(string s1, string s2)
 
 float notif_floatcount(float f1, float f2, float f3)
 {
-       float floatcount;
+       float floatcount = 0;
        if(f1 != NO_FL_ARG) ++floatcount;
        if(f2 != NO_FL_ARG) ++floatcount;
        if(f3 != NO_FL_ARG) ++floatcount;
@@ -548,7 +548,7 @@ float notif_floatcount(float f1, float f2, float f3)
 // get the actual name of a notification and return it as a string
 string Get_Field_Value(float field, float net_type, float net_name)
 {
-       string output;
+       string output = "";
        
        #define GET_FIELD_VALUE_OUTPUT(field,name,strnum,flnum) \
                if(field == F_NAME) { output = VAR_TO_TEXT(name); } \
@@ -634,7 +634,7 @@ string CCR(string input)
 #define NOTIF_Write(type,name,text) notif_msg = sprintf("seta %s 1 // %s - %s\n", name, type, strreplace("\n", "\\n", text)); fputs(fh, notif_msg); if(alsoprint) { print(strreplace("^", "^^", notif_msg)); }
 void Dump_Notifications(float fh, float alsoprint)
 {
-       float MSG_INFO_NOTIFS, MSG_CENTER_NOTIFS, MSG_WEAPON_NOTIFS, MSG_DEATH_NOTIFS;
+       float MSG_INFO_NOTIFS = 0, MSG_CENTER_NOTIFS = 0, MSG_WEAPON_NOTIFS = 0, MSG_DEATH_NOTIFS = 0;
        string notif_msg;
        #define MSG_INFO_NOTIF(name,strnum,flnum,args,hudargs,icon,normal,gentle) { ++MSG_INFO_NOTIFS; NOTIF_Write("MSG_INFO", VAR_TO_TEXT(name), normal) }
        #define MSG_CENTER_NOTIF(name,strnum,flnum,args,cpid,durcnt,normal,gentle) { ++MSG_CENTER_NOTIFS; NOTIF_Write("MSG_CENTER", VAR_TO_TEXT(name), normal) }
@@ -781,8 +781,9 @@ void Send_Notification(entity client, float broadcast, float net_type, float net
 {
        if(broadcast && net_type && net_name)
        {
-               dprint("Send_Notification(", ftos(net_type), ", ", Get_Field_Value(F_NAME, net_type, net_name), strcat(", ", s1, ", ", s2, ", ", ftos(f1), strcat(", ", ftos(f2), ", ", ftos(f3), ");\n")));
+               dprint("Send_Notification(", ftos(broadcast), ", ", ftos(net_type), ", ", Get_Field_Value(F_NAME, net_type, net_name), strcat(", ", s1, ", ", s2, ", ", ftos(f1), strcat(", ", ftos(f2), ", ", ftos(f3), ");\n")));
 
+               print("hmm... ", ftos(net_name), "\n");
                float stringcount = stof(Get_Field_Value(F_STRNUM, net_type, net_name));
                float floatcount = stof(Get_Field_Value(F_FLNUM, net_type, net_name));
                
index 64ce307000104472d82148af6fc67d685f299fe3..d1930f94aff131f6a0c0a93018f1241027d537e4 100644 (file)
@@ -787,7 +787,6 @@ float autocvar_g_ctf_pass_request;
 float autocvar_g_ctf_pass_turnrate;
 float autocvar_g_ctf_pass_timelimit;
 float autocvar_g_ctf_pass_velocity;
-float autocvar_g_ctf_captimerecord_always;
 float autocvar_g_ctf_dynamiclights;
 string autocvar_g_ctf_flag_blue_model;
 float autocvar_g_ctf_flag_blue_skin;
@@ -1167,10 +1166,6 @@ float autocvar_sv_eventlog_files_counter;
 string autocvar_sv_eventlog_files_nameprefix;
 string autocvar_sv_eventlog_files_namesuffix;
 float autocvar_sv_eventlog_files_timestamps;
-float autocvar_sv_fraginfo;
-float autocvar_sv_fraginfo_handicap;
-float autocvar_sv_fraginfo_ping;
-float autocvar_sv_fraginfo_stats;
 float autocvar_sv_friction;
 float autocvar_sv_friction_on_land;
 float autocvar_sv_gameplayfix_q2airaccelerate;
index 3807e7ed9dbe97ee17a9172d4313f79fd046a4cc..addb3249628846dd3e7bc64e93498fa09db1f639 100644 (file)
@@ -308,9 +308,11 @@ void LogDeath(string mode, float deathtype, entity killer, entity killed)
        GameLogEcho(s);
 }
 
+#define INFO_NO_MSG 0
+
 void Obituary_SpecialDeath(entity notif_target, float murder, float deathtype, string s1, string s2, float f1, float f2, float f3)
 {
-       float handled, hits;
+       float handled = 0, hits = 0;
        if(DEATH_ISSPECIAL(deathtype))
        {
                #define DEATHTYPE(name,msg_death,msg_death_by,position) \
@@ -376,12 +378,9 @@ void Obituary(entity attacker, entity inflictor, entity targ, float deathtype)
        if not(targ.classname == STR_PLAYER) { backtrace("Obituary called on non-player?!\n"); return; }
 
        // Declarations
-       string  s, a, msg;
-       float type;
-
        string s1 = NO_STR_ARG, s2 = NO_STR_ARG;
        float f1 = NO_FL_ARG, f2 = NO_FL_ARG, f3 = NO_FL_ARG;
-       float notif_firstblood;
+       float notif_firstblood = FALSE;
 
        //dprint(sprintf("Obituary(): Deathtype = %s (%d), Attacker = %s, Inflictor = %s, Target = %s...\n", Deathtype_Name(deathtype), deathtype, attacker.netname, inflictor.netname, targ.netname));
 
index 0c2adbc2d51294382f6a1d2392ca8638c63af72d..15d4ef9d7deb44e9d6690fff01c77cbde572735d 100644 (file)
@@ -433,8 +433,6 @@ float w_tuba(float req)
                        return WEAPON_KLEINBOTTLE_SUICIDE;
                else
                        return WEAPON_TUBA_SUICIDE;
-
-               return FALSE;
        }
        else if (req == WR_KILLMESSAGE)
        {