The Biggest Problem with Minecraft Servers - Why 2b2t is Stuck on 1.12.2

The Biggest Problem with Minecraft Servers - Why 2b2t is Stuck on 1.12.2

SalC1

3 года назад

1,148,344 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

@lukasschrijver5562
@lukasschrijver5562 - 20.01.2024 21:05

🎉

Ответить
@eliteknight2137
@eliteknight2137 - 02.01.2024 13:55

So how 2b2t updated to 1.19 if it couldn't to 1.13?

Ответить
@bumszli5771
@bumszli5771 - 19.09.2023 19:17

Well this aged well

Ответить
@trolazoceja
@trolazoceja - 25.08.2023 05:54

now that the server is updated and runs smoth as butter every kid cries, it is what it is

Ответить
@pudim-8bits841
@pudim-8bits841 - 21.08.2023 07:47

This aged well

Ответить
@bowser3017
@bowser3017 - 18.08.2023 04:45

19 tps on 1.19

Ответить
@PTIllusionFear
@PTIllusionFear - 15.08.2023 02:15

;)))

Ответить
@soulsmwc
@soulsmwc - 13.08.2023 23:50

Folia: Am I a joke to you?

Ответить
@illuinc2781
@illuinc2781 - 03.07.2023 00:18

and here we are july 2023 and the server is still running on 1.12

Ответить
@samabizzle
@samabizzle - 25.06.2023 22:31

Interestingly Minecraft Bedrock Edition does support multi-threading. Perhaps this limitation will be the downfall of Minecraft Java and potentially a steady transition towards using BE.

Ответить
@ResistanceLion
@ResistanceLion - 24.06.2023 15:53

Non-thread safe minecraft still, meh... Microsoft might be experts in it, as how much they do collaborate with intel, so...? What's now, in 2023?

Ответить
@LUCAILPRO530
@LUCAILPRO530 - 17.06.2023 17:59

Who is here from the Hearts of Minecraft's server?

Ответить
@thenormalguy8574
@thenormalguy8574 - 17.06.2023 12:17

folia. regionalised multithreading.
multipaper. each region has its own server.
bungeecord and its forks, including velocity and stuff: multiple servers linked together

Ответить
@reapiu8316
@reapiu8316 - 30.05.2023 16:06

There are now projects like MultiPaper and Folia which make more features multithreaded. 2b2t actually ran Folia for 1 day and had 600 players online at once with nearly 20 TPS.

Ответить
@Miodu_
@Miodu_ - 16.05.2023 11:01

I someone is reading this 2/3 years after, there is a project from papermc that is called folia. Folia is a multithread server and I saw some people even say that its on 2b2t But idk if thats truth

Ответить
@megatkc
@megatkc - 04.05.2023 07:27

Years later. PaperMC launched folia. It's amazing that a few years later it's now possible.

Ответить
@ItzCPU_
@ItzCPU_ - 01.05.2023 21:38

Donut smp with 5k players

Ответить
@JustAnRandomOwl
@JustAnRandomOwl - 07.04.2023 22:39

Me with version spoofing even after 2 years:

Ответить
@Mic_Glow
@Mic_Glow - 22.02.2023 16:45

It's surprising a multi-core cpu can't support hundreds or thousands of players. Especially if they are in separate little groups out of each other's render distance.
Seems like everything is running on one thread :/

Ответить
@eimerhegel427
@eimerhegel427 - 25.01.2023 04:23

Install plugin, epic

Ответить
@jari5169
@jari5169 - 15.01.2023 18:03

moe yang

Ответить
@lassipulkkinen273
@lassipulkkinen273 - 04.01.2023 12:19

Lots of people here are saying "it's not as simple as that; a rewrite would be necessary to implement multithreading". I think that still underestimates the problem. Game engines in general are very, very difficult to parallelize effectively even if you try to plan for it from day one, since they usually lack any useful overarching patterns to make it possible.

