Jump to content
  • 0

Problema comanda /stats


tagarta

Question

Am mai postat odata pt. ca topicul de data trecuta a fost inchis fiindca nu am mai intrat sa il verific ca a fost forumul off..

Nick: dexter

Problema: Am luat si eu GM Real Gaming si am gasit un BUG.

Cand tastez stats ma pune sa aleg cum sa apara [text/dialog] . Sub forma de text merge foarte bine, dar cand aleg sa apara sub forma de dialog merge doar prima data cand dau /stats, dupa aceea, in chat scrie : 'SERVER: Unknowm command

Erori / warnings: SERVER: Unknowm command

Lini/script: x

Ai incercat sa rezolvi singur ?: da

Comanda :

[pawn]if(PlayerInfo[playerid][pStats] == 2)

{

new string2[1152];

new coordsstring[1152];

new year, month, day;

getdate(year,month,day);

format(string2, sizeof(string2),"{FFFFFF}» STATISTICI CONT: {800000}%s {FFFFFF}- %d.%d.%d « \n", name, day, month, year);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Level: {800000}%d {FFFFFF}| Sex: {800000}%s {FFFFFF}| Varsta: {800000}%d {FFFFFF}| Cash: {800000}$%s {FFFFFF}| Banca: {800000}$%s \n", level,atext,age,FormatNumber(cash),FormatNumber(account));

strcat(string2,coordsstring);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Cont Premium: {800000}%s {FFFFFF}| Casatorit: {800000}%s {FFFFFF}| OreJucate: {800000}%d {FFFFFF}| Job: {800000}%s \n", drank,married,ptime,jtext);

strcat(string2,coordsstring);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Imprumut: {800000}%s${FFFFFF}/{800000}%s$ {FFFFFF}| {800000}FPunish: %d/40 {FFFFFF}| PuncteWanted: {800000}%d{FFFFFF}/6 | Tel: {800000}%d \n",FormatNumber(imprumutscazut),FormatNumber(imprumut),wanted, fpunish, pnumber);

strcat(string2,coordsstring);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Droguri: {800000}%d {FFFFFF}| Materiale: %d {FFFFFF}| Respect: {800000}%d{FFFFFF}/{800000}%d {FFFFFF}| Factiune: {800000}%s {FFFFFF}| Rang: {800000}%s \n",drugs,mats,exp, expamount,ttext,rtext,fwarn, warns);

strcat(string2,coordsstring);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Credit: {800000}%d mesaje/%d apeluri {FFFFFF}| PuncteRob: {800000}%d/10 {FFFFFF}| FWarns: {800000}%d/3 {FFFFFF}| Warns: {800000}%d/3 \n\n",sms, call, PRob, fwarn, warns);

strcat(string2,coordsstring);

if(PlayerInfo[playerid][pAdmin] >= 1)

{

format(coordsstring, sizeof(coordsstring), "{FF0000}Administrator: %d | HP: %.1f | Casa: %d | Afacere: %d | HireKey: %d | Interior: %d | Local: %d | IP: %s \n", PlayerInfo[targetid][pAdmin],health,housekey,bizkey,HireCar[targetid],intir,local,plrip);

strcat(string2, coordsstring);

format(coordsstring, sizeof(coordsstring), "{FF0000}Vehicul [slot #1]: %d | Vehicul [slot #2]: %d | Vehicul [slot #3]: %d | Skin: %d", PlayerInfo[targetid][pPcarkey], PlayerInfo[targetid][pPcarkey2],PlayerInfo[playerid][pPcarkey3],skin);

strcat(string2, coordsstring);

}

ShowPlayerDialog(playerid,97,DIALOG_STYLE_MSGBOX,"Statistici cont",string2,"Iesire","");

}

}

new sendername[MAX_PLAYER_NAME];

GetPlayerName(playerid, sendername, sizeof(sendername));

printf("[DEBUG]: #ShowStats - %s", sendername);

}

[/pawn]

[pawn]if (strcmp(cmd, "/stats", true) == 0)

{

    if(IsPlayerConnected(playerid))

    {

if (gPlayerLogged[playerid] != 0)

{

ShowStats(playerid,playerid);

}

else

{

SendClientMessage(playerid, COLOR_GRAD1, "Nu esti logat!");

}

}

return 1;

}[/pawn]

