Module.arguments.push('-mnull', '-snull', '-vsdl:relative_mode');
Module.arguments.push('-mnull', '-snull', '-vsdl');
Module['websocket'] = { url: function(host, port, proto) {
/* openttd.org hosts a WebSocket proxy for the content service. */
if (host == "content.openttd.org" && port == 3978 && proto == "tcp") {
return "wss://bananas-server.openttd.org/";
}
/* Everything else just tries to make a default WebSocket connection.
* If you run your own server you can setup your own WebSocket proxy in
* front of it and let people connect to your server via the proxy. You
* are best to add another "if" statement as above for this. */
if (location.protocol === 'https:') {
/* Insecure WebSockets do not work over HTTPS, so we force
* secure ones. */
return 'wss://';
} else {
/* Use the default provided by Emscripten. */
return null;
} };
Module.preRun.push(function() {
personal_dir = '/home/web_user/.openttd';
content_download_dir = personal_dir + '/content_download'
Status change: