Many of us already experience this common problem, usually known as delaying user actions in video games or altering video quality in video calls, but have you ever wondered why this happens?
Before referring to the LAG we must consider that it is the latency, very easily we can define it as the time it takes to transmit an action from our device to another device on the network (usually measured in milliseconds ms), as a basic example we have the ping:
In this example, we send a basic information to our device, called a packet, from our device to a server. When the server receives the packet, it sends a confirmation response to the sender so that he or she knows that the information has arrived correctly; the time it takes to execute this process is known as latency. In an ideal world this should not fail, however, in real life this is affected by the distance between sender and receiver, interference, available bandwidth and other factors.
Knowing this, the LAG is nothing more than a high level of latency, because in the case of an online game, it runs on an external server and from our device we send and receive packages constantly during the course of our game, which send our actions and inform us of other players, when these packages are too late in arriving or sending, we begin to see the actions of others in a delayed way and our actions will be reflected in the server after a long time, causing an effect similar to the following gif:
However, LAG is not something that only affects video games, in fact, as it is a latency problem it affects all applications that depend on the transmission of packets, such as a video call which will begin to distort (in audio and video) if there is a delay in the packets or a high delay in loading a web page.
A common cause of this problem is bandwidth consumption, which briefly can be defined as the maximum number of packets that we can send/receive our actions on the Internet occupying an amount of bandwidth, if a family member is watching Netflix in 4k he is receiving a high amount of information, occupying much of the bandwidth you have and leaving very little for you, causing the already mentioned LAG.
We hope that with this information you can take steps to solve your latency problems, either by increasing your bandwidth or by waiting for the right time to enjoy your favorite movie or game.
Juan Rambal – BackEnd Developer