PS:

[pawn]ShowStats(playerid,playerid);[/pawn] nu il mai gasesc in alta parte decat in "/stats"

ID messenger: yo.ady95 @yahoo.com .

Pentru informa?ii , ad?uga?i-m? !

Link to comment
Share on other sites

17 answers to this question

Recommended Posts

[pawn] if(PlayerInfo[playerid][pStats] == 0)

{

    format(string9, sizeof(string9), "{FFFFFF}Sub ce forma doresti sa-ti vizualizezi statisticile contului (/stats)?");

    ShowPlayerDialog(playerid, 96, DIALOG_STYLE_MSGBOX, "Statistici cont",string9, "Indisponibil", "Text");

}

if(PlayerInfo[playerid][pStats] == 1)

{

    new year, month, day;

getdate(year,month,day);

new coordsstring[256];

SendClientMessage(playerid, COLOR_dexter,"------------------------------------------------------------------------------------");

format(coordsstring, sizeof(coordsstring),"{FFFFFF}»»»»»»»»»»»»»»»» {800000}STATISTICI CONT: %s - %d.%d.%d {FFFFFF}««««««««««««««««",name, day, month, year);

SendClientMessage(playerid, COLOR_WHITE,coordsstring);

format(coordsstring, sizeof(coordsstring), "{800000}Level:{FFFFFF} %d || Sex: %s || Varsta: %d || Cash: $%s || Banca: $%s || Job: %s || Skin: %d", level,atext,age,FormatNumber(cash),FormatNumber(account), jtext, skin);

SendClientMessage(playerid, COLOR_GRAD1,coordsstring);

format(coordsstring, sizeof(coordsstring), "{800000}Cont Premium:{FFFFFF} %s || Casatorit: %s || OreJucate: %d || PretLevel: $%s || Tel: %d || Warns: %d/3", drank,married,ptime,FormatNumber(costlevel),pnumber,warns);

SendClientMessage(playerid, COLOR_GRAD3,coordsstring);

format(coordsstring, sizeof(coordsstring), "{800000}Credit:{FFFFFF} %d SMS/%d apeluri || Imprumut: %s$/%s$ || PuncteWanted: %d/6 || FPunish: %d/15 || PuncteRob: %d/10",sms,call, FormatNumber(imprumutscazut),FormatNumber(imprumut), wanted, fpunish, PRob);

SendClientMessage(playerid, COLOR_GRAD4,coordsstring);

format(coordsstring, sizeof(coordsstring), "{800000}Droguri:{FFFFFF} %d || Materiale: %d || Respect: %d/%d || Factiune: %s || FWarns: %d/3 || Rang: %s",drugs,mats,exp,expamount,ttext,fwarn,rtext);

SendClientMessage(playerid, COLOR_GRAD5,coordsstring);

if(PlayerInfo[playerid][pAdmin] >= 1)

{

format(coordsstring, sizeof(coordsstring), "{800000}Administrator:{FFFFFF} %d || HP: %.1f || Afacere: %d || HireKey: %d || Interior: %d || Local: %d || IP: %s", PlayerInfo[targetid][pAdmin],health,housekey,bizkey,HireCar[targetid],intir,local,plrip);

SendClientMessage(playerid, COLOR_LIGHTRED,coordsstring);

format(coordsstring, sizeof(coordsstring), "{800000}Vehicul [slot #1]: %d || Vehicul [slot #2]: %d || Vehicul [slot #3]: %d || Casa: %d || Afacere: %d ", PlayerInfo[targetid][pPcarkey], PlayerInfo[targetid][pPcarkey2],PlayerInfo[targetid][pPcarkey3], housekey, bizkey);

SendClientMessage(playerid, COLOR_LIGHTRED,coordsstring);

}

SendClientMessage(playerid, COLOR_dexter,"------------------------------------------------------------------------------------");

}

if(PlayerInfo[playerid][pStats] == 2)

