Rudimentary support for IPv6 in server socket creation
I haven't completely implemented it yet, but I did come up with a basic algorithm to convert the IPv6 address into a 'code' form. I still have to write the code to actually create the socket, though.
This commit is contained in:
@@ -30,7 +30,7 @@ GameType check_server(char* ip_text, char* port_text) {
|
||||
std::string code = connect_code::encode(addr, std::to_string(port));
|
||||
|
||||
/* Create server socket and wait for client to connect */
|
||||
Server* server = new Server(4, ES_UDP, addr.data(), port);
|
||||
Server* server = new Server(check_ip_ver(addr.data()), ES_UDP, addr.data(), port);
|
||||
server->create_socket();
|
||||
display_text_centered("Your code is " + code + "\nWaiting for connection...");
|
||||
std::string response = "";
|
||||
|
Reference in New Issue
Block a user