Jump to content
  • 0

Problema comanda /ridicapayday


FlOrINn

Question

Problema intalnita (descriere):Am facut comanda, intru pe server si tasstez /ridicapayday imi da mai multe RP de cat trebuia , daca am 10 payday-uri de luat 10 RP sa imi dea :| RP = respect point
Ero(area / rile) / warning-(ul / urile):-
Liniile de cod / sursa / script-ul(obligatoriu):

 

 
if(strcmp(cmd,"/ridicapayday",true)==0)
{
  if(IsPlayerConnected(playerid))
  {
    if(PlayerToPoint(3.0,playerid,1488.5713,-1771.1624,18.7958))
    {
if (PlayerInfo[playerid][pIapayday] >= 1)
{
new coordsstring[256];
new string2[1000];
new Iapayday = PlayerInfo[playerid][pIapayday];
format(string2, sizeof(string2), "{7CA600}- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -n");
format(coordsstring, sizeof(coordsstring), "{B2248F}Ai ridicat %d PayDay-uri si primesti :n", Iapayday);
strcat(string2,coordsstring);
new exp = PlayerInfo[playerid][pExp];
PlayerInfo[playerid][pExp] = pIapayday;
format(coordsstring, sizeof(coordsstring), "{00FFCC}|-| %d Respect Points !n", exp);
strcat(string2,coordsstring);
PlayerInfo[playerid][pIapayday] -= Iapayday
format(coordsstring, sizeof(coordsstring), "{7CA600}- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -");
strcat(string2,coordsstring);
ShowPlayerDialog(playerid,DIALOG_STATS,DIALOG_STYLE_MSGBOX,"PayDay",string2,"Close","");
}else{
new coordsstring[256];
new string2[1000];
format(string2, sizeof(string2), "{7CA600}- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -n");
format(coordsstring, sizeof(coordsstring), "{B2248F}Nu aveti nici un PayDay de ridicat !n");
strcat(string2,coordsstring);
   format(coordsstring, sizeof(coordsstring), "{7CA600}- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -");
strcat(string2,coordsstring);
ShowPlayerDialog(playerid,DIALOG_STATS,DIALOG_STYLE_MSGBOX,"PayDay",string2,"Close","");
}
 
    }
   }
}
 
//------------


Imagini / Video (optional):-
Ati incercat sa rezolvati singur?:Da

:P Respecta ca sa fi respectact :P 

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Developer in :

C++,PHP,HTML,CSS,JAVASCRIPT,XML,MYSQL

si ceva  Pawno :)

WebDesign,Photoshop

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

/////////////////////////////////////////////////////////////////////////////////////////

=============================================

Steam ~ Kiburici

=============================================

Link to comment
Share on other sites

8 answers to this question

Recommended Posts

  • 0

Wtf nu are treaba, comanda trebuie sa transforme payday-uri in respect point ;|

Daca am 10 payday

Sa imi dea  10 Rp(pExp)

Am transformat functia care iti dadea la ore fixe rp in  payday-uri si eu trebuie sa ma duc la locatia aia ca sa ridic payday-uri.

:P Respecta ca sa fi respectact :P 

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Developer in :

C++,PHP,HTML,CSS,JAVASCRIPT,XML,MYSQL

si ceva  Pawno :)

WebDesign,Photoshop

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

/////////////////////////////////////////////////////////////////////////////////////////

=============================================

Steam ~ Kiburici

=============================================

Link to comment
Share on other sites

  • 0

incearca asa:

if(strcmp(cmd,"/ridicapayday",true)==0)


{
if(IsPlayerConnected(playerid))
{
if(PlayerToPoint(3.0,playerid,1488.5713,-1771.1624,18.7958))
{
if (PlayerInfo[playerid][pIapayday] >= 1)
{
new coordsstring[256];
new string2[1000];
new Iapayday = PlayerInfo[playerid][pIapayday];
format(string2, sizeof(string2), "{7CA600}- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -n");
format(coordsstring, sizeof(coordsstring), "{B2248F}Ai ridicat %d PayDay-uri si primesti :n", Iapayday);
strcat(string2,coordsstring);
new exp = PlayerInfo[playerid][pExp];
PlayerInfo[playerid][pExp] += pIapayday;
format(coordsstring, sizeof(coordsstring), "{00FFCC}|-| %d Respect Points !n", exp);
strcat(string2,coordsstring);
PlayerInfo[playerid][pIapayday] -= Iapayday
format(coordsstring, sizeof(coordsstring), "{7CA600}- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -");
strcat(string2,coordsstring);
ShowPlayerDialog(playerid,DIALOG_STATS,DIALOG_STYLE_MSGBOX,"PayDay",string2,"Close","");
}
else
{
new coordsstring[256];
new string2[1000];
format(string2, sizeof(string2), "{7CA600}- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -n");
format(coordsstring, sizeof(coordsstring), "{B2248F}Nu aveti nici un PayDay de ridicat !n");
strcat(string2,coordsstring);
format(coordsstring, sizeof(coordsstring), "{7CA600}- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -");
strcat(string2,coordsstring);
ShowPlayerDialog(playerid,DIALOG_STATS,DIALOG_STYLE_MSGBOX,"PayDay",string2,"Close","");
}

}
}
}

  • Upvote 1
Link to comment
Share on other sites

  • 0

am incercat si asa tot face.

Edited by FlOrINn

:P Respecta ca sa fi respectact :P 

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Developer in :

C++,PHP,HTML,CSS,JAVASCRIPT,XML,MYSQL

si ceva  Pawno :)

WebDesign,Photoshop

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

/////////////////////////////////////////////////////////////////////////////////////////

=============================================

Steam ~ Kiburici

=============================================

Link to comment
Share on other sites

  • 0
  • 0

Deci sa zicem ca eu in fisierul ini am :

Iapayday=10

Am 10 payday-uri de luat.

Ca sa le transform in respect point trebuie sa scriu comanda /ridicapayday . 

Trebuie sa imi adauge  inca 10 respect point dar mi-a adaugat 453 :| 

-----------------------------------

Concluzie: Eu vreau sa transform numarul de payday-uri in respect point.

:P Respecta ca sa fi respectact :P 

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Developer in :

C++,PHP,HTML,CSS,JAVASCRIPT,XML,MYSQL

si ceva  Pawno :)

WebDesign,Photoshop

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

/////////////////////////////////////////////////////////////////////////////////////////

=============================================

Steam ~ Kiburici

=============================================

Link to comment
Share on other sites

  • 0

Rezolvat

Cer T/C

:P Respecta ca sa fi respectact :P 

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Developer in :

C++,PHP,HTML,CSS,JAVASCRIPT,XML,MYSQL

si ceva  Pawno :)

WebDesign,Photoshop

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

/////////////////////////////////////////////////////////////////////////////////////////

=============================================

Steam ~ Kiburici

=============================================

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.