SA-MP Forums Archive
Weird Compile Log - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Weird Compile Log (/showthread.php?tid=609645)



Weird Compile Log - EsperZ - 14.06.2016

So, I tried to set chat's color for admins to gray, after I compile the script, I get this weird thing in the compile log:
Code:
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase

Header size:          34752 bytes
Code size:          5709568 bytes
Data size:         25073708 bytes
Stack/heap size:      16384 bytes; estimated max. usage: unknown, due to recursion
Total requirements:30834412 bytes

1 Warning.
I only have 1 warning which is not a problem. This is the string I used:
Code:
public OnPlayerText(playerid, text[])
{
	new string[200];
	if(!IsAdmin (playerid,1)) 
	{
 		format(string, sizeof(string), "{9C9C9C}» {%06x}%s {9C9C9C}[%d]: {BABABA} %s", (GetPlayerColor(playerid) >>> 8), pName[playerid], playerid, text);
 		SendClientMessageToAll((GetPlayerColor(playerid)), string);
	}
...
Anyone who knowns what's that log?


Re: Weird Compile Log - TwinkiDaBoss - 14.06.2016

You can either increase
#pragma dynamic

or simply just cut down some strings and such. For example dont use 256 string if you need 128 etc..

example:
PHP Code:
new string[256]; //If you are not using all 256 why make it? 
The message you are getting is basically telling you that your code aint that optimized or your script is getting a lot heavier than it should.


Re: Weird Compile Log - EsperZ - 15.06.2016

How to increase the #pragma dynamic, and if I increase it does it have any effects? Thank you


Re: Weird Compile Log - TwinkiDaBoss - 15.06.2016

Well its just stack and heap size in cells or something like that. In other words, amount of memory you need for your script and such. Something related to that to be honest.

You can set it to like 10000 or more, depends how much you need
PHP Code:
#pragma dynamic 10000 
This "problem" can cause other problems in the future such as script wont load certain things etc. Just increase the #pragma dynamic and it should resolve the problem temporarly.

Look into your script and see where you might have made a mistake with string sizes etc.

Theres even a tutorial about this, I recommend that you check it out.
https://sampforum.blast.hk/showthread.php?tid=569978


Re: Weird Compile Log - EsperZ - 15.06.2016

Alright thanks for the help