Ok just a short question.
I don't quite understand how to send a string array to the server or client, and what method would be better.

I've tried with string bla[100]; but I couldn't copy text into the array (I've never worked with string arrays before either, and I couldn't figure out how that worked).

Using the text object as an array worked better, I can copy a name to the array locally on the client, however I noticed that by send_string (clientName.string [clientNumber]); did not send the string to the server for some reason.

Maybe it's even better to make entity strings for the names or something the like?

I really don't know what the best choice would be for sending an array of strings or one string from a string array to the client/server.


------ EDIT:

According to the manual

Code:
 function server_event(str)
{
if (event_type == event_join)
{
str_cpy(temp_str,str);
str_cat(temp_str," has joined");
scroll_message(temp_str);
return;
}



what does str contain then when a client joins a server? the player_name or something? it's not described in the manual...

and another thing:

Code:
 SEND_STRING(message_str); } // send that string to all players
// After that, message_str on all clients contains the entered message



So for the record: if I use send_string, the string that I send will replace all the equal strings on the clients/servers, AND will be send as a parameter by the functions on_server/on_client?

thanx in advance.

Last edited by Jostie; 01/07/07 18:37.