hallo meine Textdraws sind nur für einen Spieler sichtbar und das soll nich dein wie mache ich dass hjeder den haben kann
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if(newstate == PLAYER_STATE_DRIVER)
{
if(Motor[playerid] != 1)
{
SendClientMessage(playerid,Rot,"Du kannst den Motor mit der Taste [Num2] oder mit /motor starten.");
}
else
{
SendClientMessage(playerid,Rot,"Du kannst den Motor mit der Taste [Num2] oder mit /motor ausschalten.");
}
if(Licht != 1)
{
SendClientMessage(playerid,Orange,"Du kannst das Licht mit der Taste [Num8] oder mit /licht einschalten.");
}
else
{
SendClientMessage(playerid,Orange,"Du kannst das Licht mit der Taste [Num8] oder mit /licht ausschalten.");
}
Textdraw0 = TextDrawCreate(618.000000, 346.000000, "_");
TextDrawBackgroundColor(Textdraw0, 255);
TextDrawFont(Textdraw0, 1);
TextDrawLetterSize(Textdraw0, 0.539999, 1.000000);
TextDrawColor(Textdraw0, -1);
TextDrawSetOutline(Textdraw0, 0);
TextDrawSetProportional(Textdraw0, 0);
TextDrawSetShadow(Textdraw0, 1);
TextDrawUseBox(Textdraw0, 1);
TextDrawBoxColor(Textdraw0, 170);
TextDrawTextSize(Textdraw0, 467.000000, 0.000000);
TextDrawSetSelectable(Textdraw0, 0);
Textdraw1 = TextDrawCreate(618.000000, 378.000000, "_");
TextDrawBackgroundColor(Textdraw1, 255);
TextDrawFont(Textdraw1, 1);
TextDrawLetterSize(Textdraw1, 0.539999, 1.000000);
TextDrawColor(Textdraw1, -1);
TextDrawSetOutline(Textdraw1, 0);
TextDrawSetProportional(Textdraw1, 0);
TextDrawSetShadow(Textdraw1, 1);
TextDrawUseBox(Textdraw1, 1);
TextDrawBoxColor(Textdraw1, 170);
TextDrawTextSize(Textdraw1, 467.000000, 2.000000);
TextDrawSetSelectable(Textdraw1, 0);
Textdraw2 = TextDrawCreate(618.000000, 362.000000, "_");
TextDrawBackgroundColor(Textdraw2, 255);
TextDrawFont(Textdraw2, 1);
TextDrawLetterSize(Textdraw2, 0.539999, 1.000000);
TextDrawColor(Textdraw2, -1);
TextDrawSetOutline(Textdraw2, 0);
TextDrawSetProportional(Textdraw2, 0);
TextDrawSetShadow(Textdraw2, 1);
TextDrawUseBox(Textdraw2, 1);
TextDrawBoxColor(Textdraw2, 170);
TextDrawTextSize(Textdraw2, 467.000000, 0.000000);
TextDrawSetSelectable(Textdraw2, 0);
new string[128],pVeh;
pVeh=GetPlayerVehicleID(playerid);
new model = GetVehicleModel(pVeh);
format(string,sizeof(string),"%s",CarName[model-400]);
Textdraw3 = TextDrawCreate(470.000000, 345.000000, string);
TextDrawBackgroundColor(Textdraw3, 255);
TextDrawFont(Textdraw3, 1);
TextDrawLetterSize(Textdraw3, 0.500000, 1.000000);
TextDrawColor(Textdraw3, -1);
TextDrawSetOutline(Textdraw3, 0);
TextDrawSetProportional(Textdraw3, 1);
TextDrawSetShadow(Textdraw3, 1);
TextDrawSetSelectable(Textdraw3, 0);
Textdraw4 = TextDrawCreate(470.000000, 361.000000, "Km/h:");
TextDrawBackgroundColor(Textdraw4, 255);
TextDrawFont(Textdraw4, 1);
TextDrawLetterSize(Textdraw4, 0.500000, 1.000000);
TextDrawColor(Textdraw4, -1);
TextDrawSetOutline(Textdraw4, 0);
TextDrawSetProportional(Textdraw4, 1);
TextDrawSetShadow(Textdraw4, 1);
TextDrawSetSelectable(Textdraw4, 0);
Zustand[playerid] = CreatePlayerTextDraw(playerid,470.000000,377.000000,"100%");
PlayerTextDrawBackgroundColor(playerid,Zustand[playerid], 255);
PlayerTextDrawFont(playerid,Zustand[playerid], 1);
PlayerTextDrawLetterSize(playerid,Zustand[playerid], 0.500000, 1.000000);
PlayerTextDrawColor(playerid,Zustand[playerid], -1);
PlayerTextDrawSetOutline(playerid,Zustand[playerid], 0);
PlayerTextDrawSetProportional(playerid,Zustand[playerid], 1);
PlayerTextDrawSetShadow(playerid,Zustand[playerid], 0);
Textdraw5 = TextDrawCreate(470.000000, 377.000000, "Zustand:");
TextDrawBackgroundColor(Textdraw5, 255);
TextDrawFont(Textdraw5, 1);
TextDrawLetterSize(Textdraw5, 0.500000, 1.000000);
TextDrawColor(Textdraw5, -1);
TextDrawSetOutline(Textdraw5, 0);
TextDrawSetProportional(Textdraw5, 1);
TextDrawSetShadow(Textdraw5, 1);
TextDrawSetSelectable(Textdraw5, 0);
TextDrawShowForPlayer(playerid, Textdraw0);
TextDrawShowForPlayer(playerid, Textdraw1);
TextDrawShowForPlayer(playerid, Textdraw2);
TextDrawShowForPlayer(playerid, Textdraw3);
TextDrawShowForPlayer(playerid, Textdraw4);
TextDrawShowForPlayer(playerid, Textdraw5);
}
if(newstate == PLAYER_STATE_ONFOOT)
{
TextDrawHideForAll(Textdraw0);
TextDrawDestroy(Textdraw0);
TextDrawHideForAll(Textdraw1);
TextDrawDestroy(Textdraw1);
TextDrawHideForAll(Textdraw2);
TextDrawDestroy(Textdraw2);
TextDrawHideForAll(Textdraw3);
TextDrawDestroy(Textdraw3);
TextDrawHideForAll(Textdraw4);
TextDrawDestroy(Textdraw4);
TextDrawHideForAll(Textdraw5);
TextDrawDestroy(Textdraw5);
TextDrawHideForAll(Textdraw5);
TextDrawDestroy(Textdraw5);
}