Hello everyone! Your friendly neighborhood Kite here.

We have a lot of big things happening behind the scenes right now - and can’t wait to show it to everyone! This week I wanted to discuss the topic of multiplayer networking! A very fun and technical topic but I’ll try to break it down.

During our last alpha test in March/April, we were using Steamworks multiplayer support with player hosted matches. (These are often called “Listen Servers”).

This, in theory, is a really nice option for us indie developers because it essentially means it incurs no costs. One person in a match is acting as host and doing all the heavy lifting so to speak.

However, it’s a double edged sword. During the last alpha, there were a lot of issues that were directly related to players with older hardware and/or poor network connections hosting a match for 7 other players.

If you’re the host, your computer has to handle a lot of calculations and keeping all players in-sync. Some multiplayer games could totally handle this with low system requirements, since 4v4 is not a lot of people and our maps are pretty small. However, you may have noticed there’s a lot of physics going on in MGH! All possessable objects can get knocked around by any and all forces.

Most games do these physics calculations locally on the client - which is to say it may not match up exactly for all players. A chair getting knocked over might fall the other direction, for example, when comparing the results from two different players.

But in our game, the physics objects need to be in sync with all players. If a chair gets knocked over, it’s got to be knocked over very similarly for all players in the match, otherwise you’ll see chairs come to life and start moving that might be, on your screen, several feet away. Not so good.

So in MIDNIGHT GHOST HUNT, the server (host) calculates all the physics and sends “transform instructions” to all the other players in the match a few times a second. These instructions are then used to move the physics object in roughly the same way as it occurred on the server.

Bam, networked physics!

As you might expect, this can cause some serious slowdowns if the machine hosting can’t handle sending all that data, especially if someone is “haunting” in a room with a lot of props.

Also known as the Alpha 2 Lag Switch.

During our next alpha test, we’re planning on testing a new solution. We’re going to be setting up a fleet of dedicated servers that spin up and spin down depending on how many people matchmake.