set g_healthsize_soundfactor 0.5 "The sounds players make are amplified or reduced by this amount based on their size"\r
set g_healthsize_exteriorweapon_scalefactor 1 "Amount by which player size resizes the exterior weapon model"\r
set g_healthsize_weapon_scalefactor 1 "Amount by which player size resizes the view weapon model"\r
-set g_healthsize_weapon_scalefactor_pos 4 "Amount by which the view model is moved vertically based on player size"\r
+set g_healthsize_weapon_scalefactor_pos 6 "Amount by which the view model is moved vertically based on player size"\r
\r
set g_power 5 "when armor is below this level, the HUD, crosshair and helper will not work"\r
set g_power_reboot 2 "amount of time it takes to boot a player's subsystems once he has enough armor"\r
\r
// if we are a micro or macro, size the weapon model accordingly\r
if(cvar("g_healthsize") && cvar("g_healthsize_weapon_scalefactor"))\r
- if(self.model != "")\r
+ if(self.owner.scale) // prevents some exceptions\r
{\r
- self.scale = (1 + cvar("g_healthsize_weapon_scalefactor")) - cvar("g_healthsize_weapon_scalefactor") * self.owner.scale;\r
+ self.scale = pow(1 / self.owner.scale, cvar("g_healthsize_weapon_scalefactor"));\r
if(self.scale < 0.1)\r
self.scale = 0.1; // stuff breaks if scale is smaller than this\r
self.origin_z = (1 - self.scale) * cvar("g_healthsize_weapon_scalefactor_pos");\r