10.10.2011, 20:22
Quote:
Creio que vocк jб tem a string formatada certo? format(string.... "Mensagem" etc etc etc.
Entгo, essa mesma string vocк usa no TextDrawSetString. Crie um TextDraw usando o Zamorth TextDrawEditor 1.0, tem aqui no fуrum, apуs isso coloque o TD no seu GM, use o TextDrawSetString no lugar do SendClientMessage seguido do TextDrawShowForPlayer e um timer que chama uma public, essa public irб ocultar o TD: TextDrawHideForAll. Й sу tentar, faria o cуdigo de exemplo mas meu tempo estб curto, caso nгo consiga, dк erros ou coisas assim, mande. |
Код:
public OnPlayerConnect(playerid) { PlayGang[playerid] = TextDrawCreate(8.000000,303.000000," "); TextDrawUseBox(PlayGang[playerid],1); TextDrawBoxColor(PlayGang[playerid],0xffff0000); TextDrawTextSize(PlayGang[playerid],270.000000,4.000000); TextDrawAlignment(PlayGang[playerid],0); TextDrawBackgroundColor(PlayGang[playerid],0x000000ff); TextDrawFont(PlayGang[playerid],3); TextDrawLetterSize(PlayGang[playerid],0.199999,1.700000); TextDrawColor(PlayGang[playerid],0xffffffff); TextDrawSetOutline(PlayGang[playerid],1); TextDrawSetProportional(PlayGang[playerid],1); TextDrawSetShadow(PlayGang[playerid],1); return 1; } public ZoneCheckpointChecker() { for(new i; i < MAX_PLAYERS; i++) { if(!IsPlayerConnected(i))continue; if(CPS_GetPlayerCheckpoint(i) > 0 && CPS_GetPlayerCheckpoint(i) <= MAX_GZS+1 && gzcolor[CPS_GetPlayerCheckpoint(i)-1] != GetPlayerColor(i)) { if(cpzone[i][CPS_GetPlayerCheckpoint(i)] < 20) { cpzone[i][CPS_GetPlayerCheckpoint(i)]++; new tmp[11]; format(tmp, sizeof tmp, "~y~%2d/20", cpzone[i][CPS_GetPlayerCheckpoint(i)]); GameTextForPlayer(i, tmp, 1001, 4); GangZoneFlashForAll(CPS_GetPlayerCheckpoint(i)-1, GetPlayerColor(i)); }else if(cpzone[i][CPS_GetPlayerCheckpoint(i)] == 20) { GivePlayerMoney(i, 1000); GameTextForPlayer(i, "~b~Gang zona dominada Com Sucesso!", 4000, 4); gzcolor[CPS_GetPlayerCheckpoint(i)-1] = GetPlayerColor(i); GangZoneStopFlashForAll(CPS_GetPlayerCheckpoint(i)-1); GangZoneHideForAll(CPS_GetPlayerCheckpoint(i)-1); GangZoneShowForAll(CPS_GetPlayerCheckpoint(i)-1, GetPlayerColor(i)); new nome[MAX_PLAYER_NAME],str[300]; new playerid; GetPlayerName(playerid, nome, sizeof(nome)); format(str,sizeof(str),"~b~%s ~y~dominou mais um territorio para: ~b~%s",nome, pgangnames[gangteam[playerid]],cpzone[playerid]); TextDrawSetString(Text:PlayGang[playerid], str); TextDrawShowForAll(PlayGang[playerid]); PlayerInfo[i][pDominou]++; for(new j; j < MAX_PLAYERS; j++) { if(gangteam[j] == CPS_GetPlayerCheckpoint(i)-1) GameTextForPlayer(j, " ~n~ ~n~ ~n~ ~n~ ~n~ ~n~ ~n~ ~n~ ~y~A base do ~g~seu time ~y~esta sendo ~r~dominada~y~!", 4000, 4); } } } } }
Entгo se nгo quer ajudar evite ser BABACA !!!