I don’t know if my comment will be valuable to the discussion, but after a little research to help myself structure an answer for you and as far as my knowledge goes, when a server supports thousands of players throughout the game world, it has to manage the interactions and movements of each player, as well as changes in the game environment. This requires significant computing resources and network bandwidth. Both on the side of the ISP providing the link to the server and on the player side. However, when many players gather in one place, the server must process and transmit a large amount of data related to the actions and positions of all these players simultaneously. Even if each player is moving around the instantiated map and seemingly alone on it. Here it all depends on how Last Epoch is constructed (because methodologies abound). This can lead to congestion and lag as the server tries to keep up with the increased computing and network requirements. To address this problem, game developers can use various techniques such as load balancing, optimizing server-side code and implementing efficient data transfer protocols to mitigate the impact of player overload in certain areas of the game world as was noticeable yesterday when at one point there were how many players trying to log in… 150k players? In addition, the use of cloud-based server solutions and optimization of network infrastructure can also help deal with such situations more effectively.
Game servers are usually run on dedicated servers, with the server acting as the authoritative source for all game events. This is important due to the fact that in different players may have different latencies resulting in discrepancies in the state of per-player gameplay. They ensure smooth gameplay for all involved so that lag and latency are kept to a minimum and gameplay can be experienced in real time. Game server is constantly receiving and sending data between players. This includes data on where players are, as well as what pickups and equipment they have. Without an established communication link, each player would be experiencing something completely different, and the game would be unresponsive. Multiple times every second, your console or computer sends information about where you are in a game and exactly what you’re doing and it’s also doing that for every other player. Then, multiple times per second, the game server will share all of that consolidated information with every player in the game, so that each player’s console or computer knows what to display. Dedicated game servers don’t run the games themselves. Instead, they allocate GPU, CPU and RAM, and instruct the machines on what to render as an output to players. This doesn’t include what we see, but it does include rendering of game controls and the sounds you hear in-game too. Why? Because it’s far more efficient and reduces the risk of lag, loss of connection and ultimately interrupted gameplay. As players make their decisions in the game, the server processes every input, settles inconsistencies that arise, and transmits regular updates to all players involved. There is an endless stream of snapshots of all elements involved, and the game state is updated every tick.
This tick is a snapshot in time within the game world that shows the properties of every object. With multiple players doing multiple things all at the same time the server needs to keep track of everything that’s happening and when. Once the game state is calculated, it is transmitted to each player’s device by the server – after this, the game world refreshes for every player. And this happens multiple times every second. So - the higher the tickrate, the more precise is this simulation.
As an example, if you have a 64Hz - or “64-tick” - server, then it sends all players 64 updates every second.
As the tickrate goes up, more bandwidth and processing power is required. The load is increased on the server, data is sent more frequently and the game state is calculated more often. A server with a higher tickrate produces a far more precise, high-fidelity gaming experience, allowing split-second actions to be considered by the server, which can often be the difference between victory and defeat.
So in onine games, game servers handle multiple online players simultaneously through a “matchmaking” proces which allows hundreds of players per game instance – when you decide to play, you send a “request” to a matchmaking server. This makes you join a large group of millions of other players who also want to play at the same time you do. The matchmaking server selects players for a game – based on a set of rules such as skill level, kill count and various other metrics depending on a game. Then, it asks for a new process to be launched on one of the many physical (or virtual) machines. This could either happen through a central machine, which sends instructions to one of the machines to start the instance, or directly from one of the machines.
Once the instance is set up, it informs the matchmaker that it’s ready for players to join at an IP address and port. The matchmaker shares this information with all the selected players. Each of these players then connects to this instance, which only focuses on managing these players and their game. After the game, the instance sends information to the matchmaker or a game stats server about the game’s outcome, including details like who won or whatever.
So every action you take like moving your character forward to slay an enemy is sent as a message known as a “packet” (a network packet is a formatted unit of data carried by a packet-switched network. A packet consists of control information and user data; the latter is also known as the payload. Control information provides data for delivering the payload (e.g., source and destination network addresses, error detection codes, or sequencing information). Typically, control information is found in packet headers and trailers. In packet switching, the bandwidth of the transmission medium is shared between multiple communication sessions, in contrast to circuit switching, in which circuits are preallocated for the duration of one session and data is typically transmitted as a continuous bit stream) to the server. The server then shares this message with all the other players in the game, so everyone sees that you’ve performed some kind of action.
This is the process for almost all online multiplayer games. Many online games may use a cloud server or dedicated server to store all player data and run everything in the background - it can also save things like what items you have and where you are in the game. This is important because it stops people from cheating by making their computers do things they shouldn’t be able to do, like getting more powerful items or moving to places they shouldn’t. That’s why Last Epoch have separated online and offline play.
To handle different numbers of players because this number can grow exponentially over time – especially if the game becomes more popular or at long anticipated launch. In one instance, there may only be a handful of players playing at one time, but in just mere minutes or hours, the number of players can go into the millions. If the game server can’t handle this change, it might get too busy and stop working properly when there are a lot of players. By making the server scalable, it can adjust itself to handle more (or fewer players) with ease. This ensures everyone can keep playing the game smoothly, no matter how many people are playing at the same time. At this point you could say “just make scalable servers lol”. It’s not that easy. Game servers need higher specs and software configurations to make sure they work well for players. These configurations help servers run smoothly and handle many players at once. They also keep the game safe from hackers and malware. Plus, a server specially configured for gaming ensures the game runs fast and everyone can play together without any issues. Using a dedicated gaming server gives you more control over the computer and programs that make your game work, as it allows you to change the settings and make the game run even better depending on what you need but cost of such machines are raises with demand and maintenance.
I hope it is understandable as you can see that „it’s not that simple”. „Just buy more server” may not be an appropriate solution while just optimizing its parameters here and there because in the end it may turn out that you spent X thousands on server space to accommodate all the players and in two months you will want to look at the tables and you will see that the investment does not pay off because the number of players after that time is non-proportional to maintenance cost.