Player textdraw nгo estб a mostrar... -
VeNuZ_ - 07.10.2014
pawn Код:
//ongamemodeinit
for(new id = 0; id <= MAX_PLAYERS; id++){
StatsBarTD[id][0] = CreatePlayerTextDraw(id,647.000000, 433.000000, "_");
PlayerTextDrawBackgroundColor(id,StatsBarTD[id][0], -16711681);
PlayerTextDrawFont(id,StatsBarTD[id][0], 1);
PlayerTextDrawLetterSize(id,StatsBarTD[id][0], 0.500000, 1.400000);
PlayerTextDrawColor(id,StatsBarTD[id][0], -1);
PlayerTextDrawSetOutline(id,StatsBarTD[id][0], 1);
PlayerTextDrawSetProportional(id,StatsBarTD[id][0], 1);
PlayerTextDrawUseBox(id,StatsBarTD[id][0], 1);
PlayerTextDrawBoxColor(id,StatsBarTD[id][0], 153);
PlayerTextDrawTextSize(id,StatsBarTD[id][0], -5.000000, -1.000000);
PlayerTextDrawSetSelectable(id,StatsBarTD[id][0], 0);
//printf("criar StatsBarTD[%i][0] ", id);
StatsBarTD[id][1] = CreatePlayerTextDraw(id,0.000000, 433.000000, "~r~TR - Rampage ~y~]~g~] ~r~Kills: ~y~1000 ~b~] ~r~Deaths: ~y~1000 ~b~] ~r~K/D: ~y~100.0 ~b~] ~r~Exp: ~y~10/50 ~b~] ~r~Nivel: ~y~1000 ~b~ // ~r~[~y~El Quebrados ~b~(~y~0~b~)~r~] ~b~]~r~Tempo: ~r~14:35");
PlayerTextDrawBackgroundColor(id,StatsBarTD[id][1], -247);
PlayerTextDrawFont(id,StatsBarTD[id][1], 2);
PlayerTextDrawLetterSize(id,StatsBarTD[id][1], 0.220000, 1.300000);
PlayerTextDrawColor(id,StatsBarTD[id][1], -1);
PlayerTextDrawSetOutline(id,StatsBarTD[id][1], 1);
PlayerTextDrawSetProportional(id,StatsBarTD[id][1], 1);
PlayerTextDrawSetSelectable(id,StatsBarTD[id][1], 0);
//printf("criar StatsBarTD[%i][1] ", id);
}
CMD:mostrar(playerid)
{
PlayerTextDrawShow(playerid, StatsBarTD[playerid][0]);
PlayerTextDrawShow(playerid, StatsBarTD[playerid][1]);
return 1;
}
Alguйm me dб ai uma ajuda ?
Respuesta: Player textdraw nгo estб a mostrar... -
Parka - 07.10.2014
Vocк nгo pode criar PlayerText dessa maneira jб que se o jogador nгo esta conectado o PlayerText й destruнdo.
pawn Код:
public OnPlayerConnect(playerid){
StatsBarTD[playerid][0] = CreatePlayerTextDraw(id,647.000000, 433.000000, "_");
PlayerTextDrawBackgroundColor(id,StatsBarTD[playerid][0], -16711681);
PlayerTextDrawFont(id,StatsBarTD[playerid][0], 1);
PlayerTextDrawLetterSize(id,StatsBarTD[playerid][0], 0.500000, 1.400000);
PlayerTextDrawColor(id,StatsBarTD[playerid][0], -1);
PlayerTextDrawSetOutline(id,StatsBarTD[playerid][0], 1);
PlayerTextDrawSetProportional(id,StatsBarTD[playerid][0], 1);
PlayerTextDrawUseBox(id,StatsBarTD[playerid][0], 1);
PlayerTextDrawBoxColor(id,StatsBarTD[playerid][0], 153);
PlayerTextDrawTextSize(id,StatsBarTD[playerid][0], -5.000000, -1.000000);
PlayerTextDrawSetSelectable(id,StatsBarTD[playerid][0], 0);
StatsBarTD[playerid][1] = CreatePlayerTextDraw(id,0.000000, 433.000000, "~r~TR - Rampage ~y~]~g~] ~r~Kills: ~y~1000 ~b~] ~r~Deaths: ~y~1000 ~b~] ~r~K/D: ~y~100.0 ~b~] ~r~Exp: ~y~10/50 ~b~] ~r~Nivel: ~y~1000 ~b~ // ~r~[~y~El Quebrados ~b~(~y~0~b~)~r~] ~b~]~r~Tempo: ~r~14:35");
PlayerTextDrawBackgroundColor(id,StatsBarTD[playerid][1], -247);
PlayerTextDrawFont(id,StatsBarTD[playerid][1], 2);
PlayerTextDrawLetterSize(id,StatsBarTD[playerid][1], 0.220000, 1.300000);
PlayerTextDrawColor(id,StatsBarTD[playerid][1], -1);
PlayerTextDrawSetOutline(id,StatsBarTD[playerid][1], 1);
PlayerTextDrawSetProportional(id,StatsBarTD[playerid][1], 1);
PlayerTextDrawSetSelectable(id,StatsBarTD[playerid][1], 0);
return 1;
}
Re: Player textdraw nгo estб a mostrar... -
VeNuZ_ - 07.10.2014
Entao quer dizer que eu crio e wuando o jogdor sai do server apaga autonaticamente ?
Re: Player textdraw nгo estб a mostrar... -
PT - 07.10.2014
Se nao fosses tao preguiзoso ias a wiki e vias isto:
pawn Код:
Player-textdraws are automatically destroyed when a player disconnects.
https://sampwiki.blast.hk/wiki/CreatePlayerTextDraw
Re: Player textdraw nгo estб a mostrar... -
VeNuZ_ - 07.10.2014
Eu fui lб tirar exemplo para exprimentar antes de guardar no TD.. Mas nгo li a pбgina toda o: