.amx Size & Memory used
#1

Hey all,

I just have a few questions regarding my script and the size of the .amx as well as the memory being used by the functions. After compiling my script my .amx size is incredibly huge (38mb) which makes it incredibly inconvenient to upload as I use a remote host for hosting my server.

To limit this while testing my script I've implemented the following code:

Code:
#undef MAX_PLAYERS
#define MAX_PLAYERS 5

#undef MAX_VEHICLES
#define MAX_VEHICLES 250

#undef MAX_PICKUPS
#define MAX_PICKUPS 25
.. which bring the final size down to 2.5mb. When I have my server up and running it's going to be extremely irratating that I have to use these settings or something insignificantly higher to find it easy to run my script. The script was optimised to be used with earlier versions of SA-MP (0.1 & mainly 0.2). Would anyone be able to make any suggestions as to what I can do to limit the .amx file size? Would implementing something like zcmd make a significant difference? My game mode is over 20,000 lines which makes it a challenge to configure.

I also came to the conclusion that my script is not entirely sufficient, causing it to use ALOT of system resources, which I also want to limit.

Would anyone be able to make any suggestions?

Thanks.
Reply
#2

Most likely wasted/excess variables, repeated code etc, I would take a look through:
http://forum.sa-mp.com/index.php?topic=79810.0
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)