TestRunnerSRL / bizhawk-co-op

Syncs inventory, ammo, and more of multiple players for a coop experience
GNU Lesser General Public License v3.0
56 stars 41 forks source link

Add a stand-alone co-op server compatible with existing clients. #48

Open bmclarnon opened 4 years ago

bmclarnon commented 4 years ago

This server only supports a single room and would be run by a player as an alternative to hosting from within BizHawk. Advantages include (1) lower load on BizHawk, (2) no susceptibility to BizHawk crashes, and (3) support for hundreds of players.

The server should be fully functional, and should work with all games supported by bizawk-co-op. However, it has had little to no testing with LttP/MZM and only basic testing with OoT. The server is very much experimental -- I'm only proposing merging it into dev so that other people can help with testing if they're interested. Since the server is written in Go and duplicates much of the Lua network logic, it may prove to be not worth the maintenance effort. In that case, I have no objections to the dedicated server being deleted.

I apologize for the very large pull request; I couldn't find a more concise way to duplicate (and test) such a large portion of the existing Lua code. I considered running that Lua code directly, but it proved tricky to noninvasively separate the networking code from the UI code and ramcontroller code, both of which rely on BizHawk-specific functions. The various commits should be pretty self-contained; if a thorough review is desired, it may be easiest to review one commit at a time.

Hamsda commented 4 years ago

@bmclarnon you may want to get in contact with dragonbane0 on the OoTR discord if you haven't already. He is currently working on "multiworld 2.0" and much of what you are working on seems to strife for the same goals.

bmclarnon commented 4 years ago

Thanks for the heads up! I had a conversation in dev-public-talk a few weeks ago with dragonbane0 and TreZc0_. db0 said that he wasn't worried about a stand-alone server since it supports MZM and aLttP, and MW 2.0 is OoT-only. Also, since it isn't a hosted solution, it's more of an alternative to hosting in BizHawk instead of MW 2.0's centralized server. I argued that this should be experimental -- if it doesn't prove useful or if MW 2.0 rolls out faster than expected, then we can delete it.