SoftbearStudios / mk48

Mk48.io ship combat game
https://mk48.io
GNU Affero General Public License v3.0
314 stars 60 forks source link

I think there is No Multi threading. My system hung because of this game #194

Closed theunhackable closed 1 year ago

theunhackable commented 1 year ago

Describe your feature request

Additional context

finnbear commented 1 year ago

Hi there,

I can't tell if you are referring to playing the game, or hosting your own game server.

It should not be possible for the game client to hang your entire system, because it is sandboxed by your web browser. It it did hang your system, that would involve a browser bug/vulnerability or operating system bug/vulnerability. Even so, if this ever happens again, we would be interested to see a copy/screenshot of the Inspect Element Console. As for multi-threading, the game client would barely benefit from it and it is barely possible in browser-based games.

If you are referring to hosting your own game server... ...the server does have multithreading which can be enabled by changing this line https://github.com/SoftbearStudios/mk48/blob/0b7ba2d3b2b8193f041332d267a2375993e6045e/engine/game_server/Cargo.toml#L40 to have `features = ["rayon"]` instead of `features = []`.