Take the 2-minute tour ×
Arqade is a question and answer site for passionate videogamers on all platforms. It's 100% free, no registration required.

Just curious. Say both teams are playing 4v4 teamfight, while one of each is backdooring each nexus.

What could happen if both at the same time do the "destroying blow" to the nexus?

share|improve this question
5  
This is too opinion-based or too specific on how the game/server is coded. Unless someone got knowledge on the code League of legends use, the answers won't help anyone. –  Jonathan Drapeau Aug 27 at 18:30
5  
VTC because this basically requires knowledge of how the game code works. Even if you tried to test it, because it's an online game, there's no way to be certain that you're hitting at exactly the same time, or how the server internally handles near-simultaneous events. –  cloudymusic Aug 27 at 18:33
4  
By the way, this is not off-topic. I'm asking about the existence of a possible different outcome (instead of winning or losing the game). Tell me if I'm wrong: this is like asking if you can save Faridah Malik in Deus Ex HR to get a different ending. Link: gaming.stackexchange.com/questions/29361/… –  Fabián Aug 28 at 7:30
3  
@Fabián You're sort of proving why we don't allow these types of questions in the first place; you're taking the word of someone who may or may not be the developer, and using developer-only knowledge (if it happens to be true). And you accepted it. That's exactly why we don't allow these questions. –  Frank Aug 28 at 21:59
7  
Not sure why no one posted the meta-question here: meta.gaming.stackexchange.com/questions/9901 tl;dr this is not off-topic. –  BlueRaja - Danny Pflughoeft Aug 29 at 20:02

3 Answers 3

up vote 21 down vote accepted

So let's get the obvious thing out of the way:

Yes. It is indeed very possible to destroy the two nexuses at the same "time."

That's because of how "time" works in computer games: discrete intervals that are by no means "tiniest amounts of a second".

This is how most game servers are written, due to the nature of modern computer networks being packet based (that is, in bursts of bits as opposed to a continuous flow of data):

while the game is running:
  collect the players input
  update the game state accordingly
  if anybody has met the winning conditions:
    declare them winner
    stop the game
  send the players the new game state

This loop can be implemented in many ways — especially the "update the world accordingly" part — but the fact remains that this is a loop, and it only runs so many iterations every second.

