How to get a player's name?
#8

Quote:
Originally Posted by Ehab1911
Посмотреть сообщение
Thank you guys, I will try now but what does that number mean in new string[256]; ? What does it effect and what is it, please tell me more about the String[number]
Look at my post, i described what it means. The [number] is called an "array".
An array is a variable in which you can store multiple pieces of data at once and access them dynamically. An array is declared to a set size at compile time so you need to know how many pieces of data you need to store in advance, a good example of this is the very common MAX_PLAYERS array, this will have one slot for every possibly connected player, so you know data for one player will not interfere with data for another player.

And dont use 256, its way too much, and will only cause the server to lagg.

*EDIT*
Lol Ehab, didnt notice it was you (again)
Reply


Messages In This Thread
How to get a player's name? - by Ehab1911 - 19.06.2011, 20:07
Re: How to get a player's name? - by Vince - 19.06.2011, 20:10
Re: How to get a player's name? - by sleepysnowflake - 19.06.2011, 20:17
Re: How to get a player's name? - by sim_sima - 19.06.2011, 20:19
Re: How to get a player's name? - by sim_sima - 19.06.2011, 20:34
Re: How to get a player's name? - by Scenario - 19.06.2011, 20:35
Re: How to get a player's name? - by Ehab1911 - 19.06.2011, 20:37
Re: How to get a player's name? - by sim_sima - 19.06.2011, 20:39
Re: How to get a player's name? - by sleepysnowflake - 19.06.2011, 20:45
Re: How to get a player's name? - by Ehab1911 - 19.06.2011, 20:48

Forum Jump:


Users browsing this thread: 1 Guest(s)