Netcode
Posted: 16 Mar 2014, 10:10
Even if some players are saying "random", we are obviously not using a random function to determine outcome of event. It's more that there is less precision to see why things fall on one side or another (like the sides of a coin)
So, the goal here is to limit the perception of chaotic situation by display the best choice of information. As engineer, this is a part where we spend not much time at thinking, and I think we can improve by doing it.
For example, for the next update, we have now decided that laser has a priority over rockets when being fired. It was fair before, and it's still fair now, but it's more easy to accept now than before. It's just improved by the rules of display.
For capture of a pole or a door, maybe the rule should be to display 100% only when the message from the server is saying it. But it would make a 99% that would display for long time, not making this really nicer. Whatever we do, it's clear that two people in two different cities in Europe can not know instantly at how much is captured the pole at 15 ms (1500 ms of capture time / 100 scale of 100%) of precision at any given time.
Main reason: there is time taken for the information to travel
You can have 100 ms with this kind of numbers
15 ms from the input of a keyboard, to software process, and waiting for the next packet to leave (netrate)
40 ms ping (upload to server + download from server)
30 ms (server synchro, process, netrate)
15 ms (process at the right time on the client,rendering)
The synchro in between is required to solve the fact that information are going in both side, and if attacker is wishing to take the pole, the defense is also firing a rocket. If two players, in battle, are on the pole, the capture should not move: this equation is made on the server.
The good news is: we have improved this, thansk to netvision & some performance tweaks & display rules
I will avoid to make theorical assumption of any numerical performance increase, since it can not be computed without making tons of arbitral choice of parameters, but I have great hopes that the result will be clearly visible.
However, for taking the decision that a pole is captured, we will still have to wait for the server to acknowledge it from all source of information and then send the packet to all players. What will help here, is that this information will be closer to what you already have on the client, when it arrives. So, it should generate less surprises.
I hope it maksens
So, the goal here is to limit the perception of chaotic situation by display the best choice of information. As engineer, this is a part where we spend not much time at thinking, and I think we can improve by doing it.
For example, for the next update, we have now decided that laser has a priority over rockets when being fired. It was fair before, and it's still fair now, but it's more easy to accept now than before. It's just improved by the rules of display.
For capture of a pole or a door, maybe the rule should be to display 100% only when the message from the server is saying it. But it would make a 99% that would display for long time, not making this really nicer. Whatever we do, it's clear that two people in two different cities in Europe can not know instantly at how much is captured the pole at 15 ms (1500 ms of capture time / 100 scale of 100%) of precision at any given time.
Main reason: there is time taken for the information to travel
You can have 100 ms with this kind of numbers
15 ms from the input of a keyboard, to software process, and waiting for the next packet to leave (netrate)
40 ms ping (upload to server + download from server)
30 ms (server synchro, process, netrate)
15 ms (process at the right time on the client,rendering)
The synchro in between is required to solve the fact that information are going in both side, and if attacker is wishing to take the pole, the defense is also firing a rocket. If two players, in battle, are on the pole, the capture should not move: this equation is made on the server.
The good news is: we have improved this, thansk to netvision & some performance tweaks & display rules
I will avoid to make theorical assumption of any numerical performance increase, since it can not be computed without making tons of arbitral choice of parameters, but I have great hopes that the result will be clearly visible.
However, for taking the decision that a pole is captured, we will still have to wait for the server to acknowledge it from all source of information and then send the packet to all players. What will help here, is that this information will be closer to what you already have on the client, when it arrives. So, it should generate less surprises.
I hope it maksens