I haven't really tested this with any other object, but I've noticed a strange error/bug when creating a TCPObject, and having a SimGroup be part of it.
Like this.
new TCPObject(TCPServer)
{
IP = $MyTCPIpAddress;
Port = 6788;
Clients = new simGroup();
};
And doing that makes the TCPObject have no name, and if I remember correctly I can't set a name to it.
I solved it by doing this.
%tcpObj = new TCPObject(TCPServer)
{
IP = $MyTCPIpAddress;
Port = 6788;
};
%tcpObj.clients = new simGroup();
Anyway, it's not a problem to me (now), but I am just curious why did this happen, and wanted to know if it happened to anyone else before.
Also as I said before, it's not a problem since it's been solved, but I would like to know what caused this.