Guest User

Untitled

a guest
Apr 20th, 2020
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.51 KB | None | 0 0
  1. new PlayerText:GlavniCash[MAX_PLAYERS][1]; //GLAVNE PARE XD
  2.  
  3. GlavniCash[playerid][0] = CreatePlayerTextDraw(playerid, 497.555603, 99.404449, "$00000000");
  4. PlayerTextDrawLetterSize(playerid, GlavniCash[playerid][0], 0.499555, 1.933510);
  5. PlayerTextDrawAlignment(playerid, GlavniCash[playerid][0], 1);
  6. PlayerTextDrawColor(playerid, GlavniCash[playerid][0], -1);
  7. PlayerTextDrawSetShadow(playerid, GlavniCash[playerid][0], 0);
  8. PlayerTextDrawSetOutline(playerid, GlavniCash[playerid][0], 1);
  9. PlayerTextDrawBackgroundColor(playerid, GlavniCash[playerid][0], 255);
  10. PlayerTextDrawFont(playerid, GlavniCash[playerid][0], 3);
  11. PlayerTextDrawSetProportional(playerid, GlavniCash[playerid][0], 1);
  12.  
  13. forward NovacTDovi();
  14. public NovacTDovi()
  15. {
  16. foreach( new i : Player)
  17. {
  18. if(IsPlayerConnected(i))
  19. {
  20. if(PlayerInfo[i][xNovac] < 1)
  21. {
  22. PlayerTextDrawSetString(i,GlavniCash[i][0],"$00000000");
  23. }
  24. else if(PlayerInfo[i][xNovac] < 10)
  25. {
  26. new string[128];
  27. format(string,sizeof(string),"$0000000%d",PlayerInfo[i][xNovac]);
  28. PlayerTextDrawSetString(i,GlavniCash[i][0],string);
  29. }
  30. else if(PlayerInfo[i][xNovac] < 100)
  31. {
  32. new string[128];
  33. format(string,sizeof(string),"$000000%d",PlayerInfo[i][xNovac]);
  34. PlayerTextDrawSetString(i,GlavniCash[i][0],string);
  35. }
  36. else if(PlayerInfo[i][xNovac] < 1000)
  37. {
  38. new string[128];
  39. format(string,sizeof(string),"$00000%d",PlayerInfo[i][xNovac]);
  40. PlayerTextDrawSetString(i,GlavniCash[i][0],string);
  41. }
  42. else if(PlayerInfo[i][xNovac] < 10000)
  43. {
  44. new string[128];
  45. format(string,sizeof(string),"$0000%d",PlayerInfo[i][xNovac]);
  46. PlayerTextDrawSetString(i,GlavniCash[i][0],string);
  47. }
  48. else if(PlayerInfo[i][xNovac] < 100000)
  49. {
  50. new string[128];
  51. format(string,sizeof(string),"$000%d",PlayerInfo[i][xNovac]);
  52. PlayerTextDrawSetString(i,GlavniCash[i][0],string);
  53. }
  54. else if(PlayerInfo[i][xNovac] < 1000000)
  55. {
  56. new string[128];
  57. format(string,sizeof(string),"$00%d",PlayerInfo[i][xNovac]);
  58. PlayerTextDrawSetString(i,GlavniCash[i][0],string);
  59. }
  60. else if(PlayerInfo[i][xNovac] < 10000000)
  61. {
  62. new string[128];
  63. format(string,sizeof(string),"$0%d",PlayerInfo[i][xNovac]);
  64. PlayerTextDrawSetString(i,GlavniCash[i][0],string);
  65. }
  66. else if(PlayerInfo[i][xNovac] < 100000000)
  67. {
  68. new string[128];
  69. format(string,sizeof(string),"$%d",PlayerInfo[i][xNovac]);
  70. PlayerTextDrawSetString(i,GlavniCash[i][0],string);
  71. }
  72. }
  73. }
  74. }
Advertisement
Add Comment
Please, Sign In to add comment