{

new string2[1152];

new coordsstring[1152];

new year, month, day;

getdate(year,month,day);

format(string2, sizeof(string2),"{FFFFFF}» STATISTICI CONT: {800000}%s {FFFFFF}- %d.%d.%d « \n", name, day, month, year);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Level: {800000}%d {FFFFFF}| Sex: {800000}%s {FFFFFF}| Varsta: {800000}%d {FFFFFF}| Cash: {800000}$%s {FFFFFF}| Banca: {800000}$%s \n", level,atext,age,FormatNumber(cash),FormatNumber(account));

strcat(string2,coordsstring);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Cont Premium: {800000}%s {FFFFFF}| Casatorit: {800000}%s {FFFFFF}| OreJucate: {800000}%d {FFFFFF}| Job: {800000}%s \n", drank,married,ptime,jtext);

strcat(string2,coordsstring);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Imprumut: {800000}%s${FFFFFF}/{800000}%s$ {FFFFFF}| {800000}FPunish: %d/40 {FFFFFF}| PuncteWanted: {800000}%d{FFFFFF}/6 | Tel: {800000}%d \n",FormatNumber(imprumutscazut),FormatNumber(imprumut),wanted, fpunish, pnumber);

strcat(string2,coordsstring);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Droguri: {800000}%d {FFFFFF}| Materiale: %d {FFFFFF}| Respect: {800000}%d{FFFFFF}/{800000}%d {FFFFFF}| Factiune: {800000}%s {FFFFFF}| Rang: {800000}%s \n",drugs,mats,exp, expamount,ttext,rtext,fwarn, warns);

strcat(string2,coordsstring);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Credit: {800000}%d mesaje/%d apeluri {FFFFFF}| PuncteRob: {800000}%d/10 {FFFFFF}| FWarns: {800000}%d/3 {FFFFFF}| Warns: {800000}%d/3 \n\n",sms, call, PRob, fwarn, warns);

strcat(string2,coordsstring);

if(PlayerInfo[playerid][pAdmin] >= 1)

{

format(coordsstring, sizeof(coordsstring), "{FF0000}Administrator: %d | HP: %.1f | Casa: %d | Afacere: %d | HireKey: %d | Interior: %d | Local: %d | IP: %s \n", PlayerInfo[targetid][pAdmin],health,housekey,bizkey,HireCar[targetid],intir,local,plrip);

strcat(string2, coordsstring);

format(coordsstring, sizeof(coordsstring), "{FF0000}Vehicul [slot #1]: %d | Vehicul [slot #2]: %d | Vehicul [slot #3]: %d | Skin: %d", PlayerInfo[targetid][pPcarkey], PlayerInfo[targetid][pPcarkey2],PlayerInfo[playerid][pPcarkey3],skin);

strcat(string2, coordsstring);

}

ShowPlayerDialog(playerid,97,DIALOG_STYLE_MSGBOX,"Statistici cont",string2,"Iesire","");

}

}

new sendername[MAX_PLAYER_NAME];

GetPlayerName(playerid, sendername, sizeof(sendername));

printf("[DEBUG]: #ShowStats - %s", sendername);

}[/pawn]

ID messenger: yo.ady95 @yahoo.com .

Pentru informa?ii , ad?uga?i-m? !

Link to comment
Share on other sites

Iar ai aratat doar o parte ... Acolo ai o "}" in plus, vreau sa vad de unde vine aia.

La "rintf("[DEBUG]: #ShowStats - %s", sendername);" se termina.. incepe "SetPlayerToTeamColor"..

ID messenger: yo.ady95 @yahoo.com .

Pentru informa?ii , ad?uga?i-m? !

Link to comment
Share on other sites

La "rintf("[DEBUG]: #ShowStats - %s", sendername);" se termina.. incepe "SetPlayerToTeamColor"..

Ce spun eu, ce raspunzi tu. Eu iti spun sa-mi arati tot CODUL sa vad de unde ai "}" care e in plus in ce mi-ai dat tu!

Link to comment
Share on other sites

[pawn]public ShowStats(playerid,targetid)

