SPIGOT-7214: Add CraftChunk and CraftChunkSnapshot contains biome method

By: md_5 <git@md-5.net>
This commit is contained in:
Bukkit/Spigot 2023-01-28 11:49:44 +11:00
parent 0bb0794be6
commit c68938c935
2 changed files with 17 additions and 0 deletions

View file

@ -1,6 +1,7 @@
package org.bukkit;
import java.util.Collection;
import org.bukkit.block.Biome;
import org.bukkit.block.Block;
import org.bukkit.block.BlockState;
import org.bukkit.block.data.BlockData;
@ -233,4 +234,12 @@ public interface Chunk extends PersistentDataHolder {
* @return if the block is contained within
*/
boolean contains(@NotNull BlockData block);
/**
* Tests if this chunk contains the specified biome.
*
* @param biome biome to test
* @return if the biome is contained within
*/
boolean contains(@NotNull Biome biome);
}

View file

@ -164,4 +164,12 @@ public interface ChunkSnapshot {
* @return if the block is contained within
*/
boolean contains(@NotNull BlockData block);
/**
* Tests if this chunk contains the specified biome.
*
* @param biome biome to test
* @return if the biome is contained within
*/
boolean contains(@NotNull Biome biome);
}