]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/client/main.qc
Merge branch 'master' into develop
[xonotic/xonotic-data.pk3dir.git] / qcsrc / client / main.qc
index 5380fd5f5e3145a6571d038a15265af9c5048628..90067ce9ee6f5585c0d3c003c1880398348c1312 100644 (file)
@@ -57,6 +57,8 @@ void CSQC_Init()
                maxclients = i;
        }
 
+       ReplicateVars_Send_All();
+
        // needs to be done so early because of the constants they create
        static_init();
        static_init_late();
@@ -123,13 +125,13 @@ void CSQC_Init()
 
        {
                get_mi_min_max_texcoords(1); // try the CLEVER way first
-               minimapname = strcat("gfx/", mi_shortname, "_radar.tga");
+               minimapname = strcat("gfx/", mi_shortname, "_radar");
                shortmapname = mi_shortname;
 
                if (precache_pic(minimapname) == "")
                {
                        // but maybe we have a non-clever minimap
-                       minimapname = strcat("gfx/", mi_shortname, "_mini.tga");
+                       minimapname = strcat("gfx/", mi_shortname, "_mini");
                        if (precache_pic(minimapname) == "")
                                minimapname = ""; // FAIL
                        else
@@ -194,7 +196,7 @@ void Shutdown()
        deactivate_minigame();
        HUD_MinigameMenu_Close(NULL, NULL, NULL);
 
-       ReplicateVars(true); // destroy
+       ReplicateVars_Destroy();
 }
 
 void AuditLists()
@@ -884,6 +886,7 @@ void CSQC_Ent_Update(entity this, bool isnew)
                {
                        LOG_INFOF("A CSQC entity changed its type! (edict: %d, server: %d, type: %d -> %d)", etof(this), this.entnum, this.enttype, t);
                        Ent_Remove(this);
+                       ONREMOVE(this);
                        clearentity(this);
                        isnew = true;
                }
@@ -1189,12 +1192,10 @@ NET_HANDLE(TE_CSQC_RACE, bool isNew)
                case RACE_NET_SPEED_AWARD:
                        race_speedaward = ReadInt24_t() * GetSpeedUnitFactor(autocvar_hud_panel_physics_speed_unit);
                        strcpy(race_speedaward_holder, ReadString());
-                       strcpy(race_speedaward_unit, GetSpeedUnit(autocvar_hud_panel_physics_speed_unit));
                        break;
                case RACE_NET_SPEED_AWARD_BEST:
                        race_speedaward_alltimebest = ReadInt24_t() * GetSpeedUnitFactor(autocvar_hud_panel_physics_speed_unit);
                        strcpy(race_speedaward_alltimebest_holder, ReadString());
-                       strcpy(race_speedaward_alltimebest_unit, GetSpeedUnit(autocvar_hud_panel_physics_speed_unit));
                        break;
                case RACE_NET_RANKINGS_CNT:
                        RANKINGS_DISPLAY_CNT = ReadByte();