1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-08-19 04:29:09 +00:00

Change: use TCP for everything except for master-server and initial server scan (#9130)

This means that pressing Refresh button and adding servers manually
now uses TCP.

The master-server and initial scan are still UDP as they will be
replaced by Game Coordinator; no need to change this now.

If we query a server that is too old, show a proper warning to the
user informing him the server is too old.
This commit is contained in:
Patric Stout
2021-04-30 11:34:47 +02:00
committed by GitHub
parent f00564eeb2
commit 69118d063f
8 changed files with 78 additions and 43 deletions

View File

@@ -65,10 +65,14 @@ Module.preRun.push(function() {
}
window.openttd_server_list = function() {
add_server = Module.cwrap("em_openttd_add_server", null, ["string", "number"]);
add_server = Module.cwrap("em_openttd_add_server", null, ["string"]);
/* Add servers that support WebSocket here. Example:
* add_server("localhost", 3979); */
/* Add servers that support WebSocket here. Examples:
* add_server("localhost");
* add_server("localhost:3979");
* add_server("127.0.0.1:3979");
* add_server("[::1]:3979");
*/
}
var leftButtonDown = false;