![Laughing :lol:](./images/smilies/icon_lol.gif)
PS, I am curious, what sort of features should I implement here? I feel like there is not much more I can add (Except optimizing rotation, getcustomvars and adding rotation acceleration maybe...) Oh yes and maybe chat feature...
Code: Select all
//Setup the Network Stuff
netmgr->setUpClient();
if(!netmgr->getEstablished())
{
isServer = true;
netmgr->setUpServer();
}
only way is to feed it a single ip thats intended to be server and they have to run it first to ensure that a connection is made otherwise a server is setup instead.Halan wrote:well thing is i want to make a client and check if a game is allready running if not i want to make the client server...
greets,
halan
Code: Select all
bool isServer = false;
Code: Select all
netmgr->setUpClient();
if(!netmgr->getEstablished())
{
netmgr->setUpServer();
isServer = true;
}
Code: Select all
if(isServer)
{
netmgr->updateClient();
}
else
{
netmgr->updateServer();
}
Ok then I recommend using a different instance of netmgr, using the same one as a client AND server is not recommended. Make a client, wait a few seconds for it then check if its established. If its not then delete that netmgr and make a new one with a server.Halan wrote:well thing is i want to make a client and check if a game is allready running if not i want to make the client server...
greets,
halan