Interface GEOResource
- All Superinterfaces:
net.kyori.adventure.key.Keyed,org.bukkit.Keyed
public interface GEOResource
extends org.bukkit.Keyed
A
GEOResource is a virtual resource that can be thought of as world-gen.
However it cannot be found in a World.
This resource only exists in memory and can be retrieved through a GEOMiner
or similar devices.
A GEOResource can be detected via the GEOScanner.- Author:
- TheBusyBiscuit
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionintgetDefaultSupply(org.bukkit.World.Environment environment, org.bukkit.block.Biome biome) Returns the default supply of this resource in that biomeorg.bukkit.inventory.ItemStackgetItem()ThisItemStackis used for display-purposes in the GEO Scanner.intReturns how much the value may deviate from the default supply (positive only).getName()Returns the name of this resource (e.g.default StringgetName(org.bukkit.entity.Player p) This method returns a localized name for thisGEOResourcein theLanguagethe givenPlayerselected.booleanReturns whether this Resource can be obtained using a GEO Miner.default voidregister()Registers this GEO ResourceMethods inherited from interface org.bukkit.Keyed
getKey, key
-
Method Details
-
getDefaultSupply
int getDefaultSupply(@Nonnull org.bukkit.World.Environment environment, @Nonnull org.bukkit.block.Biome biome) Returns the default supply of this resource in that biome- Parameters:
environment- TheWorld.Environmentthis area is currently in (NORMAL / NETHER / THE_END)biome- TheBiomethis area is currently in.- Returns:
- The default supply found in a
Chunkwith the givenBiome
-
getMaxDeviation
int getMaxDeviation()Returns how much the value may deviate from the default supply (positive only).- Returns:
- The deviation or spread of the supply
-
getName
Returns the name of this resource (e.g. "Oil")- Returns:
- The name of this Resource
-
getItem
@Nonnull org.bukkit.inventory.ItemStack getItem()ThisItemStackis used for display-purposes in the GEO Scanner. But will also determine the Output of the GEO Miner, if it is applicable for that.- Returns:
- The
ItemStackversion of this Resource.
-
isObtainableFromGEOMiner
boolean isObtainableFromGEOMiner()Returns whether this Resource can be obtained using a GEO Miner. This will automatically add it to the GEO - Miner.- Returns:
- Whether you can get obtain this resource using a GEO Miner.
-
register
default void register()Registers this GEO Resource -
getName
This method returns a localized name for thisGEOResourcein theLanguagethe givenPlayerselected.- Parameters:
p- ThePlayerto localize the name for.- Returns:
- The localized name for this
GEOResource
-