A typical performance targets here is 30 or 60 updates (or ticks) per second, or an update within 33 or 16 milliseconds (that's short, but certainly not microseconds short!). So long as the Nexuses... Nexi... final bases go down in the same tick, then they've gone down at the same "time." Example with made up numbers:

Tick number         96987 96988 96989 96990 96991 96992
Blue team nexus        69    60    55    30    15     0
Purple team nexus      45    45    30    25    10     0

What Nexus died first here? You can't tell.

Further complicating the matters here is network lag and compensation thereof. From the Valve Developer Community comes this handy graph for the Source Engine:

Server and game ticks

Since packets take time to reach the clients, this means that the clients are playing in the past (and the amount of time they do come in the past depends on their ping), and their user inputs come from even further back. As a result, the server might have to essentially "rewrite history" around them.

In one player's "user input tick 105" packet, you can claim to fire a bullet directly through another player's skull. This other player's "user input tick 105" packet arrives a few moment later, claiming he stepped to the right. Whoops!

Of course the server can't keep things in limbo for too long; there is a grace time after which the server must finally update the world state once and for all, and if the second player's packet arrives too late, then the shot will still count as a headshot.

Nitpickers' corner. Actually in this case, the Source Engine will award the headshot no matter what; this is why heavies for example can kill you "through" walls.

So, at the end of the day, it still is possible to have both nexuses go down at the same time.

Now, since the Nexus can't move around, there is a bunch of optimizations that can or can't be done that muddle the waters significantly more. Unfortunately, this logic is all on the server-side of Riot's; unless a group of 10 players sufficiently close to their data centers can dedicate significant amount of time to SCIENCE, there is little hope that we can figure out how League of Legends actually resolves ties, as it's rather blindingly obvious that the game does not allow ties.

No. It is blindingly obvious that you cannot draw a game.

Riot boasted that in January 2014 27 million players played League of Legends daily. Thus, the lower bound for the number of games played on the service daily is 2.7 million.

Nitpickers' corner. Depending on how you define "player" it is perhaps possible that some of the 27 million players won't actually play at all and just log in to check their profile page or the tribunal or whatever it is that LoL players do. On the other hand many more will play more than one game. At any rate, I don't have a better number to work on.

Now, it is true that I cannot find any report about the possibility of drawing League of Legends games on the internet. This discussion has happened already on the League of Legends forums multiple times (EU NE forums, EU W forums, NA forums, ...); if some player did experience a draw, we would know about it.

Let's guesstimate the odds:

  • 1% of the LoL games ends with both nexi being attacked at the same time.
  • 0.001% of the LoL games ends with both nexi being destroyed in the same tick.

That means the number of draws that would happen every day is 2.7 million × 0.01 × 0.00001 ~= 3. There would be 3 draws per day. The game as grown in popularity over time since 2009, so let's say that averages out to just 2 draw games per day. The game has been out for 1,768 days today, so that's 3,536 draws since ever.

How come we know of no single draw, then?

If draws are so rare, they would make for an excellent YouTube video at least, or for some interesting screenshots. "You won't BELIEVE how this League of Legends game ended!" So you can bet that people would post about them, write about them, upload videos of them. If nothing else, people would write about it in the threads that have come up earlier. Additionally, videos like this would include lines about the game ending in a draw, together with all of the unusued lines, but they don't.

The silence is deafening.

So what?

The only rational explanation is that there can't be draws in League of Legends and that the game server, somehow, resolves ties and awards victory to one and only one team.

There are several ways in which this could happen, and we are unlikely to know which one is being used, everything else being equal:

  • Ties can be resolved always in favour of the same team
  • Ties can be resolved with a coin toss
  • Ties can be resolved to the team with more kills/gold/whatever (although you then need to handle ties for this stat, too)

If I had to guess, I'd agree with a variation on the team "favour team X over team Y every time", as it's the simplest solution to deal with a situation you clearly don't want or can't handle.

share|improve this answer
    
Given how things have gone on other answers, I'm not going to respond to comments; sorry. If I think you have a point I'll simply edit the answer accordingly. –  badp Aug 30 at 9:56
    
So, same conclusion/answer as all of the other answers and mass upvoted and all others mass downvoted. Granted it is better detail, but still... –  dphil Sep 2 at 20:45
1  
I think this answer goes into way more detail than is necessary... that said, as a developer, I agree with everything written here (including how ties are most-likely resolved) –  BlueRaja - Danny Pflughoeft Sep 2 at 23:28

The event you describe, due to the reasons stated by badp, cannot happen.

However, if you destroy the enemy nexus and your team surrenders immediately after, their nexus blows up, but the game screen moves to your nexus, which explodes too and YOU end up losing the game.

Personally witnessed this happen several times.

share|improve this answer
3  
It is better to link to the "reasons stated above" (whether stated in answers or comments), as the answer order is not fixed. –  unor Aug 31 at 13:57

It can't happen. In a computer system, everything essentially rotates with 1 thing happening at a time. It just happens so fast that you don't notice only 1 thing happening at a time.

Someone may say this might not be the case with a server, but the server will still process 1 nexus before the other.

Now, let's say theoretically they do in fact get attacked at the same time. The server will still process one before the other and you could actually argue that the one that blows up first will be randomly determined since the you have no idea where in the state of things what object is in line to be effected next.

EDIT: Fine for those who really want to point out the single situation it could be occur IF the developers foolishly decided to code it this way.

1) We are assuming there is a state change loop.

2) After the state change loop we will assume there is a game process loop.

3) They would have to code in specificially something like if (nexus1.isDead() && nexus2.isDead()).

Even with this info, I will stand by my answer because of how unrealistic it would be to code for this since the game currently does not allow ties at this time.

share|improve this answer
1  
@Vality I think you might be confused about what lockless threading is. This has nothing to do with locking. It's simply when does 1 condition get reached first. Whether something is locked or isn't, 1 condition will still be reached first. –  dphil Aug 27 at 19:45
1  
@Vality Since there is not ties in this game, the only reason to do this is to make it random between the 2 sides I suppose but I still don't find that plausible. The only way locking could apply is your bitfield scenario as well as game update loop and game (reaction? or whatever it would be called) loop. –  dphil Aug 27 at 20:04
1  
@Vality Fine I'll admit it's not impossible, but Lockless loading still doesn't matter. Lockless loading only matters if like you said there is only a single variable for it but lockless loading doesn't matter if there are 2. Either way it is the same scenario irregardless of locking. –  dphil Aug 27 at 20:11
1  
@dphil You are right actually. I should have thought on that more carefully, this could occur even with a lock. Thanks for the correction. –  Vality Aug 27 at 20:13
1  
I feel like I got trolled... even though my answer came to the exact same conclusion as the others, i get downvoted to -5. –  dphil Sep 2 at 14:51

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.