{

    if(IsPlayerConnected(playerid)&&IsPlayerConnected(targetid))

{

new cash =  GetPlayerCash(targetid);

new atext[20];

if(PlayerInfo[targetid][pSex] == 1) { atext = "Masculin"; }

else if(PlayerInfo[targetid][pSex] == 2) { atext = "Feminin"; }

new ttext[20];

if(PlayerInfo[targetid][pMember] == 4 || PlayerInfo[targetid][pLeader] == 4) { ttext = "Medic&Fireman"; }

else if(gTeam[targetid] == 4 || gTeam[targetid] == 3) { ttext = "Civil"; }

else if(PlayerInfo[targetid][pMember] == 1 || PlayerInfo[targetid][pLeader] == 1) { ttext = "Politia Romana"; }

else if(PlayerInfo[targetid][pMember] == 2 || PlayerInfo[targetid][pLeader] == 2) { ttext = "S.R.I.."; }

else if(PlayerInfo[targetid][pMember] == 3 || PlayerInfo[targetid][pLeader] == 3) { ttext = "Armata Romana"; }

else if(PlayerInfo[targetid][pMember] == 4 || PlayerInfo[targetid][pLeader] == 4) { ttext = "S.M.U.R.D"; }

else if(PlayerInfo[targetid][pMember] == 5 || PlayerInfo[targetid][pLeader] == 5) { ttext = "Clanul Sportivilor"; }

else if(PlayerInfo[targetid][pMember] == 6 || PlayerInfo[targetid][pLeader] == 6) { ttext = "Clanul Cordunenilor"; }

else if(PlayerInfo[targetid][pMember] == 7 || PlayerInfo[targetid][pLeader] == 7) { ttext = "Clanul Butoane"; }

else if(PlayerInfo[targetid][pMember] == 8 || PlayerInfo[targetid][pLeader] == 8) { ttext = "Agentia Hitman"; }

else if(PlayerInfo[targetid][pMember] == 9 || PlayerInfo[targetid][pLeader] == 9) { ttext = "PRO TV"; }

else if(PlayerInfo[targetid][pMember] == 10 || PlayerInfo[targetid][pLeader] == 10) { ttext = "Taxi Cab Co."; }

else if(PlayerInfo[targetid][pMember] == 11 || PlayerInfo[targetid][pLeader] == 11) { ttext = "Instructor Auto"; }

else if(PlayerInfo[targetid][pMember] == 12 || PlayerInfo[targetid][pLeader] == 12) { ttext = "Remorcari Auto"; }

    new rtext[64];

if(PlayerInfo[targetid][pMember] == 1 || PlayerInfo[targetid][pLeader] == 1)//PR Ranks

{

    if(PlayerInfo[targetid][pRank] == 1) { rtext = "Cadet"; }

else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Ofiter"; }

else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Sergent"; }

else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Locotenent"; }

else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Capitan"; }

        else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Chestor"; }

else { rtext = "Cadet"; }

}

else if(PlayerInfo[targetid][pMember] == 2 || PlayerInfo[targetid][pLeader] == 2)//S.R.I Ranks

{

    if(PlayerInfo[targetid][pRank] == 1) { rtext = "Subinspector"; }

else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Inspector"; }

else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Comisar"; }

else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Agent special"; }

else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Asistent director"; }

    else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Director"; }

else { rtext = "Subinspector"; }

}

else if(PlayerInfo[targetid][pMember] == 3 || PlayerInfo[targetid][pLeader] == 3)//NG Ranks

{

    if(PlayerInfo[targetid][pRank] == 1) { rtext = "Caporal"; }

else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Sergent"; }

else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Maior"; }

else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Capitan"; }

else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Locotenent"; }

    else if(PlayerInfo[targetid][pRank] == 6) { rtext = "General"; }

else { rtext = "Caporal"; }

}

else if(PlayerInfo[targetid][pMember] == 4 || PlayerInfo[targetid][pLeader] == 4)//MF Ranks

{

    if(PlayerInfo[targetid][pRank] == 1) { rtext = "Student"; }

else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Pompier"; }

else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Asistent"; }

else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Medic primar"; }

else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Director adjunct"; }

    else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Director"; }

else { rtext = "Subinspector"; }

}

else if(PlayerInfo[targetid][pMember] == 5 || PlayerInfo[targetid][pLeader] == 5)//Clanul Sportivilor Ranks

{

    if(PlayerInfo[targetid][pRank] == 1) { rtext = "Incepator"; }

else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Talhar"; }

else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Mafiot"; }

else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Criminal"; }

else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Coordonator"; }

    else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Sefu'"; }

else { rtext = "Sefu'"; }

}

else if(PlayerInfo[targetid][pMember] == 6 || PlayerInfo[targetid][pLeader] == 6)//Clanul Cordunenilor Ranks

{

    if(PlayerInfo[targetid][pRank] == 1) { rtext = "Incepator"; }

else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Talhar"; }

else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Mafiot"; }

else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Criminal"; }

else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Coordonator"; }

    else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Sefu'"; }

else { rtext = "Sefu'"; }

}

else if(PlayerInfo[targetid][pMember] == 7 || PlayerInfo[targetid][pLeader] == 7)// Clanul Butoane Ranks

{

    if(PlayerInfo[targetid][pRank] == 1) { rtext = "Copil"; }

else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Hot"; }

else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Jefuitor"; }

else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Violator"; }

else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Criminal"; }

    else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Sefu'"; }

else { rtext = "Copil"; }

}

else if(PlayerInfo[targetid][pMember] == 8 || PlayerInfo[targetid][pLeader] == 8)//Hitman Ranks

{

    if(PlayerInfo[targetid][pRank] == 1) { rtext = "Incepator"; }

else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Lunetist"; }

else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Asasin"; }

else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Asasin profesionist"; }

else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Vice-Director"; }

    else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Director"; }

else { rtext = "Incepator"; }

}

else if(PlayerInfo[targetid][pMember] == 9 || PlayerInfo[targetid][pLeader] == 9)//NR Ranks

{

    if(PlayerInfo[targetid][pRank] == 1) { rtext = "Cameraman"; }

else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Ziarist"; }

else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Reporter"; }

else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Redactor sef"; }

else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Editor"; }

    else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Producator"; }

else { rtext = "Cameraman"; }

}

else if(PlayerInfo[targetid][pMember] == 10 || PlayerInfo[targetid][pLeader] == 10)//Taxi Company Ranks

{

    if(PlayerInfo[targetid][pRank] == 1) { rtext = "Incepator"; }

else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Sofer"; }

else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Taximetrist"; }

else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Dispecer"; }

else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Director"; }

    else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Proprietar Taxi"; }

else { rtext = "Incepator"; }

}

else if(IsAnInstructor(targetid))//Driving/Flying School Ranks

{

    if(PlayerInfo[targetid][pRank] == 1) { rtext = "Student"; }

else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Instructor"; }

else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Instructor profesionist"; }

else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Manager"; }

else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Vice-director"; }

    else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Director"; }

else { rtext = "Student"; }

}

else if(PlayerInfo[targetid][pMember] == 12 || PlayerInfo[targetid][pLeader] == 12)// Remorcari Auto

{

    if(PlayerInfo[targetid][pRank] == 1) { rtext = "Vulcanizator"; }

else if(PlayerInfo[targetid][pRank] == 2) { rtext = "Mecanic incepator"; }

else if(PlayerInfo[targetid][pRank] == 3) { rtext = "Mecanic profesionist"; }

else if(PlayerInfo[targetid][pRank] == 4) { rtext = "Mester"; }

else if(PlayerInfo[targetid][pRank] == 5) { rtext = "Inginer mecanic"; }

    else if(PlayerInfo[targetid][pRank] == 6) { rtext = "Director companie"; }

else { rtext = "Vulcanizator"; }

}

else

{

    rtext = "-";

}

        new jtext[20];

        if(PlayerInfo[targetid][pJob] == 1) { jtext = "Detectiv"; }

        else if(PlayerInfo[targetid][pJob] == 2) { jtext = "Avocat"; }

        else if(PlayerInfo[targetid][pJob] == 3) { jtext = "Prostituata"; }

        else if(PlayerInfo[targetid][pJob] == 4) { jtext = "Dealer droguri"; }

        else if(PlayerInfo[targetid][pJob] == 5) { jtext = "Spargator de masini"; }

        else if(PlayerInfo[targetid][pJob] == 6) { jtext = "Reporter"; }

        else if(PlayerInfo[targetid][pJob] == 7) { jtext = "Mecanic auto"; }

        else if(PlayerInfo[targetid][pJob] == 8) { jtext = "Bodyguard"; }

        else if(PlayerInfo[targetid][pJob] == 9) { jtext = "Dealer arme"; }

        else if(PlayerInfo[targetid][pJob] == 10) { jtext = "Dealer masini"; }

        else if(PlayerInfo[targetid][pJob] == 11) { jtext = "Fermier"; }

else if(PlayerInfo[targetid][pJob] == 12) { jtext = "Curier"; }

        else if(PlayerInfo[targetid][pJob] == 14) { jtext = "Sofer autobuz"; }

        else if(PlayerInfo[targetid][pJob] == 15) { jtext = "Ziarist"; }

        else if(PlayerInfo[targetid][pJob] == 16) { jtext = "Camionagiu"; }

        else { jtext = "Somer"; }

new drank[20];

if(PlayerInfo[targetid][pDonateRank] == 1) { drank = "Da"; }

else { drank = "Nu exista"; }

new married[20];

strmid(married, PlayerInfo[targetid][pMarriedTo], 0, strlen(PlayerInfo[targetid][pMarriedTo]), 255);

new age = PlayerInfo[targetid]


;

new ptime = PlayerInfo[targetid][pConnectTime];

new fwarn = PlayerInfo[targetid][pFwarn];

new fpunish = PlayerInfo[targetid][pPunish];

new drugs = PlayerInfo[targetid][pDrugs];

new mats = PlayerInfo[targetid][pMats];

new wanted = WantedLevel[targetid];

new level = PlayerInfo[targetid][pLevel];

new exp = PlayerInfo[targetid][pExp];

new pnumber = PlayerInfo[targetid][pPnumber];

new account = PlayerInfo[targetid][pAccount];

new nxtlevel = PlayerInfo[targetid][pLevel]+1;

new expamount = nxtlevel*levelexp;

new costlevel = nxtlevel*levelcost;//10k for testing purposes

new housekey = PlayerInfo[targetid][pPhousekey];

new bizkey = PlayerInfo[targetid][pPbiskey];

new intir = PlayerInfo[targetid][pInt];

        new skin = PlayerInfo[targetid][pChar];

        new Float:health;

        GetPlayerHealth(targetid, health);

new local = PlayerInfo[targetid][pLocal];

new PRob = PlayerInfo[targetid][pRob];

new name[MAX_PLAYER_NAME];

new warns = PlayerInfo[targetid][pWarns];

new imprumut = PlayerInfo[targetid][pImprumut];

  new imprumutscazut = PlayerInfo[targetid][pImprumut]/45;

new sms = PlayerInfo[targetid][pSMS];

new call = PlayerInfo[targetid][pCall];

GetPlayerName(targetid, name, sizeof(name));

new Float:px,Float:py,Float:pz;

GetPlayerPos(targetid, px, py, pz);

new plrip[16];

GetPlayerIp(targetid, plrip, sizeof(plrip));

new string9[128];

if(PlayerInfo[playerid][pStats] == 0)

{

    format(string9, sizeof(string9), "{FFFFFF}Sub ce forma doresti sa-ti vizualizezi statisticile contului (/stats)?");

    ShowPlayerDialog(playerid, 96, DIALOG_STYLE_MSGBOX, "Statistici cont",string9, "Indisponibil", "Text");

}

if(PlayerInfo[playerid][pStats] == 1)

{

    new year, month, day;

getdate(year,month,day);

new coordsstring[256];

SendClientMessage(playerid, COLOR_dexter,"------------------------------------------------------------------------------------");

format(coordsstring, sizeof(coordsstring),"{FFFFFF}»»»»»»»»»»»»»»»» {800000}STATISTICI CONT: %s - %d.%d.%d {FFFFFF}««««««««««««««««",name, day, month, year);

SendClientMessage(playerid, COLOR_WHITE,coordsstring);

format(coordsstring, sizeof(coordsstring), "{800000}Level:{FFFFFF} %d || Sex: %s || Varsta: %d || Cash: $%s || Banca: $%s || Job: %s || Skin: %d", level,atext,age,FormatNumber(cash),FormatNumber(account), jtext, skin);

SendClientMessage(playerid, COLOR_GRAD1,coordsstring);

format(coordsstring, sizeof(coordsstring), "{800000}Cont Premium:{FFFFFF} %s || Casatorit: %s || OreJucate: %d || PretLevel: $%s || Tel: %d || Warns: %d/3", drank,married,ptime,FormatNumber(costlevel),pnumber,warns);

SendClientMessage(playerid, COLOR_GRAD3,coordsstring);

format(coordsstring, sizeof(coordsstring), "{800000}Credit:{FFFFFF} %d SMS/%d apeluri || Imprumut: %s$/%s$ || PuncteWanted: %d/6 || FPunish: %d/15 || PuncteRob: %d/10",sms,call, FormatNumber(imprumutscazut),FormatNumber(imprumut), wanted, fpunish, PRob);

SendClientMessage(playerid, COLOR_GRAD4,coordsstring);

format(coordsstring, sizeof(coordsstring), "{800000}Droguri:{FFFFFF} %d || Materiale: %d || Respect: %d/%d || Factiune: %s || FWarns: %d/3 || Rang: %s",drugs,mats,exp,expamount,ttext,fwarn,rtext);

SendClientMessage(playerid, COLOR_GRAD5,coordsstring);

if(PlayerInfo[playerid][pAdmin] >= 1)

{

format(coordsstring, sizeof(coordsstring), "{800000}Administrator:{FFFFFF} %d || HP: %.1f || Afacere: %d || HireKey: %d || Interior: %d || Local: %d || IP: %s", PlayerInfo[targetid][pAdmin],health,housekey,bizkey,HireCar[targetid],intir,local,plrip);

SendClientMessage(playerid, COLOR_LIGHTRED,coordsstring);

format(coordsstring, sizeof(coordsstring), "{800000}Vehicul [slot #1]: %d || Vehicul [slot #2]: %d || Vehicul [slot #3]: %d || Casa: %d || Afacere: %d ", PlayerInfo[targetid][pPcarkey], PlayerInfo[targetid][pPcarkey2],PlayerInfo[targetid][pPcarkey3], housekey, bizkey);

SendClientMessage(playerid, COLOR_LIGHTRED,coordsstring);

}

SendClientMessage(playerid, COLOR_dexter,"------------------------------------------------------------------------------------");

}

if(PlayerInfo[playerid][pStats] == 2)

{

new string2[1152];

new coordsstring[1152];

new year, month, day;

getdate(year,month,day);

format(string2, sizeof(string2),"{FFFFFF}» STATISTICI CONT: {800000}%s {FFFFFF}- %d.%d.%d « \n", name, day, month, year);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Level: {800000}%d {FFFFFF}| Sex: {800000}%s {FFFFFF}| Varsta: {800000}%d {FFFFFF}| Cash: {800000}$%s {FFFFFF}| Banca: {800000}$%s \n", level,atext,age,FormatNumber(cash),FormatNumber(account));

strcat(string2,coordsstring);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Cont Premium: {800000}%s {FFFFFF}| Casatorit: {800000}%s {FFFFFF}| OreJucate: {800000}%d {FFFFFF}| Job: {800000}%s \n", drank,married,ptime,jtext);

strcat(string2,coordsstring);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Imprumut: {800000}%s${FFFFFF}/{800000}%s$ {FFFFFF}| {800000}FPunish: %d/40 {FFFFFF}| PuncteWanted: {800000}%d{FFFFFF}/6 | Tel: {800000}%d \n",FormatNumber(imprumutscazut),FormatNumber(imprumut),wanted, fpunish, pnumber);

strcat(string2,coordsstring);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Droguri: {800000}%d {FFFFFF}| Materiale: %d {FFFFFF}| Respect: {800000}%d{FFFFFF}/{800000}%d {FFFFFF}| Factiune: {800000}%s {FFFFFF}| Rang: {800000}%s \n",drugs,mats,exp, expamount,ttext,rtext,fwarn, warns);

strcat(string2,coordsstring);

format(coordsstring, sizeof(coordsstring), "{FFFFFF}Credit: {800000}%d mesaje/%d apeluri {FFFFFF}| PuncteRob: {800000}%d/10 {FFFFFF}| FWarns: {800000}%d/3 {FFFFFF}| Warns: {800000}%d/3 \n\n",sms, call, PRob, fwarn, warns);

strcat(string2,coordsstring);

if(PlayerInfo[playerid][pAdmin] >= 1)

{

format(coordsstring, sizeof(coordsstring), "{FF0000}Administrator: %d | HP: %.1f | Casa: %d | Afacere: %d | HireKey: %d | Interior: %d | Local: %d | IP: %s \n", PlayerInfo[targetid][pAdmin],health,housekey,bizkey,HireCar[targetid],intir,local,plrip);

strcat(string2, coordsstring);

format(coordsstring, sizeof(coordsstring), "{FF0000}Vehicul [slot #1]: %d | Vehicul [slot #2]: %d | Vehicul [slot #3]: %d | Skin: %d", PlayerInfo[targetid][pPcarkey], PlayerInfo[targetid][pPcarkey2],PlayerInfo[playerid][pPcarkey3],skin);

strcat(string2, coordsstring);

}

ShowPlayerDialog(playerid,97,DIALOG_STYLE_MSGBOX,"Statistici cont",string2,"Iesire","");

}

}

new sendername[MAX_PLAYER_NAME];

GetPlayerName(playerid, sendername, sizeof(sendername));

printf("[DEBUG]: #ShowStats - %s", sendername);

}

