Jump to content
  • 0

Problema string.


Question

Posted

Problema intalnita (descriere): Pai nu stiu cum sa pun la /stats cu dialog... am pus cu strcat dar vad ca trebe fara valori, si daca pun fiecare cu string-ul sau nu-mi apare... imi da Unknown command.
Ero(area / rile) / warning-(ul / urile): 

			new sendername[MAX_PLAYER_NAME];
		 	new stringc[1524];
			new year, month, day;
			getdate(year,month,day);
			GetPlayerName(playerid, sendername, sizeof(sendername));
			format(stringc,sizeof(stringc),"Buletin {DC0C0C}%s {a9c4e4}- %d/%d/%d\n", sendername, day, month, year);
			//format(stringc,sizeof(stringc),"Informatii Donator - {DC0C0C}%s {a9c4e4}- %d/%d/%d\n", sendername, day, month, year);
			strcat ( stringc, " {a9c4e4}________________________");
			strcat ( stringc, " \n\n{a9c4e4}Level: \t\t {ee5555}%d", level);
			strcat ( stringc, " \n{a9c4e4}Respect Points: \t {ee5555}%d/%d", respect, respectneed);
			strcat ( stringc, " \n{a9c4e4}Cash: \t {ee5555}$%s");
		 	strcat ( stringc, " \n{a9c4e4}Bank: \t {ee5555}$%s");
		 	strcat ( stringc, " \n{a9c4e4}PhoneNr.: \t {ee5555}%s");
		 	strcat ( stringc, " \n{a9c4e4}Premium Account: \t {ee5555}%s");
		   	strcat ( stringc, " \n{a9c4e4}Next level: \t {ee5555}%s");
		   	strcat ( stringc, " \n{a9c4e4}Hours played: \t {ee5555}%d");
		   	strcat ( stringc, " \n{a9c4e4}Rob Points: \t {ee5555}%d/10");
		   	strcat ( stringc, " \n{a9c4e4}Jailed: \t {ee5555}%s");
		   	strcat ( stringc, " \n{a9c4e4}AJailed: \t {ee5555}%s");
		   	strcat ( stringc, " \n{a9c4e4}Muted: \t {ee5555}%s");
		   	strcat ( stringc, " \n{a9c4e4}Fireworks: \t {ee5555}%d");
		   	strcat ( stringc, " \n{a9c4e4}Wanted Level: \t {ee5555}%d");
		   	strcat ( stringc, " \n{a9c4e4}Kills: \t {ee5555}%d");
		   	strcat ( stringc, " \n{a9c4e4}Deaths: \t {ee5555}%d");
		   	strcat ( stringc, " \n{a9c4e4}Drugs: \t {ee5555}%d");
		   	strcat ( stringc, " \n{a9c4e4}Materials: \t {ee5555}%d");
		   	strcat ( stringc, " \n{a9c4e4}Gold: \t {ee5555}%d");
		   	strcat ( stringc, " \n{a9c4e4}Crimes: \t {ee5555}%d");
		   	strcat ( stringc, " \n{a9c4e4}Arrests: \t {ee5555}%d");
		   	strcat ( stringc, " \n{a9c4e4}Wanted Deaths: \t {ee5555}%d");
		   	strcat ( stringc, " \n{a9c4e4}Job: \t {ee5555}%s");
		   	strcat ( stringc, " \n{a9c4e4}Faction: \t {ee5555}%s");
		   	strcat ( stringc, " \n{a9c4e4}Rank: \t {ee5555}%s");
		   	strcat ( stringc, " \n{a9c4e4}FWarns: \t {ee5555}%d/3");
		   	strcat ( stringc, " \n{a9c4e4}FPunish: \t {ee5555}%d/20");
		   	strcat ( stringc, " \n{a9c4e4}Warns: \t {ee5555}%d/3");
		   	strcat ( stringc, " \n\n{a9c4e4}________________________");
		   	strcat ( stringc, " \n\n{DC0C0C}BLoWn RPG{FFFFFF} v0.2.1");
			ShowPlayerDialog(playerid, 966, DIALOG_STYLE_MSGBOX, "Show Stats", stringc, "Iesi", "");

Si acum daca pun asa 

			strcat ( stringc, " \n\n{a9c4e4}Level: \t\t {ee5555}%d", level);
			strcat ( stringc, " \n{a9c4e4}Respect Points: \t {ee5555}%d/%d", respect, respectneed);

Nu mai apare in dialog... apare de la respect points in jos.
Liniile de cod / sursa / script-ul(obligatoriu):  Mai sus.
Imagini / Video (optional): -
Ati incercat sa rezolvati singur?:  Da. dar degeaba ... nu merge

8 answers to this question

Recommended Posts

  • 0
  • 0
Posted (edited)

Nu e problema in jos ca nu apare ! Problema este in sus la primele... adica la Level daca-i pun valoarea nu apare.

 

 

 

EDIT:

