Uh, Compiling question
#1

I just added an NRG and Infernus code, and got this
Код:
Header size:      5184 bytes
Code size:      560036 bytes
Data size:      589556 bytes
Stack/heap size:   16384 bytes; estimated max. usage=4224 cells (16896 bytes)
Total requirements: 1171160 bytes
Will it be a problem?


this is the code
Код:
new inf[MAX_PLAYERS]; // Declared here so it's a constant
new nrg[MAX_PLAYERS];
Код:
new Float:Pos[MAX_PLAYERS][4]; // You only need to declare one, not two

  if(!strcmp(cmdtext,"/inf",true))
  {
  if(PlayerInfo[playerid][pIsStunting] == 1)
   {
    DestroyVehicle(inf[playerid]);
     GetPlayerPos(playerid,Pos[playerid][1],Pos[playerid][2],Pos[playerid][3]);
     inf[playerid]=CreateVehicle(411,Pos[playerid][1],Pos[playerid][2],Pos[playerid][3],0,-1,-1,10);
     PutPlayerInVehicle(playerid,inf[playerid], 0);
    SendClientMessage(playerid,LIGHTBLUE,"You have Spawned An Infernus.");
     return 1;
}
  }
  if(!strcmp(cmdtext,"/nrg",true))
  {
  if(PlayerInfo[playerid][pIsStunting] == 1)
   {
   	DestroyVehicle(nrg[playerid]);
   	GetPlayerPos(playerid,Pos[playerid][1],Pos[playerid][2],Pos[playerid][3]);
     nrg[playerid]=CreateVehicle(522,Pos[playerid][1],Pos[playerid][2],Pos[playerid][3],0,-1,-1,10);
     PutPlayerInVehicle(playerid,nrg[playerid], 0);
    SendClientMessage(playerid,COLOR_LIGHTBLUE,"You have Spawned An NRG-500.");
}
   return 1;
  }/code
Reply
#2

Quote:
Originally Posted by Seif_
It's not a problem, but it might be in the future. If you have too many cells, your script can stop functioning. Try optimizing your script.
eh, >< How can i optimize it?, any suggestions?

Btw, thanks for quick response
Reply
#3

Quote:
Originally Posted by Seif_
thanks again, ill check it out in the morning =/, will it take long to do it? lol
Reply
#4

Not much, about 20 mins or less
Reply
#5

Quote:
Originally Posted by Anthony_Brassi
Quote:
Originally Posted by Seif_
It's not a problem, but it might be in the future. If you have too many cells, your script can stop functioning. Try optimizing your script.
eh, >< How can i optimize it?, any suggestions?

Btw, thanks for quick response
how did you make your proggress bar in the signature?
Reply
#6


Quote:

how did you make your proggress bar in the signature?

http://www.shareyouraim.com/


and thanks for the help
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)