Jump to content

  • Log In with Google      Sign In   
  • Create Account


#ActualDavid Gutiérrez Palma

Posted 25 August 2013 - 02:41 AM

If a tree falls in the forest and no one is around to hear it, does it make a noise?

If all the people interested in the combat is offline, you don't need to calculate the result of that combat until one of the involved players is online. In other words, you should avoid calculations until a player requests the result of the combat and you should use the fast-forward mechanism not only when the player is online, but also when another player who interacts with the player is online:

t0 - P2 decides to attack P1, army will arrive at t5.
t1 - P3 decides to attack P1, army will arrive at t4.
t2 - P4 decides to attack P1, army will arrive at t6.
t3 - Nothing happens
t4 - P3 army should arrive and attack, but since P1 and P3 are offline, we don't need to calculate damage at this moment.
t5 - P2 army should arrive and attack, but since P1 and P2 are offline, we don't need to calculate damage at this moment.
t6 - P4 army should arrive and attack, but since P1 and P4 are offline, we don't need to calculate damage at this moment.

... Much Later ...

P2 connects and the server realizes he attacked P1 at t5, so the server must resolve (using the fast-forward mechanism) not only that combat, but also all the prior actions which involve one of those players before calculating the result of that combat:

- The server calculates the results of the combat between P3 and P1 at t4.
- The server calculates the results of the combat between P2 and P1 at t5.
- The server doesn't need to calculate the results of the combat between P4 and P1 because both of them are offline and this combat happened after the combat between P2 and P1.

#4David Gutiérrez Palma

Posted 25 August 2013 - 02:40 AM

If a tree falls in the forest and no one is around to hear it, does it make a noise?

If all the people interested in the combat is offline, you don't need to calculate the result of that combat until one of the involved players is online. In other words, you should avoid calculations until a player requests the result of the combat and you should use the fast-forward mechanism not only when the player is online, but also when another player who interacts with the player is online:

t0 - P2 decides to attack P1, army will arrive at t5.
t1 - P3 decides to attack P1, army will arrive at t4.
t2 - P4 decides to attack P1, army will arrive at t6.
t3 - Nothing happens
t4 - P3 army should arrive and attack, but since P1 and P3 are offline, we don't need to calculate damage at this moment.
t5 - P2 army should arrive and attack, but since P1 and P2 are offline, we don't need to calculate damage at this moment.
t6 - P4 army should arrive and attack, but since P1 and P4 are offline, we don't need to calculate damage at this moment.

... Much Later ...

P2 connects and the server realizes he attacked P1 at t5, so the server must resolve (using the fast-forward mechanism) not only that combat, but also all the prior actions which involve one of those players before calculating the result of that combat:

- The server calculates the results of the combat between P3 and P1 at t4.
- The server calculates the results of the combat between P2 and P1 at t5.
- The server doesn't need to calculate the results of the combat between P4 and P1 because both of them are offline at this moment and this combat happened after the combat between P2 and P1.

#3David Gutiérrez Palma

Posted 25 August 2013 - 02:39 AM

If a tree falls in the forest and no one is around to hear it, does it make a noise?

If all the people interested in the combat is offline, you don't need to calculate the result of that combat until one of the involved players is online. In other words, you should avoid calculations until a player requests the result of the combat and you should use the fast-forward mechanism not only when the player is online, but also when another player who interacts with the player is online:

t0 - P2 decides to attack P1, army will arrive at t5.
t1 - P3 decides to attack P1, army will arrive at t4.
t2 - P4 decides to attack P1, army will arrive at t6.
t3 - Nothing happens
t4 - P3 army should arrive and attack, but since P1 and P3 are offline, we don't need to calculate damage at this moment.
t5 - P2 army should arrive and attack, but since P1 and P2 are offline, we don't need to calculate damage at this moment.
t6 - P4 army should arrive and attack, but since P1 and P4 are offline, we don't need to calculate damage at this moment.

... Much Later ...

P2 connects and the server realizes he attacked P1 at t5, so the server must resolve (using the fast-forward mechanism) not only that combat, but also all the prior actions which involve one of those players before calculating the result of that combat:

- The server calculates the results of the combat between P3 and P1 at t4.
- The server calculates the results of the combat between P2 and P1 at t5.
- The server doesn't need to calculate the results of the combat between P4 and P1 because both of them are offline at this moment.

#2David Gutiérrez Palma

Posted 25 August 2013 - 02:38 AM

If a tree falls in the forest and no one is around to hear it, does it make a noise?

If all the people interested in the combat is offline, you don't need to calculate the result of that combat until one of the sides is online. In other words, you should avoid calculations until a player requests the result of the combat and you should use the fast-forward mechanism not only when the player is online, but also when another player who interacts with the player is online:

t0 - P2 decides to attack P1, army will arrive at t5.
t1 - P3 decides to attack P1, army will arrive at t4.
t2 - P4 decides to attack P1, army will arrive at t6.
t3 - Nothing happens
t4 - P3 army should arrive and attack, but since P1 and P3 are offline, we don't need to calculate damage at this moment.
t5 - P2 army should arrive and attack, but since P1 and P2 are offline, we don't need to calculate damage at this moment.
t6 - P4 army should arrive and attack, but since P1 and P4 are offline, we don't need to calculate damage at this moment.

... Much Later ...

P2 connects and the server realizes he attacked P1 at t5, so the server must resolve (using the fast-forward mechanism) not only that combat, but also all the prior actions which involve one of those players before calculating the result of that combat:

- The server calculates the results of the combat between P3 and P1 at t4.
- The server calculates the results of the combat between P2 and P1 at t5.
- The server doesn't need to calculate the results of the combat between P4 and P1 because both of them are offline at this moment.

#1David Gutiérrez Palma

Posted 25 August 2013 - 02:38 AM

If a tree falls in the forest and no one is around to hear it, does it make a noise? If all the people interested in the combat is offline, you don't need to calculate the result of that combat until one of the sides is online. In other words, you should avoid calculations until a player requests the result of the combat and you should use the fast-forward mechanism not only when the player is online, but also when another player who interacts with the player is online: t0 - P2 decides to attack P1, army will arrive at t5. t1 - P3 decides to attack P1, army will arrive at t4. t2 - P4 decides to attack P1, army will arrive at t6. t3 - Nothing happens t4 - P3 army should arrive and attack, but since P1 and P3 are offline, we don't need to calculate damage at this moment. t5 - P2 army should arrive and attack, but since P1 and P2 are offline, we don't need to calculate damage at this moment. t6 - P4 army should arrive and attack, but since P1 and P4 are offline, we don't need to calculate damage at this moment. ... Much Later ... P2 connects and the server realizes he attacked P1 at t5, so the server must resolve (using the fast-forward mechanism) not only that combat, but also all the prior actions which involve one of those players before calculating the result of that combat: - The server calculates the results of the combat between P3 and P1 at t4. - The server calculates the results of the combat between P2 and P1 at t5. - The server doesn't need to calculate the results of the combat between P4 and P1 because both of them are offline at this moment.

PARTNERS