Citat

            new sendername[MAX_PLAYER_NAME];
             new stringc[9999];
            new year, month, day;
            getdate(year,month,day);
            GetPlayerName(playerid, sendername, sizeof(sendername));
            format(stringc,sizeof(stringc),"Buletin {DC0C0C}%s {a9c4e4}- %d/%d/%d\n", sendername, day, month, year);
            //format(stringc,sizeof(stringc),"Informatii Donator - {DC0C0C}%s {a9c4e4}- %d/%d/%d\n", sendername, day, month, year);
            strcat ( stringc, " {a9c4e4}________________________");
            strcat ( stringc, " \n\n{a9c4e4}Level: \t {ee5555}%d");
            strcat ( stringc, " \n{a9c4e4}Respect Points: \t {ee5555}%d/%d");
            strcat ( stringc, " \n{a9c4e4}Cash: \t {ee5555}$%s");
             strcat ( stringc, " \n{a9c4e4}Bank: \t {ee5555}$%s");
             strcat ( stringc, " \n{a9c4e4}PhoneNr.: \t {ee5555}%s");
             strcat ( stringc, " \n{a9c4e4}Premium Account: \t {ee5555}%s");
               strcat ( stringc, " \n{a9c4e4}Next level: \t {ee5555}%s");
               strcat ( stringc, " \n{a9c4e4}Hours played: \t {ee5555}%d");
               strcat ( stringc, " \n{a9c4e4}Rob Points: \t {ee5555}%d/10");
               strcat ( stringc, " \n{a9c4e4}Jailed: \t {ee5555}%s");
               strcat ( stringc, " \n{a9c4e4}AJailed: \t {ee5555}%s");
               strcat ( stringc, " \n{a9c4e4}Muted: \t {ee5555}%s");
               strcat ( stringc, " \n{a9c4e4}Fireworks: \t {ee5555}%d");
               strcat ( stringc, " \n{a9c4e4}Wanted Level: \t {ee5555}%d");
               strcat ( stringc, " \n{a9c4e4}Kills: \t {ee5555}%d");
               strcat ( stringc, " \n{a9c4e4}Deaths: \t {ee5555}%d");
               strcat ( stringc, " \n{a9c4e4}Drugs: \t {ee5555}%d");
               strcat ( stringc, " \n{a9c4e4}Materials: \t {ee5555}%d");
               strcat ( stringc, " \n{a9c4e4}Gold: \t {ee5555}%d");
               strcat ( stringc, " \n{a9c4e4}Crimes: \t {ee5555}%d");
               strcat ( stringc, " \n{a9c4e4}Arrests: \t {ee5555}%d");
               strcat ( stringc, " \n{a9c4e4}Wanted Deaths: \t {ee5555}%d");
               strcat ( stringc, " \n{a9c4e4}Job: \t {ee5555}%s");
               strcat ( stringc, " \n{a9c4e4}Faction: \t {ee5555}%s");
               strcat ( stringc, " \n{a9c4e4}Rank: \t {ee5555}%s");
               strcat ( stringc, " \n{a9c4e4}FWarns: \t {ee5555}%d/3");
               strcat ( stringc, " \n{a9c4e4}FPunish: \t {ee5555}%d/20");
               strcat ( stringc, " \n{a9c4e4}Warns: \t {ee5555}%d/3");
               strcat ( stringc, " \n\n{a9c4e4}________________________");
               strcat ( stringc, " \n\n{DC0C0C}BLoWn RPG{FFFFFF} v0.2.1");
            ShowPlayerDialog(playerid, 966, DIALOG_STYLE_MSGBOX, "Show Stats", stringc, "Iesi", "");

Daca il pun cum e mai sus apare doar ca apare de ex %d nu apare valoare pentru ca nu are...

 

Dar daca pun o valoare de ex la Level %d", level);

Edited by VeLo
  • 0
Posted (edited)
 

DAca ii pui valoare, nu mai apare nica dupa level, sau nu mai apare randul deloc?

 

Edited by .№_Fpk.Marius_™.
#SclipireDeMoment
  • 0
  • 0
Posted

Poftim am incercat asa..

 

 

            format(stringc,sizeof(stringc),"Buletin {DC0C0C}%s {a9c4e4}- %d/%d/%d\n", sendername, day, month, year);
            //format(stringc,sizeof(stringc),"Informatii Donator - {DC0C0C}%s {a9c4e4}- %d/%d/%d\n", sendername, day, month, year);
             format(stringc,sizeof(stringc)," {a9c4e4}________________________");
             format(stringc,sizeof(stringc)," \n\n{a9c4e4}Level: \t {ee5555}%d", level);
             format(stringc,sizeof(stringc)," \n{a9c4e4}Respect Points: \t {ee5555}%d/%d", respect, respectneed);

 

 

Si daca-l pun asa nu mai apare... imi da server: unknown command.

  • 0
Posted (edited)

Rezolvat!

 

T/C.

Edited by VeLo
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.