public HalfSecUpdate()
{
new string[256], farbcode[7];
for(new playerid = 0; playerid < MAX_PLAYERS; playerid++)
{
if(IsPlayerConnected(playerid))
{
if(!IsPlayerInRangeOfPoint(playerid,30.0,-1659.9304,1210.9401,21.1563))
{
if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT || GetPlayerState(playerid) == PLAYER_STATE_WASTED)
{
TextDrawHideForPlayer(playerid,Tankanzeige[playerid]);
new vehicle = GetPlayerVehicleID(playerid);
new Tank[MAX_VEHICLES];
Tank[vehicle]=floatround((GasMax/100*Gas[vehicle]),floatround_round);
if(Tank[vehicle] >= 93)format(string,sizeof(string),"%sIIIIIIIIIIIII~w~",farbcode);
else if(Tank[vehicle] >= 86)format(string,sizeof(string),"Tank: %sIIIIIIIIIIII~w~I");
else if(Tank[vehicle] >= 79)format(string,sizeof(string),"Tank: %sIIIIIIIIIII~w~II");
else if(Tank[vehicle] >= 72)format(string,sizeof(string),"Tank: %sIIIIIIIIII~w~III");
else if(Tank[vehicle] >= 65)format(string,sizeof(string),"Tank: %sIIIIIIIII~w~IIII");
else if(Tank[vehicle] >= 57)format(string,sizeof(string),"Tank: %sIIIIIIII~w~IIIII");
else if(Tank[vehicle] >= 50)format(string,sizeof(string),"Tank: %sIIIIIII~w~IIIIII");
else if(Tank[vehicle] >= 43)format(string,sizeof(string),"Tank: %sIIIIII~w~IIIIIII");
else if(Tank[vehicle] >= 36)format(string,sizeof(string),"Tank: %sIIIII~w~IIIIIIII");
else if(Tank[vehicle] >= 29)format(string,sizeof(string),"Tank: %sIIII~w~IIIIIIIII");
else if(Tank[vehicle] >= 22)format(string,sizeof(string),"Tank: %sIII~w~IIIIIIIIII");
else if(Tank[vehicle] >= 15)format(string,sizeof(string),"Tank: %sII~w~IIIIIIIIIII");
else if(Tank[vehicle] >= 7) format(string,sizeof(string),"Tank: %sI~w~IIIIIIIIIIII");
else format(string,sizeof(string),"Tank: %s~w~IIIIIIIIIIIII");
TextDrawHideForPlayer(playerid,Tankanzeige[playerid]);
TextDrawSetString(Tankanzeige[playerid],string);
TextDrawShowForPlayer(playerid,Tankanzeige[playerid]);
}
}
else
{
TextDrawHideForPlayer(playerid,Tankanzeige[playerid]);
return 1;
}
}
}
return 1;
}
undzwar möchte ich dass die tankanzeige so wie auf dem Bild aussieht wie mach ich das dann?