Update to Minecraft 1.17

By: md_5 <git@md-5.net>
This commit is contained in:
Bukkit/Spigot
2021-06-11 15:00:00 +10:00
parent 2e1a3720cf
commit 153752dfac
44 changed files with 3379 additions and 958 deletions

View File

@@ -170,6 +170,25 @@ public interface Registry<T extends Keyed> extends Iterable<T> {
* @see Fluid
*/
Registry<Fluid> FLUID = new SimpleRegistry<>(Fluid.class);
/**
* Game events.
*
* @see GameEvent
*/
Registry<GameEvent> GAME_EVENT = new Registry<GameEvent>() {
@NotNull
@Override
public Iterator iterator() {
return GameEvent.values().iterator();
}
@Nullable
@Override
public GameEvent get(@NotNull NamespacedKey key) {
return GameEvent.getByKey(key);
}
};
/**
* Get the object by its key.