Author Topic: Compiled my coding questions into one topic for less spam. Updated:1/3/11  (Read 919 times)

I understand that it is as follows to send a message to every client in the server:
messageall('',%text);
However, I wish to utilize the first argument, yet modifying it seems to do nothing. What is it for?

Secondly, the following command will permanently ban a person with the id of '1' with a reason of "Reason".
What is the first argument, with a value of 0, for?
commandtoserver('ban',0,1,-1,"Reason");


1/3/11
How would I add an item to a players inventory? Not mounting it through mountimage() but ADDING it
« Last Edit: January 03, 2012, 09:06:10 PM by Lugnut1206 »

1: That is the message type. The only example of a registered message type I can think of off the top of my head is MsgAdminForce, which will cause a sound to be played on receiving clients.

2: That would be the object ID of the victim client.

2: That would be the object ID of the victim client.
How would this help me?
If I somehow didn't have the bl_id or something, I could do
talk(findclientbyname(target)); and put the result there?

Sounds like a lot of work.

Arguments for 'ban' argument 1 means the player name argument 2 means the ID argument 3 means the time of the ban and argument 4 is a one letter word that identifies the ban reason.

Arguments for 'ban' argument 1 means the player name argument 2 means the ID argument 3 means the time of the ban and argument 4 is a one letter word that identifies the ban reason.
string that identifies the ban reason*

string that identifies the ban reason*

yes but the string is usually a word.

I have no idea where you're getting "one letter word" from. It can be a string of any length as long as it doesn't exceed the packet size.

yes but the string is usually a word.
if you look up "define string" on google the first somewhat-related thing is "series"
series =/= 1


Then where's the one letter part coming in? I don't understand this at all.

On the banlist, it will only show either the player name or BLID, with BLID being used if a blid is put in, this is true unless you ban from the admin menu.

It's not 1 letter, it can be a string of almost any size, like "undehmbxsrfx" or "hello" or "q"

and if you put quotes around it like I did in the OP it can be multi word too

Oh woops I mistyped it, it has to be one full word but if you want it to be multiple words you have to use the underscore _ instead of spaces.

Oh woops I mistyped it, it has to be one full word but if you want it to be multiple words you have to use the underscore _ instead of spaces.
Only if you're typing it in the chat
If you're manually calling it, you don't need underscores

Oh woops I mistyped it, it has to be one full word but if you want it to be multiple words you have to use the underscore _ instead of spaces.
This is coding help.

You can use spaces in anything but chat.
Things about typing commands in chat don't go in coding help.

I don't want to be mean, but unless you really know what you're talking about, you shouldn't help here.

I'm confused now.

Can you put underscores instead of spaces in ingame chat for multi-word commands to put spaces?
rephrase:are underscores replaced with spaces in ingame commands?