This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Updated: 26.Nov.2025 - working again after some adjustments! | |
| Reading is annoying some times, but read before start pasting commands. | |
| This installs simhub per game, so you have to install it for each game. | |
| All commands in a terminal as regular user, never as root. | |
| Info: Linux games are isolated 'Compatibility Vessels' per game, it may look weird, but after understanding it better its | |
| quite handy, if something goes wrong you just delete the whole 'vessel' and start from scratch, as if windows was reinstalled. | |
| The vessel for each game has an unique ID. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // utilizes the browser eventsystem | |
| // usefull in cases where you need communication between independent components | |
| // registered events are automatically removed onunload with preserving any other onunload handler | |
| var eventsMixin = function(target) { | |
| var _subscriptions = []; | |
| target.broadcast = function(type, payload) { | |
| var ev = new CustomEvent(type, { | |
| detail: payload, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /***************************************** | |
| /* DOM touch support module | |
| /*****************************************/ | |
| if (!window.CustomEvent) { | |
| window.CustomEvent = function (event, params) { | |
| params = params || { bubbles: false, cancelable: false, detail: undefined }; | |
| var evt = document.createEvent('CustomEvent'); | |
| evt.initCustomEvent(event, params.bubbles, params.cancelable, params.detail); | |
| return evt; | |
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var WebSocketServer = require('ws').Server; | |
| var wss = new WebSocketServer({port: 8080}); | |
| var jwt = require('jsonwebtoken'); | |
| /** | |
| The way I like to work with 'ws' is to convert everything to an event if possible. | |
| **/ | |
| function toEvent (message) { | |
| try { |