//---------------------------------------------------------[/pawn]

Sper sa fie bun acum..

ID messenger: yo.ady95 @yahoo.com .

Pentru informa?ii , ad?uga?i-m? !

Link to comment
Share on other sites

Sincer eu la comanda n-am vazut nimic neinregula. Poate ca m-am uitat in fuga pe ea ... In fine, da-ne si dialog-ul, adica atunci cand ii arata dialogoul, cauta in gm:[pawn]dialogid == 97[/pawn]

Nu este " dialogid == 97 " ..

Am gasit doar astea in schimb :

[pawn] if(dialogid == 96)

{

    if(response)

    {

        PlayerInfo[playerid][pStats] = 2;

        ShowStats(playerid, playerid);

    }

    else

    {

        PlayerInfo[playerid][pStats] = 1;

        ShowStats(playerid, playerid);

        return 1;

    }

}

if(dialogid == 98)

{

    if(response)

    {

        PlayerInfo[playerid][pStats] = 2;

SCM(playerid, -1, "{800000}[s-F] {FFFFFF}Vizualizarea statisticilor contului tau a fost schimbata in modul DIALOG!");

SCM(playerid, -1, "{800000}[s-F] {FFFFFF}Tasteaza /stats pentru a vedea noile modificari!");

return 1;

    }

    else

    {

        PlayerInfo[playerid][pStats] = 1;

        SCM(playerid, -1, "{800000}[s-F] {FFFFFF}Vizualizarea statisticilor contului tau a fost schimbata in modul TEXT!");

SCM(playerid, -1, "{800000}[s-F] {FFFFFF}Tasteaza /stats pentru a vedea noile modificari!");

return 1;

    }

}[/pawn]

