.amx Size
#6

Quote:
Originally Posted by sizeof(Sky));
Quote:
Originally Posted by UberSocks
What would you define as something 'Where it's not needed'?

Forgive me but I'm a beginner. Just started using strings recently.

But yes, my script does use a lot of [256] strings.
Sorry for the double-post, but apparently my post has received the max-length, lol.

What types of commands have the [256] strings? Can you list them? (Don't copy-paste the whole command, just the syntax for it. E.G: /SetHP <Player ID/Part of Name> <Amount>)
My script is MySQL integrated, so I have used a lot of strings to send and receive data from the database such as queries etc. From skimming through the code, I have noticed that a lot of strings are used to display server information in the console, to which I have logged for several purposes.

For example, this is when a player has typed /deleteitem <Slot Number>

Code:
	new query[256];
	ConnectToDatabase();
	if(PlayerItemsInfo[playerid][slotid][piSQLId] != INVALID_SQL_ID)
	{
	  format(query,sizeof(query),"DELETE FROM players_items WHERE id=%d",PlayerItemsInfo[playerid][slotid][piSQLId]);
		if(mysql_query(query))
	  {
	    printf(" SQL: %s",query);
The only string throughout this part is query[256], and as you can see, is used to print in the server console. There are many alike throughout the entire script. Although there are others which have a different purpose in the script, they are basically used to call and receive information from the database.

Edit
---------------
I think I may have found my problem:

Code:
			new usage[100];
			format(usage, sizeof(usage), "USAGE: /recon [playername/id]");
			SendClientMessage(playerid, COLOR_WHITE, usage);
Reply


Messages In This Thread
.amx Size - by UberSocks - 10.10.2009, 01:37
Re: .amx Size - by (.Aztec); - 10.10.2009, 01:50
Re: .amx Size - by UberSocks - 10.10.2009, 01:52
Re: .amx Size - by (.Aztec); - 10.10.2009, 01:57
Re: .amx Size - by (.Aztec); - 10.10.2009, 02:13
Re: .amx Size - by UberSocks - 10.10.2009, 02:23
Re: .amx Size - by (.Aztec); - 10.10.2009, 02:25
Re: .amx Size - by UberSocks - 10.10.2009, 02:27
Re: .amx Size - by Simon - 10.10.2009, 02:32
Re: .amx Size - by _Vortex - 10.10.2009, 02:34
Re: .amx Size - by Gamer_Z - 06.02.2012, 13:35
Re: .amx Size - by Rac3r - 16.03.2012, 10:25

Forum Jump:


Users browsing this thread: 1 Guest(s)