2 ms·
I'm fighting with a variant of this right now - Attempting to build a multiplayer game with dedicated servers & master server authority. I've got 4 computers in
by bob1029 2y ago
I'm fighting with a variant of this right now - Attempting to build a multiplayer game with dedicated servers & master server authority. I've got 4 computers involved to run the full dev iteration (2 for 1v1 clients, 1 for master server and 1 for dedicated server host). The clients I am running in my local LAN with both servers in AWS.
Attempting to do all of this on the local machine will mostly work, but it fails to exercise a lot of the networking concerns (public IP detection, port assignment, etc.), and weird edges crop up as latency grows beyond 0ms. It also makes it impossible to test with other players on other LANs without reaching for complicated networking setups that add even more confusion when things go wrong.
I could write a bunch of bandaid "if editor attached" code throughout, but I also like the idea that I am testing the final thing on the ~final hardware and there isn't going to be any weird dragon fight after this.
- roland35 2y agoIt sounds like your experience is a good example of having a full integration test setup which is basically what the "real thing" is. For doing end to end tests, that is likely required! But as the project matures over time hopefully you can carve out code which can be tested without the network stack.
- viraptor 2y agoHave you seen https://github.com/Shopify/toxiproxy https://github.com/Shopify/toxiproxy ? Maybe you could use this / similar setup to test with more realistic network behaviour.
- bob1029 2y agoI am using UDP transport so options are fairly limited.