ID messenger: yo.ady95 @yahoo.com .

Pentru informa?ii , ad?uga?i-m? !

Link to comment
Share on other sites

Posteaza "ShowStats(playerid,playerid);" trebuie sa fie un "public" sau "stock"

Apoi in prima parte unde ai postat aia cu "if(PlayerInfo[playerid][pStats] == 2) {" nu ai postat comanda intrega.Daca vrei sa te ajutam posteaza tot, ca nu fura nimeni GM-uri si comenzi care le gasesti peste tot pe net.La aceasta comanda ai 2 acolade inschise la sfarsit in plus, asta inseamna ca inainte de if(PlayerInfo[playerid][pStats] == 2) mai sunt 2 sau mai multe cerinte.

Link to comment
Share on other sites

Posteaza "ShowStats(playerid,playerid);" trebuie sa fie un "public" sau "stock"

Apoi in prima parte unde ai postat aia cu "if(PlayerInfo[playerid][pStats] == 2) {" nu ai postat comanda intrega.Daca vrei sa te ajutam posteaza tot, ca nu fura nimeni GM-uri si comenzi care le gasesti peste tot pe net.La aceasta comanda ai 2 acolade inschise la sfarsit in plus, asta inseamna ca inainte de if(PlayerInfo[playerid][pStats] == 2) mai sunt 2 sau mai multe cerinte.

E postat tot mai sus prin reply-uri..

ID messenger: yo.ady95 @yahoo.com .

Pentru informa?ii , ad?uga?i-m? !

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.