Textfield editable names

This commit is contained in:
Paul Chote
2010-07-10 22:30:28 +12:00
parent dcf13e52c2
commit 56fb711fc6
5 changed files with 54 additions and 43 deletions

View File

@@ -265,18 +265,7 @@ namespace OpenRA.Server
}},
{ "name",
s =>
{
if (s.Trim() == "")
{
SendChatTo( conn, "Blank names are not permitted." );
return true;
}
if (s.Length > 10)
{
s = s.Substring(0,10);
}
{
Console.WriteLine("Player@{0} is now known as {1}", conn.socket.RemoteEndPoint, s);
GetClient(conn).Name = s;
SyncLobbyInfo();