27.11.2011, 14:44
pawn Код:
new Float:MostHealth, Float:vHealth, vDriver, veh;
for(new i; i < MAX_VEHICLES; i++)
{
GetVehicleHealth(i, vHealth);
if(vHealth > MostHealth)
{
MostHealth = vHealth;
veh = i;
}
}
vDriver = GetVehicleDriver(veh);
SetPlayerHealth(vDriver, (MostHealth/10));
Modify it to suit your needs.