#1

So did the team that managed the gui and throws me this one:

Header size: 9664 bytes
Code size: 1306068 bytes
Data size: 2642604 bytes
Stack/heap size: 16384 bytes; estimated max. usage=4931 cells (19724 bytes)
Total requirements: 3974720 bytes



team:

Код:
if( dialogid == 548 )
	{
	    if( response )
	    {
         if(listitem == 0)
          {
          Informacija(playerid,playerid);
          }
          if(listitem == 1)
           {
           new msg[180];
           new XPe = GetPlayerScore(playerid);
           new pdx = playerDB[playerid][pdxp];
           new dylx = playerDB[playerid][dylxp];
           new taxix = playerDB[playerid][medxp];
           new medx = playerDB[playerid][medxp];
           new mechx = playerDB[playerid][mechxp];
           new furx = playerDB[playerid][furxp];
           new cosax = playerDB[playerid][cosaxp];
           format(msg, 256, "{ff9933}Bendra patirtis(XP): {FFFFFF}%i\n{ff9933}Policininko: {ffffff}%i\n{ff9933}Dylerio: {ffffff}%i\n{ff9933}Taxisto: {ffffff}%i\n{ff9933}Mediko: {ffffff}%i\n{ff9933}Mechaniko: {ffffff}%i\n{ff9933}Fûristo: {ffffff}%i\n{ff9933}Mafijozo: {ffffff}%i", XPe, pdx, dylx, taxix, medx, mechx, furx, cosax);
           ShowPlayerDialog(playerid,9978,DIALOG_STYLE_MSGBOX,"Darbø patirtis",msg,"Gerai","");
 	      }
		}
   return 1;
}
Reply
#2

Uped
Reply
#3

It means you've run out of memory. You either have too much unnecessarily big strings/arrays, or simply your gamemode got really massive. Before you allocate more memory, go to https://sampforum.blast.hk/showthread.php?tid=57018 and check out memory reduction chapter.
Reply
#4

but I put this one to me in the throws ..
Reply
#5

Because you declare the msg with size of 180 and in the format (lenght parameter), you use set it to 256.

pawn Код:
new msg[180];
format(msg, 256, ...
Change it to 180 (if the message is smaller, reduce it).
Reply
#6

same...
Reply
#7

That was a part of it, you may use many arrays with large sizes that cause that. However, you're saying that it shows that only when you add that code, so what Informacija do? Can you post it?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)