Asynchronous operations

I have a question about asynchronous tasks.
When I made plugins for Bukkit/Spigot, you weren’t allowed to do certain things asynchronously, such as create a scoreboard.
Is that the same for Sponge, or are there some things that can be done asynchronously?

Many things can’t be done asynchronously because of Minecraft itself. Many of the restrictions Bukkit in this area are still in effect in Sponge. I’m not sure about Scoreboard itself, but I know you can’t modify the world Asynchronously.

That’s fine, I was just wondering since Sponge is so good at doing everything else.

In one of my projects I’m creating an empty scoreboard in a asynchronous task, seems to work out fine.

Minecraft is single-threaded, and that can’t really be modified. This is why most things can’t be done asynchronously.
However, a lot of object construction can, since builders and such aren’t part of the main thread.

1 Like