]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Kill get_vehicleinfo
authorMario <mario@smbclan.net>
Sat, 2 Jan 2016 08:45:03 +0000 (18:45 +1000)
committerMario <mario@smbclan.net>
Sat, 2 Jan 2016 08:45:03 +0000 (18:45 +1000)
qcsrc/client/hud/hud.qc
qcsrc/client/view.qc
qcsrc/common/vehicles/all.qh
qcsrc/common/vehicles/cl_vehicles.qc
qcsrc/common/vehicles/sv_vehicles.qc

index 7b1aed1241a4d0896c45a06c5d8a94d8b6af20bf..b0f2b9ea65d37bdb8c54e5a5e0ee05f8b53224e9 100644 (file)
@@ -418,7 +418,7 @@ void HUD_Vehicle()
        if(hud == HUD_BUMBLEBEE_GUN)
                CSQC_BUMBLE_GUN_HUD();
        else {
-               Vehicle info = get_vehicleinfo(hud);
+               Vehicle info = Vehicles_from(hud);
                info.vr_hud(info);
        }
 }
index 80b1770c3a689902d91961cd09c35b75e3cc76e8..0995bc2f7ab8727d33a8537afe9ebc99646596fd 100644 (file)
@@ -779,7 +779,7 @@ void HUD_Crosshair_Vehicle()
 {
        if(hud != HUD_BUMBLEBEE_GUN)
        {
-               Vehicle info = get_vehicleinfo(hud);
+               Vehicle info = Vehicles_from(hud);
                info.vr_crosshair(info);
        }
 }
@@ -1466,7 +1466,7 @@ void CSQC_UpdateView(float w, float h)
                {
                        if(hud != HUD_BUMBLEBEE_GUN)
                        {
-                               Vehicle info = get_vehicleinfo(hud);
+                               Vehicle info = Vehicles_from(hud);
                                vehicle_viewdist = info.height;
                                vehicle_viewofs = info.view_ofs;
                        }
index cf4b711c3ad63942f4bab80ff9780799038e2f6f..f4e837f784694d841ca78b60c8a43d1c6d22990b 100644 (file)
@@ -5,7 +5,6 @@
 
 REGISTRY(Vehicles, BITS(4))
 #define Vehicles_from(i) _Vehicles_from(i, VEH_Null)
-#define get_vehicleinfo(i) Vehicles_from(i)
 REGISTER_REGISTRY(Vehicles)
 REGISTRY_CHECK(Vehicles)
 
index cc4fa0f122b9652f90a038e30fb3796ab7e16702..6b900fea6622892f817572435272c4d4041d0c79 100644 (file)
@@ -109,7 +109,7 @@ NET_HANDLE(TE_CSQC_VEHICLESETUP, bool isnew)
                AuxiliaryXhair[0].axh_image = vCROSS_BURST; // Plasma cannons
                AuxiliaryXhair[1].axh_image = vCROSS_BURST; // Raygun
        } else {
-               Vehicle info = get_vehicleinfo(hud_id);
+               Vehicle info = Vehicles_from(hud_id);
        info.vr_setup(info);
        }
 }
index 53ed9bf4cc682f0111088d99d02ec18b07042b3e..78a0dbc1f4acc29dd206dd5aff124f307ef28588 100644 (file)
@@ -737,7 +737,7 @@ void vehicles_damage(entity inflictor, entity attacker, float damage, int deatht
 
                antilag_clear(self);
 
-               Vehicle info = get_vehicleinfo(self.vehicleid);
+               Vehicle info = Vehicles_from(self.vehicleid);
                info.vr_death(info);
                vehicles_setreturn(self);
        }
@@ -944,7 +944,7 @@ void vehicles_touch()
                }
 
                if(self.play_time < time) {
-                       Vehicle info = get_vehicleinfo(self.vehicleid);
+                       Vehicle info = Vehicles_from(self.vehicleid);
                        info.vr_impact(info);
                }
 
@@ -1118,7 +1118,7 @@ void vehicles_enter(entity pl, entity veh)
 
        setself(veh);
        CSQCModel_UnlinkEntity(veh);
-       Vehicle info = get_vehicleinfo(veh.vehicleid);
+       Vehicle info = Vehicles_from(veh.vehicleid);
        info.vr_enter(info);
        setself(this);
 
@@ -1132,7 +1132,7 @@ void vehicles_think()
        if(self.owner)
                self.owner.vehicle_weapon2mode = self.vehicle_weapon2mode;
 
-       Vehicle info = get_vehicleinfo(self.vehicleid);
+       Vehicle info = Vehicles_from(self.vehicleid);
        info.vr_think(info);
 
        vehicles_painframe(self);
@@ -1183,7 +1183,7 @@ void vehicles_spawn()
 
        vehicles_reset_colors();
 
-       Vehicle info = get_vehicleinfo(self.vehicleid);
+       Vehicle info = Vehicles_from(self.vehicleid);
        info.vr_spawn(info);
 
        CSQCMODEL_AUTOINIT(self);
@@ -1198,7 +1198,7 @@ bool vehicle_initialize(entity veh, bool nodrop)
                return false;
 
        if(!veh.tur_head) {
-               Vehicle info = get_vehicleinfo(veh.vehicleid);
+               Vehicle info = Vehicles_from(veh.vehicleid);
                info.vr_precache(info);
        }
 
@@ -1293,7 +1293,7 @@ bool vehicle_initialize(entity veh, bool nodrop)
        self.pos2 = self.angles;
        self.tur_head.team = self.team;
 
-       Vehicle info = get_vehicleinfo(veh.vehicleid);
+       Vehicle info = Vehicles_from(veh.vehicleid);
        info.vr_setup(info);
 
        if(self.active == ACTIVE_NOT)