edit: Revisiting this now, I have to admit the claim about games in general is kind of nonsense; I'm not sure what I was thinking. The bulk of entity-related logic is often relatively easy to parallelize, and tends to constitute most of the necessary processing as a whole (ignoring rendering, I guess). Minecraft is kind of special in this regard since while you can have all of your 50 ms per tick consumed by entity processing, it might just as well be block updates (hard to parallelize), or just some random ad-hoc piece of bad code that Mojang has neglected for some reason, like the entity tracker mentioned by tranquilcam13 in the replies. While I'll retain my earlier self-indulgent ramble below for historical interests, there is a stronger and more coherent argument to be made here (much the same as tranquilcam13's): the sentiment expressed in the video neglects not only the difficulty of shoehorning parallelism into a 10+ year old codebase originally written in large part by a mental 10- year old, but also the sheer amount of general issues in said codebase, both architectural and algorithmic, irrespective of the single-threaded design. The claim that a lack of parallelism is "the biggest problem" with your game is categorically false when you're doing 2500+ block updates to depower a redstone line, and your entities are giant heap-allocated blobs, since Notch seemingly missed a memo most game developers received sometime during the 2000s. And, um, hopper lag. I just looked into this. For every hopper with no container above, every tick, 2 times per hopper, the game iterates through every chunk section in the y,z plane containing the hopper to find the ones actually near the hopper (because 1-8 hash map lookups would've been too lame, I guess; oh wait, they are doing those, too!), and searches them for item entities. Well, too bad that hit-testing every pair of entities stored in lists is O(n*m). It's not like hoppers, as block entities, might already be stored in a highly-efficient spatial partitioning structure affectionately known as the f***ing block array? Oh well, rant over.
--


Multithreading is not a silver bullet. You need to be able to divide the task at hand into multiple independent pieces that don't depend on each other's outputs, so that they can be executed in parallel. The pieces need to represent a sufficiently large amount of work each, so that synchronization overhead won't outweigh any benefits. This means that the parallelism will need to be implemented in relatively broad sections of the engine that deal with large amounts of data, i.e. going through entities sequentially and parallelizing updates to their x, y and z coordinates won't yield a 200% speedup; it'll be more like -99%.

What turns this from difficult to basically impossible is the baggage of a long-standing synchronous engine on an already existing game. Take block updates, for instance. One might think this would be relatively easy, by executing each step of block updates in parallel writing results to some kind of back buffer, then copying from back to front and repeating until things have settled. There are a couple problems with this approach.
First of all, because block updates may need to modify blocks other than the one being updated, conflicts will need to be handled somehow. Things like redstone torches updating neighboring components aren't too big of a problem by themselves since they will generally agree on what the new blockstate should be, and conflicts between a poweredness update and a destruction of the block, for instance, could be resolved by basically hardcoding an order of precedence for different kinds of updates. However, pistons are hard. When resolving a conflict between two pistons extending into the same block, one of the extensions necessarily can not happen. A cancelling mechanism of some sort is needed. This needs to be able to roll back both the piston arm and any blocks that moved with it, and it needs to be efficient enough not to defeat the point of implementing parallelism. What do you do when a lava source block is simultaneously pushed by a piston and turned into obsidian? There will be many, many corner cases to deal with, and it will be very difficult to maintain a sane implementation that developers can actually work with and add new features on top of without setting off a butterfly effect resulting in inconsistent behavior, dupe glitches and whatnot. It'll be worse than the current Java edition codebase, imagine that.
Second of all, block updates in current Minecraft occur in a "depth-first" order, where any chain effects are processed recursively before proceeding to others triggered by the same update. In the single-threaded case this makes it much easier to deal with the previously discussed problems. However, it would be even harder than the breadth-first approach described above (read: impossible) to parallelize properly. This behavior can be observed in-game in situations such as the piston conflict that I already mentioned, and some voodoo redstone devices actually rely on these details. While breakage between versions is to be expected with weird redstone, a parallelism update would most likely break all of it at once, with the new mechanics potentially being more inconsistent, and less useful.

As others have mentioned, some parts of Minecraft, especially world generation, do lend themselves well to parallelism, and Mojang has already started making changes to take advantage of this. Still, these are a far cry from the fully parallelized engine that people seem to want from them. I hope I've shed some light on why this is never going to happen, not because "Mojang lazy" or whatever, but because it's actually impossible. Certainly easier said than done at the very least.

Ответить
@braniik1108
@braniik1108 - 29.12.2022 12:59

I have heard something about multipaper and that it could hold 1000 players can someone tell me about it more? seems very interesting

Ответить
@cardelf6159
@cardelf6159 - 09.12.2022 04:33

6b6t is jump updating to 1.19.2

Ответить
@themastereal8345
@themastereal8345 - 28.11.2022 12:36

How bout you use bedrock

Ответить
@themastereal8345
@themastereal8345 - 23.11.2022 00:27

Let’s say a server runs on a intel i9 processor, 1 divided 16 multiplied by 100 means that current servers are using 6.5% of a cpu, can you believe it? 250 players = one core, 250 multiplied by 16 equals 4000 players, we are stuck at 250 instead of the 4000 we could have had, this is sad.

Ответить
@theunnamedaccount4009
@theunnamedaccount4009 - 20.11.2022 14:48

Bro I live in Australia and can't connect to any major server with less than 200 ping. So yeah, that

Ответить
@quentin6669
@quentin6669 - 01.11.2022 09:57

It’s hard to have over 200 people on any sever for any game

Ответить
@bastothemax
@bastothemax - 25.10.2022 21:13

Have you looked at something called "MultiPaper"? It allows multiple servers use the same world, so you can theoreticaly have 1000s of players

Ответить
@cyberdaemon
@cyberdaemon - 18.10.2022 21:17

Minecraft Online is also stuck to 1.12.2 lol

Ответить
@typisttheshep5481
@typisttheshep5481 - 13.10.2022 03:32

Are there any mods that fix this?

Ответить
@SilentOnion
@SilentOnion - 27.09.2022 18:17

moeyang

Ответить
@senditvr
@senditvr - 10.09.2022 04:09

2B2T IS UPDATED

Ответить
@Devastator8571
@Devastator8571 - 08.09.2022 20:52

Multithreading has actually been an issue plaguing many video games

Ответить
@donwald3436
@donwald3436 - 29.08.2022 16:58

lol turns out Notch may have made spaghetti code but Jeb makes cobweb code.

Ответить
@nikdog419
@nikdog419 - 21.08.2022 19:19

Ah, so Minecraft servers are in need of one those speciality high frequency (5-6GHz) single core processors.

Ответить
@Scudmaster11
@Scudmaster11 - 06.08.2022 07:40

1.12.2 is my go to version of MC... i can play on almost every server

Ответить
@entropie138
@entropie138 - 31.07.2022 11:39

Imagine you can only have one roughly 200 people inhabit the entire Earth. Any more people and time begins to slow down.

That is life on a multiplayer Minecraft server.
And the most accommodating version is 1.12.2, which is 5 years old!

Ответить
@yoursleepparalysisdemon1828
@yoursleepparalysisdemon1828 - 29.07.2022 06:27

the way he pronounces "mojang"

Ответить
@timeTegus
@timeTegus - 22.07.2022 19:59

Now ther are 2 flaws xD

Ответить
@Ed1ts.X.E
@Ed1ts.X.E - 16.07.2022 13:16

its now on 1.19

Ответить
@hunter2226
@hunter2226 - 10.07.2022 00:23

Bro the way he said Mojang

Ответить
@sokohighkora2479
@sokohighkora2479 - 25.06.2022 22:45

moyang

Ответить
@ferrythemagicalbeing1107
@ferrythemagicalbeing1107 - 25.06.2022 16:27

its mojang not mon somthing

Ответить
@CloudaceMC.2
@CloudaceMC.2 - 15.06.2022 02:02

you could always get someone to write utilizacion mapper for java and trick java into thinking that all the cores wereit's not really that hard it would just be troublesome to optimize for the number of cores on the CPU

Ответить
@AppleNoteAnimation
@AppleNoteAnimation - 12.06.2022 01:39

i need to know its pronunciation moyang or mojang

Ответить
@Jan12700
@Jan12700 - 07.06.2022 22:23

WorldQL could be the solution.

Ответить
@buttscarlton1830
@buttscarlton1830 - 02.06.2022 23:24

i haven't ever played on 2B2T but i think if they brought it all the way up to 1.16+ there would be a massive power difference, with the addition of netherite. some people would get way more netherite than others and there would be even more of a power difference between someone that's been on the server for a long time and a brand new person.

Ответить
@Erkunden1
@Erkunden1 - 01.06.2022 08:19

its on 1.18.2

Ответить
@jenixiv
@jenixiv - 31.05.2022 17:27

@Minecraft @Microsoft



...can you do this on yt lol

Ответить