|
12 | 12 | import net.minestom.server.registry.ProtocolObject; |
13 | 13 | import net.minestom.server.registry.Registry; |
14 | 14 | import net.minestom.server.utils.NamespaceID; |
| 15 | +import net.minestom.server.world.biome.Biome; |
15 | 16 | import org.jetbrains.annotations.Contract; |
16 | 17 | import org.jetbrains.annotations.NotNull; |
17 | 18 | import org.jetbrains.annotations.Nullable; |
@@ -96,10 +97,12 @@ public enum BasicType { |
96 | 97 | name -> Optional.ofNullable(Material.fromNamespaceId(name)).map(Material::id)), |
97 | 98 | FLUIDS("minecraft:fluid", Registry.Resource.FLUID_TAGS, |
98 | 99 | name -> Optional.ofNullable(Fluid.fromNamespaceId(name)).map(Fluid::id)), |
| 100 | + BIOMES("minecraft:worldgen/biome", Registry.Resource.BIOME_TAGS, |
| 101 | + name -> Optional.of(DynamicRegistry.Key.of(name)).map(DynamicRegistry.Key::namespace).map(MinecraftServer.getBiomeRegistry()::getId)), |
99 | 102 | ENTITY_TYPES("minecraft:entity_type", Registry.Resource.ENTITY_TYPE_TAGS, |
100 | 103 | name -> Optional.ofNullable(EntityType.fromNamespaceId(name)).map(EntityType::id)), |
101 | 104 | GAME_EVENTS("minecraft:game_event", Registry.Resource.GAMEPLAY_TAGS, |
102 | | - name -> Optional.ofNullable(EntityType.fromNamespaceId(name)).map(EntityType::id)), |
| 105 | + name -> Optional.ofNullable(GameEvent.fromNamespaceId(name)).map(GameEvent::id)), |
103 | 106 | SOUND_EVENTS("minecraft:sound_event", null, null), // Seems not to be included in server data |
104 | 107 | POTION_EFFECTS("minecraft:sound_event", null, null), // Seems not to be included in server data |
105 | 108 |
|
|
0 commit comments