SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 27/02/2016, 04:46 PM   #1
Dokins
Banned
 
Join Date: Jun 2010
Posts: 1,648
Reputation: 53
Default Should I be concerned about this AMX size?

After noticing my AMX file is 85MB and my PWN is 992KB I was concerned that the AMX shouldn't be that much...Would this have any affect on game play?

I'm almost about to cry, but any advice would help.

Thanks,
Grant.
Dokins is offline   Reply With Quote
Old 27/02/2016, 04:51 PM   #2
SyS
High-roller
 
SyS's Avatar
 
Join Date: Oct 2015
Posts: 1,949
Reputation: 504
Default Re: Should I be concerned about this AMX size?

no but sometimes the amx file size may effect as due to false compilations (runtime errors) and increased array indexes
but for file size 999kb 85 mb is good

Last edited by SyS; 01/03/2016 at 01:07 PM.
SyS is offline   Reply With Quote
Old 27/02/2016, 04:54 PM   #3
Dokins
Banned
 
Join Date: Jun 2010
Posts: 1,648
Reputation: 53
Default Re: Should I be concerned about this AMX size?

I did have a slight heart attack. Thank you for your kind reply. I appreciate it.
Dokins is offline   Reply With Quote
Old 27/02/2016, 05:01 PM   #4
Infinity
High-roller
 
Infinity's Avatar
 
Join Date: Jul 2009
Posts: 1,226
Reputation: 975
Default Re: Should I be concerned about this AMX size?

Do you perhaps have unreasonably large arrays? An increase of that magnitude seems a bit odd.
__________________

I apologize for the stupidity of my fellow members

Quote:
Originally Posted by !damo!spiderman View Post
Stand for something that's going to help the world rather than fill it with more hate. Give someone a hug, tell someone you care... Do something, do anything but do it with love not hate.
Infinity is offline   Reply With Quote
Old 27/02/2016, 05:06 PM   #5
Dokins
Banned
 
Join Date: Jun 2010
Posts: 1,648
Reputation: 53
Default Re: Should I be concerned about this AMX size?

Uhhh, I've been through them, not really seeing anything abnormal entirely.
Dokins is offline   Reply With Quote
Old 27/02/2016, 05:16 PM   #6
justinnater
Huge Clucker
 
justinnater's Avatar
 
Join Date: Jan 2011
Posts: 249
Reputation: 85
Default Re: Should I be concerned about this AMX size?

One current gamemode that I have is 75mb and nothing is wrong with it.
Reason for that was the high limit of arrays / defines
justinnater is offline   Reply With Quote
Old 27/02/2016, 05:30 PM   #7
Michael B
High-roller
 
Michael B's Avatar
 
Join Date: Oct 2014
Location: Romania
Posts: 1,004
Reputation: 127
Default Re: Should I be concerned about this AMX size?

Well, most of the gamemodes I've seen did not exceed the size of 10mb.
The compiled file size depends not only on the gamemode size itself, but also on the includes. This being said, I assume that most of your script consists in includes.
__________________
Michael B is offline   Reply With Quote
Old 27/02/2016, 05:46 PM   #8
Dokins
Banned
 
Join Date: Jun 2010
Posts: 1,648
Reputation: 53
Default Re: Should I be concerned about this AMX size?

Most of it is actually in the game mode itself, I don't use many includes.
Dokins is offline   Reply With Quote
Old 27/02/2016, 05:58 PM   #9
Virtual1ty
Banned
 
Join Date: Jun 2009
Location: Croatia (Hrvatska)
Posts: 734
Reputation: 102
Default Re: Should I be concerned about this AMX size?

Using lots of switch cases (eg. case 0...100000) can also cause bigger .amx size.
You definately should be concerned, not that the server couldn't handle it, but it's just a waste of space, normal compiled gamemodes with lots of features should be 10-30 MB max.
Virtual1ty is offline   Reply With Quote
Old 27/02/2016, 05:58 PM   #10
izeatfishz
Huge Clucker
 
izeatfishz's Avatar
 
Join Date: Jun 2012
Posts: 231
Reputation: 43
Default Re: Should I be concerned about this AMX size?

This is a concern, you probably are using oversized strings or infinite loops or leaking memory.
izeatfishz is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Size gets big +rep iBots Scripting Help 9 28/08/2015 09:31 PM
How to change tab size (font size) Zekiloni Client Support 6 14/03/2015 11:33 PM
What is the size of your... Dr.Einstein Everything and Nothing 49 20/11/2013 10:40 PM
[Tool/Web/Other] String checker [length, block size, breaks & tabs] - Is your string size correct? Sinner Tools and Files 13 17/09/2013 08:11 AM
Header size, coder size, data size compiling warning Red_Dragon. Scripting Help 11 16/05/2013 12:58 PM


All times are GMT. The time now is 05:25 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.