Vehicle Health
#9

About "new Text:VehicleHealthText" I already hav it "new Text:VehicleHealthText;"... and still dont work, just dont show .... it can be from the X and Y text positions? look my callback :
Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
	if(!IsPlayerInAnyVehicle(playerid) == false)
	{
 		GetVehicleHealth(vehicleid, vhealth);
 		format(str1, sizeof (str1), "Vehicle Health:%f", vhealth);
 		TextDrawSetString(VehicleHealthText, str1);
		TextDrawTextSize(VehicleHealthText, 2.0, 3.6);
		TextDrawFont(VehicleHealthText, 1);
 		TextDrawShowForPlayer(playerid, VehicleHealthText);
		if(vhealth > 0)
		{
	    	TextDrawColor(VehicleHealthText, 0xFF0000FF);
	    	return 1;
		}
		if(vhealth > 250)
		{
    	    TextDrawColor(VehicleHealthText, 0xFD7E00FF);
	    	return 1;
		}
		if(vhealth > 500)
		{
 	       TextDrawColor(VehicleHealthText, 0xF2FF00FF);
	    	return 1;
		}
		if(vhealth > 750)
		{
   		   TextDrawColor(VehicleHealthText, 0x05E600FF);
			return 1;
		}
		return 0;
	}
	return 1;
}
And i use/copy your script on your last post in OnGameModeInIt public
Reply


Messages In This Thread
Vehicle Health - by Jesus_wow - 24.10.2011, 15:58
Re: Vehicle Health - by jiwan - 24.10.2011, 16:11
Re: Vehicle Health - by [NoV]LaZ - 24.10.2011, 16:18
Re: Vehicle Health - by Jesus_wow - 24.10.2011, 16:22
Re: Vehicle Health - by Jesus_wow - 24.10.2011, 16:50
Re: Vehicle Health - by LetsOWN[PL] - 24.10.2011, 16:52
Re: Vehicle Health - by Jesus_wow - 24.10.2011, 18:59
Re: Vehicle Health - by [MWR]Blood - 24.10.2011, 19:09
Re: Vehicle Health - by Jesus_wow - 24.10.2011, 19:23

Forum Jump:


Users browsing this thread: 2 Guest(s)