Class GravesXAPI
Graves are created with various configurations, including equipment, items, experience, protection, and more. The API also handles event triggering when graves are created and ensures data is stored correctly.
-
Constructor Summary
ConstructorsConstructorDescriptionGravesXAPI
(Graves plugin) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. -
Method Summary
Modifier and TypeMethodDescriptionvoid
abandonGrave
(@NotNull Grave grave) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
autoLootGrave
(@NotNull org.bukkit.entity.Entity entity, @NotNull org.bukkit.Location location, @NotNull Grave grave) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
breakGrave
(@NotNull Grave grave) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
breakGrave
(@NotNull org.bukkit.Location location, @NotNull Grave grave) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.org.bukkit.Location
chunkStringToLocation
(@NotNull String string) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.chunkToString
(@NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
copyResources
(@NotNull String inputPath, @NotNull String outputPath) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
copyResources
(@NotNull String inputPath, @NotNull String outputPath, boolean overwrite) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.org.bukkit.Particle.DustOptions
createDustOptionsFromHex
(@NotNull String hexColor, float size) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
createGrave
(@NotNull org.bukkit.entity.Entity victim, @Nullable org.bukkit.entity.Entity killer, @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable org.bukkit.Location locationDeath, @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
createGrave
(@NotNull org.bukkit.entity.Entity victim, @Nullable org.bukkit.entity.Entity killer, @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable org.bukkit.Location locationDeath, @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, boolean graveProtection, long graveProtectionTime) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
createGrave
(@NotNull org.bukkit.entity.Entity victim, @Nullable org.bukkit.entity.Entity killer, @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable org.bukkit.Location locationDeath, @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, org.bukkit.event.entity.EntityDamageEvent.DamageCause damageCause, boolean graveProtection, long graveProtectionTime) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
createGrave
(@NotNull org.bukkit.entity.Entity victim, @Nullable org.bukkit.entity.EntityType killerEntityType, int experience, long timeAliveRemaining) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
createGrave
(@NotNull org.bukkit.entity.Entity victim, @Nullable org.bukkit.entity.EntityType killerEntityType, long timeAliveRemaining) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
createGrave
(@NotNull org.bukkit.entity.Entity victim, @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
createGrave
(@NotNull org.bukkit.entity.Entity victim, @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, boolean graveProtection, long graveProtectionTime) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
createGrave
(@NotNull org.bukkit.entity.Entity victim, @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, org.bukkit.event.entity.EntityDamageEvent.DamageCause damageCause) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
createGrave
(@NotNull org.bukkit.entity.Entity victim, @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, org.bukkit.event.entity.EntityDamageEvent.DamageCause damageCause, boolean graveProtection, long graveProtectionTime) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
createGrave
(@NotNull org.bukkit.entity.Entity victim, @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable org.bukkit.Location locationDeath, @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
createGrave
(@NotNull org.bukkit.entity.Entity victim, @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable org.bukkit.Location locationDeath, @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, org.bukkit.event.entity.EntityDamageEvent.DamageCause damageCause) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
createGrave
(@NotNull org.bukkit.entity.Entity victim, @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable org.bukkit.Location locationDeath, @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, org.bukkit.event.entity.EntityDamageEvent.DamageCause damageCause, boolean graveProtection, long graveProtectionTime) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.decodeBase64ToObject
(@NotNull String base64String) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.static void
downloadAndReplacePlugin
(long pluginId, String pluginName, String pluginsFolder, org.bukkit.command.CommandSender commandSender) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.static void
downloadAndReplacePlugin
(String pluginId, String pluginName, String pluginsFolder, org.bukkit.command.CommandSender commandSender) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
dropGraveItems
(@NotNull org.bukkit.Location location, @NotNull Grave grave) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.encodeObjectToBase64
(@NotNull Object object) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
ensureGravesXAddonFolder
(org.bukkit.plugin.Plugin addon) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
equipArmor
(@NotNull org.bukkit.inventory.Inventory inventory, @NotNull org.bukkit.entity.Player player) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
equipItems
(@NotNull org.bukkit.inventory.Inventory inventory, @NotNull org.bukkit.entity.Player player) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.int
exportAddonConfigs
(org.bukkit.plugin.Plugin addon) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.int
exportAddonConfigs
(org.bukkit.plugin.Plugin addon, boolean replaceIfExists) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.getBlockData
(@NotNull org.bukkit.Location location, @NotNull UUID graveUUID, @NotNull String replaceMaterial, @NotNull String replaceData) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.getChunkData
(@NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.org.bukkit.Location
getClosestLocation
(@NotNull org.bukkit.Location locationBase, @NotNull List<org.bukkit.Location> locationList) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.org.bukkit.Color
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.org.bukkit.Color
getColorFromHex
(@NotNull String hex) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.int
getDropPercent
(int experience, float percent) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.getEntityData
(@NotNull org.bukkit.Location location, @NotNull UUID uuidEntity, @NotNull UUID uuidGrave, EntityData.Type type) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.int
getExperienceAtLevel
(int level) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.long
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.long
getGraveAmount
(@Nullable org.bukkit.entity.Player targetPlayer) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.double
getHighestDouble
(@NotNull org.bukkit.entity.Player player, String permission) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.int
getHighestInt
(@NotNull org.bukkit.entity.Player player, @Nullable String permission) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.getHologramData
(@NotNull org.bukkit.Location location, @NotNull UUID uuidEntity, @NotNull UUID uuidGrave, int line) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.int
getInventorySize
(int size) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.getLatestVersion
(int resourceId) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.long
getLevelFromExperience
(long experience) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.getLocationData
(@NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.int
getPlayerDropExperience
(@NotNull org.bukkit.entity.Player player, float expStorePercent) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.int
getPlayerExperience
(@NotNull org.bukkit.entity.Player player) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.com.mojang.authlib.GameProfile
getPlayerGameProfile
(@NotNull org.bukkit.entity.Player player) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.org.bukkit.Rotation
getRotationFromBlockFace
(@NotNull org.bukkit.block.BlockFace face) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.getSkinSignature
(@NotNull org.bukkit.entity.Entity entity) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.getTexture
(@NotNull org.bukkit.entity.Entity entity) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
hasPermission
(@NotNull org.bukkit.entity.Entity entity, @NotNull String permission) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.inventoryToString
(@NotNull org.bukkit.inventory.Inventory inventory) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
isAir
(@NotNull org.bukkit.Material material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
isLava
(@NotNull org.bukkit.Material material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
isNearGrave
(@NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
isNearGrave
(@NotNull org.bukkit.Location location, @NotNull org.bukkit.block.Block block) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
isNearGrave
(@NotNull org.bukkit.Location location, @NotNull org.bukkit.entity.Player player) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
isNearGrave
(@NotNull org.bukkit.Location location, @Nullable org.bukkit.entity.Player player, @Nullable org.bukkit.block.Block block) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
isPlayerHead
(@NotNull String material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
isPlayerHead
(@NotNull org.bukkit.Material material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
isSafeNotSolid
(@NotNull org.bukkit.Material material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
isSafeSolid
(@NotNull org.bukkit.Material material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
isValidYAML
(@NotNull File file) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.boolean
isWater
(@NotNull org.bukkit.Material material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.locationToString
(@NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
register()
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
removeGrave
(@NotNull Grave grave) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
removeOldestGrave
(@NotNull org.bukkit.entity.LivingEntity livingEntity) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.org.bukkit.Location
roundLocation
(@NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
setSkullTexture
(@NotNull org.bukkit.block.Skull skull, @NotNull String name, @NotNull String base64) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
setSkullTexture
(@NotNull org.bukkit.inventory.meta.SkullMeta skullMeta, @NotNull String name, @NotNull String base64) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.org.bukkit.block.BlockFace
simplifyBlockFace
(@NotNull org.bukkit.block.BlockFace face) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.org.bukkit.inventory.Inventory
stringToInventory
(@NotNull org.bukkit.inventory.InventoryHolder inventoryHolder, @NotNull String string, @NotNull String title) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.org.bukkit.Location
stringToLocation
(@NotNull String string) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.void
swingMainHand
(@NotNull org.bukkit.entity.Player player) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1.
-
Constructor Details
-
GravesXAPI
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGravesXAPI(Graves)
.Constructor for initializing the GravesXAPI with the main plugin instance.- Parameters:
plugin
- The main Graves plugin instance.
-
-
Method Details
-
createGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void createGrave(@NotNull @NotNull org.bukkit.entity.Entity victim, @Nullable @Nullable org.bukkit.entity.EntityType killerEntityType, long timeAliveRemaining) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveCreationAPI.createGrave(Entity, EntityType, long)
.Creates a grave for an entity with the basic parameters.- Parameters:
victim
- The entity that died.killerEntityType
- The entity type of the killer.timeAliveRemaining
- The remaining time the grave will stay alive.
-
createGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void createGrave(@NotNull @NotNull org.bukkit.entity.Entity victim, @Nullable @Nullable org.bukkit.entity.EntityType killerEntityType, int experience, long timeAliveRemaining) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveCreationAPI.createGrave(Entity, EntityType, int, long)
.Creates a grave for an entity with the basic parameters.- Parameters:
victim
- The entity that died.killerEntityType
- The entity type of the killer.experience
- The experience the victim had.timeAliveRemaining
- The remaining time the grave will stay alive.
-
createGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void createGrave(@NotNull @NotNull org.bukkit.entity.Entity victim, @Nullable @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Use the equivalent inGraveCreationAPI
.Creates a grave for an entity with the basic parameters.- Parameters:
victim
- The entity that died.killerEntityType
- The entity type of the killer.equipmentMap
- The equipment the victim had at the time of death.itemStackList
- The list of items the victim had at the time of death.experience
- The experience the victim had.timeAliveRemaining
- The remaining time the grave will stay alive.
-
createGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void createGrave(@NotNull @NotNull org.bukkit.entity.Entity victim, @Nullable @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, boolean graveProtection, long graveProtectionTime) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Use the equivalent inGraveCreationAPI
.Creates a grave with additional protection settings.- Parameters:
victim
- The entity that died.killerEntityType
- The entity type of the killer.equipmentMap
- The equipment the victim had at the time of death.itemStackList
- The list of items the victim had at the time of death.experience
- The experience the victim had.timeAliveRemaining
- The remaining time the grave will stay alive.graveProtection
- Whether the grave is protected.graveProtectionTime
- The time for which the grave remains protected.
-
createGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void createGrave(@NotNull @NotNull org.bukkit.entity.Entity victim, @Nullable @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, @Nullable org.bukkit.event.entity.EntityDamageEvent.DamageCause damageCause) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Use the equivalent inGraveCreationAPI
.Creates a grave for an entity with a specific storage type.- Parameters:
victim
- The entity that died.killerEntityType
- The entity type of the killer.equipmentMap
- The equipment the victim had at the time of death.itemStackList
- The list of items the victim had at the time of death.experience
- The experience the victim had.timeAliveRemaining
- The remaining time the grave will stay alive.damageCause
- Damage Caused (nullable).
-
createGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void createGrave(@NotNull @NotNull org.bukkit.entity.Entity victim, @Nullable @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, @Nullable org.bukkit.event.entity.EntityDamageEvent.DamageCause damageCause, boolean graveProtection, long graveProtectionTime) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Use the equivalent inGraveCreationAPI
.Creates a grave for an entity with a specific storage type and additional protection settings.- Parameters:
victim
- The entity that died.killerEntityType
- The entity type of the killer.equipmentMap
- The equipment the victim had at the time of death.itemStackList
- The list of items the victim had at the time of death.experience
- The experience the victim had.timeAliveRemaining
- The remaining time the grave will stay alive.damageCause
- Damage Caused (nullable).graveProtection
- Whether the grave is protected.graveProtectionTime
- The time for which the grave remains protected.
-
createGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void createGrave(@NotNull @NotNull org.bukkit.entity.Entity victim, @Nullable @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable @Nullable org.bukkit.Location locationDeath, @Nullable @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, @Nullable org.bukkit.event.entity.EntityDamageEvent.DamageCause damageCause) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Use the equivalent inGraveCreationAPI
.Creates a grave for an entity at a specific location where the victim died.- Parameters:
victim
- The entity that died.killerEntityType
- The entity type of the killer.locationDeath
- The location where the victim died (nullable).equipmentMap
- The equipment the victim had at the time of death.itemStackList
- The list of items the victim had at the time of death.experience
- The experience the victim had.timeAliveRemaining
- The remaining time the grave will stay alive.damageCause
- Damage Caused (nullable).
-
createGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void createGrave(@NotNull @NotNull org.bukkit.entity.Entity victim, @Nullable @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable @Nullable org.bukkit.Location locationDeath, @Nullable @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, @Nullable org.bukkit.event.entity.EntityDamageEvent.DamageCause damageCause, boolean graveProtection, long graveProtectionTime) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Use the equivalent inGraveCreationAPI
.Creates a grave for an entity at a specific location with protection settings.- Parameters:
victim
- The entity that died.killerEntityType
- The entity type of the killer.locationDeath
- The location where the victim died (nullable).equipmentMap
- The equipment the victim had at the time of death.itemStackList
- The list of items the victim had at the time of death.experience
- The experience the victim had.timeAliveRemaining
- The remaining time the grave will stay alive.damageCause
- Damage Caused (nullable).graveProtection
- Whether the grave is protected.graveProtectionTime
- The time for which the grave remains protected.
-
createGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void createGrave(@NotNull @NotNull org.bukkit.entity.Entity victim, @Nullable @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable @Nullable org.bukkit.Location locationDeath, @Nullable @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Use the equivalent inGraveCreationAPI
.Creates a grave for an entity at a specific location without a killer and no storage type.- Parameters:
victim
- The entity that died.killerEntityType
- The entity type of the killer.locationDeath
- The location where the victim died (nullable).equipmentMap
- The equipment the victim had at the time of death.itemStackList
- The list of items the victim had at the time of death.experience
- The experience the victim had.timeAliveRemaining
- The remaining time the grave will stay alive.
-
createGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void createGrave(@NotNull @NotNull org.bukkit.entity.Entity victim, @Nullable @Nullable org.bukkit.entity.Entity killer, @Nullable @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable @Nullable org.bukkit.Location locationDeath, @Nullable @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Use the equivalent inGraveCreationAPI
.Creates a grave for an entity killed by another entity.- Parameters:
victim
- The entity that died.killer
- The entity that killed the victim (nullable).killerEntityType
- The entity type of the killer.locationDeath
- The location where the victim died (nullable).equipmentMap
- The equipment the victim had at the time of death.itemStackList
- The list of items the victim had at the time of death.experience
- The experience the victim had.timeAliveRemaining
- The remaining time the grave will stay alive.
-
createGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void createGrave(@NotNull @NotNull org.bukkit.entity.Entity victim, @Nullable @Nullable org.bukkit.entity.Entity killer, @Nullable @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable @Nullable org.bukkit.Location locationDeath, @Nullable @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, boolean graveProtection, long graveProtectionTime) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Use the equivalent inGraveCreationAPI
.Creates a grave for an entity killed by another entity with protection settings.- Parameters:
victim
- The entity that died.killer
- The entity that killed the victim (nullable).killerEntityType
- The entity type of the killer.locationDeath
- The location where the victim died (nullable).equipmentMap
- The equipment the victim had at the time of death.itemStackList
- The list of items the victim had at the time of death.experience
- The experience the victim had.timeAliveRemaining
- The remaining time the grave will stay alive.graveProtection
- Whether the grave is protected.graveProtectionTime
- The time for which the grave remains protected.
-
createGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void createGrave(@NotNull @NotNull org.bukkit.entity.Entity victim, @Nullable @Nullable org.bukkit.entity.Entity killer, @Nullable @Nullable org.bukkit.entity.EntityType killerEntityType, @Nullable @Nullable org.bukkit.Location locationDeath, @Nullable @Nullable Map<org.bukkit.inventory.EquipmentSlot, org.bukkit.inventory.ItemStack> equipmentMap, @Nullable @Nullable List<org.bukkit.inventory.ItemStack> itemStackList, int experience, long timeAliveRemaining, @Nullable org.bukkit.event.entity.EntityDamageEvent.DamageCause damageCause, boolean graveProtection, long graveProtectionTime) Deprecated, for removal: This API element is subject to removal in a future version.Main method to create a grave with all available parameters.- Parameters:
victim
- The entity that died.killer
- The entity that killed the victim (nullable).killerEntityType
- The entity type of the killer.locationDeath
- The location where the victim died (nullable).equipmentMap
- The equipment the victim had at the time of death.itemStackList
- The list of items the victim had at the time of death.experience
- The experience the victim had.timeAliveRemaining
- The remaining time the grave will stay alive.damageCause
- Damage Caused (nullable).graveProtection
- Whether the grave is protected.graveProtectionTime
- The time for which the grave remains protected.
-
removeGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void removeGrave(@NotNull @NotNull Grave grave) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.removeGrave(Grave)
.Removes the specified grave from the grave manager.- Parameters:
grave
- the grave to be removed
-
breakGrave
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.breakGrave(Grave)
.Breaks the specified grave, triggering its removal and handling any related events.- Parameters:
grave
- the grave to be broken
-
breakGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void breakGrave(@NotNull @NotNull org.bukkit.Location location, @NotNull @NotNull Grave grave) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.breakGrave(Location, Grave)
.Breaks the specified grave at a given location.- Parameters:
location
- the location where the grave is locatedgrave
- the grave to be broken
-
autoLootGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void autoLootGrave(@NotNull @NotNull org.bukkit.entity.Entity entity, @NotNull @NotNull org.bukkit.Location location, @NotNull @NotNull Grave grave) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.autoLootGrave(Entity, Location, Grave)
.Automatically loots the specified grave for the given entity at the given location.- Parameters:
entity
- the entity that will loot the gravelocation
- the location of the gravegrave
- the grave to be looted
-
abandonGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void abandonGrave(@NotNull @NotNull Grave grave) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.abandonGrave(Grave)
.Marks the specified grave as abandoned, preventing further interaction.- Parameters:
grave
- the grave to be abandoned
-
dropGraveItems
@Deprecated(forRemoval=true, since="4.9.9.1") public void dropGraveItems(@NotNull @NotNull org.bukkit.Location location, @NotNull @NotNull Grave grave) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.dropGraveItems(Location, Grave)
.Drops the items stored in the specified grave at the given location.- Parameters:
location
- the location where the items will be droppedgrave
- the grave whose items are to be dropped
-
removeOldestGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public void removeOldestGrave(@NotNull @NotNull org.bukkit.entity.LivingEntity livingEntity) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.removeOldestGrave(LivingEntity)
.Removes the oldest grave associated with the specified living entity.- Parameters:
livingEntity
- the entity whose oldest grave will be removed
-
isNearGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isNearGrave(@NotNull @NotNull org.bukkit.Location location, @Nullable @Nullable org.bukkit.entity.Player player, @Nullable @Nullable org.bukkit.block.Block block) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.isNearGrave(Location, Player, org.bukkit.block.Block)
.Determines if the specified location is near a grave.This method serves as an overload to allow optional parameters such as a player or a block to be included in the proximity check.
- Parameters:
location
- the location to check for nearby graves (required).player
- the player to consider in the proximity check (optional; nullable).block
- the block to consider in the proximity check (optional; nullable).- Returns:
true
if the location is near a grave, otherwisefalse
.
-
isNearGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isNearGrave(@NotNull @NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.isNearGrave(Location)
.Determines if the specified location is near a grave.This variant of the method omits the player and block parameters.
- Parameters:
location
- the location to check for nearby graves (required).- Returns:
true
if the location is near a grave, otherwisefalse
.
-
isNearGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isNearGrave(@NotNull @NotNull org.bukkit.Location location, @NotNull @NotNull org.bukkit.entity.Player player) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.isNearGrave(Location, Player)
.Determines if the specified location is near a grave, considering a specific player.This variant of the method includes the player parameter but omits the block parameter.
- Parameters:
location
- the location to check for nearby graves (required).player
- the player to consider in the proximity check (required).- Returns:
true
if the location is near a grave, otherwisefalse
.
-
isNearGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isNearGrave(@NotNull @NotNull org.bukkit.Location location, @NotNull @NotNull org.bukkit.block.Block block) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.isNearGrave(Location, org.bukkit.block.Block)
.Determines if the specified location is near a grave, considering a specific block.This variant of the method includes the block parameter but omits the player parameter.
- Parameters:
location
- the location to check for nearby graves (required).block
- the block to consider in the proximity check (required).- Returns:
true
if the location is near a grave, otherwisefalse
.
-
getGrave
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.getGrave(UUID)
.Gets the grave type- Parameters:
uuid
- the uuid of the grave
-
getBlockData
@Deprecated(forRemoval=true, since="4.9.9.1") public BlockData getBlockData(@NotNull @NotNull org.bukkit.Location location, @NotNull @NotNull UUID graveUUID, @NotNull @NotNull String replaceMaterial, @NotNull @NotNull String replaceData) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Access data classes directly as needed; no replacement API.Retrieves the BlockData associated with a grave at a given location.- Parameters:
location
- The location of the grave.graveUUID
- The unique identifier of the grave.replaceMaterial
- The material to replace in the BlockData.replaceData
- Additional data to apply to the BlockData.- Returns:
- A BlockData instance representing the grave at the specified location.
-
getChunkData
@Deprecated(forRemoval=true, since="4.9.9.1") public ChunkData getChunkData(@NotNull @NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Access data classes directly as needed; no replacement API.Retrieves the ChunkData for the chunk containing the specified location.- Parameters:
location
- The location for which to retrieve the chunk data.- Returns:
- A ChunkData instance representing the chunk at the specified location.
-
getEntityData
@Deprecated(forRemoval=true, since="4.9.9.1") public EntityData getEntityData(@NotNull @NotNull org.bukkit.Location location, @NotNull @NotNull UUID uuidEntity, @NotNull @NotNull UUID uuidGrave, @NotNull EntityData.Type type) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Access data classes directly as needed; no replacement API.Retrieves the EntityData for an entity associated with a grave.- Parameters:
location
- The location of the entity.uuidEntity
- The unique identifier of the entity.uuidGrave
- The unique identifier of the grave.type
- The type of the entity.- Returns:
- An EntityData instance representing the entity associated with the grave.
-
getHologramData
@Deprecated(forRemoval=true, since="4.9.9.1") public HologramData getHologramData(@NotNull @NotNull org.bukkit.Location location, @NotNull @NotNull UUID uuidEntity, @NotNull @NotNull UUID uuidGrave, int line) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Access data classes directly as needed; no replacement API.Retrieves the HologramData for a hologram associated with a grave.- Parameters:
location
- The location of the hologram.uuidEntity
- The unique identifier of the entity associated with the hologram.uuidGrave
- The unique identifier of the grave.line
- The line number of the hologram to retrieve.- Returns:
- A HologramData instance representing the hologram associated with the grave.
-
getLocationData
@Deprecated(forRemoval=true, since="4.9.9.1") public LocationData getLocationData(@NotNull @NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Access data classes directly as needed; no replacement API.Retrieves the LocationData for a given location.- Parameters:
location
- The location for which to retrieve data.- Returns:
- A LocationData instance representing the specified location.
-
simplifyBlockFace
@Deprecated(forRemoval=true, since="4.9.9.1") public org.bukkit.block.BlockFace simplifyBlockFace(@NotNull @NotNull org.bukkit.block.BlockFace face) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseLocationAPI.simplifyBlockFace(BlockFace)
.Simplifies a given BlockFace to one of the four cardinal directions (NORTH, EAST, SOUTH, WEST).- Parameters:
face
- The BlockFace to simplify.- Returns:
- The simplified BlockFace.
-
getRotationFromBlockFace
@Deprecated(forRemoval=true, since="4.9.9.1") public org.bukkit.Rotation getRotationFromBlockFace(@NotNull @NotNull org.bukkit.block.BlockFace face) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseLocationAPI.getRotationFromBlockFace(BlockFace)
.Retrieves the Rotation corresponding to a given BlockFace.- Parameters:
face
- The BlockFace for which to retrieve the rotation.- Returns:
- The corresponding Rotation for the specified BlockFace.
-
encodeObjectToBase64
@Deprecated(forRemoval=true, since="4.9.9.1") public String encodeObjectToBase64(@NotNull @NotNull Object object) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.objectToBase64(Object)
.Encodes an object to a Base64 string using Base64Util.- Parameters:
object
- The object to encode.- Returns:
- The Base64 encoded string, or null if encoding fails.
-
decodeBase64ToObject
@Deprecated(forRemoval=true, since="4.9.9.1") public Object decodeBase64ToObject(@NotNull @NotNull String base64String) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.base64ToObject(String)
.Decodes a Base64 string to an object using Base64Util.- Parameters:
base64String
- The Base64 string to decode.- Returns:
- The decoded object, or null if decoding fails.
-
loadClass
@Deprecated(forRemoval=true, since="4.9.9.1") public void loadClass(@NotNull @NotNull String className) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.loadClass(String)
.Loads a class with the specified name using ClassUtil.- Parameters:
className
- The fully qualified name of the class to be loaded.
-
getColor
@Deprecated(forRemoval=true, since="4.9.9.1") public org.bukkit.Color getColor(@NotNull @NotNull String colorName) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.getColor(String)
.Gets the Color corresponding to the given color name using ColorUtil.- Parameters:
colorName
- The name of the color as a string.- Returns:
- The Color corresponding to the given name, or null if no match is found.
-
getColorFromHex
@Deprecated(forRemoval=true, since="4.9.9.1") public org.bukkit.Color getColorFromHex(@NotNull @NotNull String hex) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.getColorFromHex(String)
.Parses a hex color code to a Color using ColorUtil.- Parameters:
hex
- The hex color code as a string (e.g., "#FF5733").- Returns:
- The Color corresponding to the hex color code, or null if the code is invalid.
-
createDustOptionsFromHex
@Deprecated(forRemoval=true, since="4.9.9.1") public org.bukkit.Particle.DustOptions createDustOptionsFromHex(@NotNull @NotNull String hexColor, float size) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.dustFromHex(String, float)
.Creates a Particle.DustOptions object using a hex color code.- Parameters:
hexColor
- The hex color code as a string (e.g., "#FF5733").size
- The size of the dust particle.- Returns:
- A Particle.DustOptions object with the specified color and size, or null if the color code is invalid.
-
hasPermission
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean hasPermission(@NotNull @NotNull org.bukkit.entity.Entity entity, @NotNull @NotNull String permission) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.hasPermission(Entity, String)
.Checks if the specified entity has the given permission using EntityUtil.- Parameters:
entity
- The entity to check.permission
- The permission to check for.- Returns:
true
if the entity has the specified permission,true
if the method is not found, orfalse
if an exception occurs.
-
getPlayerExperience
@Deprecated(forRemoval=true, since="4.9.9.1") public int getPlayerExperience(@NotNull @NotNull org.bukkit.entity.Player player) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.playerTotalXp(Player)
.Gets the total experience of the specified player using ExperienceUtil.- Parameters:
player
- The player to get the experience from.- Returns:
- The total experience of the player.
-
getExperienceAtLevel
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.xpAtLevel(int)
.Gets the experience required to reach a specific level using ExperienceUtil.- Parameters:
level
- The level to get the experience for.- Returns:
- The experience required to reach the specified level.
-
getLevelFromExperience
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.levelFromXp(long)
.Calculates the level from a given amount of experience using ExperienceUtil.- Parameters:
experience
- The experience to calculate the level from.- Returns:
- The level corresponding to the given experience.
-
getDropPercent
@Deprecated(forRemoval=true, since="4.9.9.1") public int getDropPercent(int experience, float percent) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.dropPercent(int, float)
.Calculates the drop percentage of experience using ExperienceUtil.- Parameters:
experience
- The total experience.percent
- The percentage to drop.- Returns:
- The experience drop amount.
-
getPlayerDropExperience
@Deprecated(forRemoval=true, since="4.9.9.1") public int getPlayerDropExperience(@NotNull @NotNull org.bukkit.entity.Player player, float expStorePercent) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.playerDropXp(Player, float)
.Gets the amount of experience a player will drop upon death based on a percentage.- Parameters:
player
- The player to get the drop experience from.expStorePercent
- The percentage of experience to drop.- Returns:
- The amount of experience to drop.
-
moveFile
@Deprecated(forRemoval=true, since="4.9.9.1") public void moveFile(@NotNull @NotNull File file, @NotNull @NotNull String name) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.moveFile(File, String)
.Moves a file to a new location with a new name using FileUtil.- Parameters:
file
- The file to be moved.name
- The new name for the file.
-
copyFile
@Deprecated(forRemoval=true, since="4.9.9.1") public void copyFile(@NotNull @NotNull File file, @NotNull @NotNull String name) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.copyFile(File, String)
(deprecated).Copies a file to a new location with a new name using FileUtil.- Parameters:
file
- The file to be copied.name
- The new name for the copied file.
-
getInventorySize
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseInventoryAPI.getInventorySize(int)
.Gets the appropriate inventory size based on the given size.- Parameters:
size
- The size to be used for determining the inventory size.- Returns:
- The appropriate inventory size.
-
equipArmor
@Deprecated(forRemoval=true, since="4.9.9.1") public void equipArmor(@NotNull @NotNull org.bukkit.inventory.Inventory inventory, @NotNull @NotNull org.bukkit.entity.Player player) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseInventoryAPI.equipArmor(Inventory, Player)
.Equips the player's armor from the given inventory.- Parameters:
inventory
- The inventory containing the armor items.player
- The player to be equipped with armor.
-
equipItems
@Deprecated(forRemoval=true, since="4.9.9.1") public void equipItems(@NotNull @NotNull org.bukkit.inventory.Inventory inventory, @NotNull @NotNull org.bukkit.entity.Player player) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseInventoryAPI.equipItems(Inventory, Player)
.Equips the player's inventory items from the given inventory.- Parameters:
inventory
- The inventory containing the items.player
- The player to be equipped with items.
-
inventoryToString
@Deprecated(forRemoval=true, since="4.9.9.1") public String inventoryToString(@NotNull @NotNull org.bukkit.inventory.Inventory inventory) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseInventoryAPI.inventoryToString(Inventory)
.Converts the given inventory to a string representation.- Parameters:
inventory
- The inventory to be converted.- Returns:
- The string representation of the inventory.
-
stringToInventory
@Deprecated(forRemoval=true, since="4.9.9.1") public org.bukkit.inventory.Inventory stringToInventory(@NotNull @NotNull org.bukkit.inventory.InventoryHolder inventoryHolder, @NotNull @NotNull String string, @NotNull @NotNull String title) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseInventoryAPI.stringToInventory(InventoryHolder, String, String)
.Converts a string representation of an inventory to an Inventory object.- Parameters:
inventoryHolder
- The inventory holder.string
- The string representation of the inventory.title
- The title of the inventory.- Returns:
- The Inventory object.
-
roundLocation
@Deprecated(forRemoval=true, since="4.9.9.1") public org.bukkit.Location roundLocation(@NotNull @NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseLocationAPI.roundLocation(Location)
.Rounds the given location's coordinates to the nearest whole numbers.- Parameters:
location
- The location to be rounded.- Returns:
- A new location with rounded coordinates.
-
locationToString
@Deprecated(forRemoval=true, since="4.9.9.1") public String locationToString(@NotNull @NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseLocationAPI.locationToString(Location)
.Converts a Location object to a string representation.- Parameters:
location
- The location to be converted.- Returns:
- A string representation of the location in the format "world|x|y|z".
-
chunkToString
@Deprecated(forRemoval=true, since="4.9.9.1") public String chunkToString(@NotNull @NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseLocationAPI.chunkToString(Location)
.Converts a chunk's location to a string representation.- Parameters:
location
- The location within the chunk.- Returns:
- A string representation of the chunk in the format "world|chunkX|chunkZ".
-
chunkStringToLocation
@Deprecated(forRemoval=true, since="4.9.9.1") public org.bukkit.Location chunkStringToLocation(@NotNull @NotNull String string) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseLocationAPI.chunkStringToLocation(String)
.Converts a chunk string representation back to a Location object.- Parameters:
string
- The string representation of the chunk in the format "world|chunkX|chunkZ".- Returns:
- A Location object representing the chunk.
-
stringToLocation
@Deprecated(forRemoval=true, since="4.9.9.1") public org.bukkit.Location stringToLocation(@NotNull @NotNull String string) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseLocationAPI.stringToLocation(String)
.Converts a string representation of a location back to a Location object.- Parameters:
string
- The string representation of the location in the format "world|x|y|z".- Returns:
- A Location object.
-
getClosestLocation
@Deprecated(forRemoval=true, since="4.9.9.1") public org.bukkit.Location getClosestLocation(@NotNull @NotNull org.bukkit.Location locationBase, @NotNull @NotNull List<org.bukkit.Location> locationList) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseLocationAPI.getClosestLocation(Location, List)
.Finds the closest location to a given base location from a list of locations.- Parameters:
locationBase
- The base location to compare against.locationList
- The list of locations to search through.- Returns:
- The closest location to the base location, or null if the list is empty.
-
isAir
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isAir(@NotNull @NotNull org.bukkit.Material material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.isAir(Material)
.Checks if the given material is an air block.- Parameters:
material
- The material to check.- Returns:
- True if the material is air, false otherwise.
-
isLava
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isLava(@NotNull @NotNull org.bukkit.Material material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.isLava(Material)
.Checks if the given material is lava.- Parameters:
material
- The material to check.- Returns:
- True if the material is lava, false otherwise.
-
isSafeNotSolid
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isSafeNotSolid(@NotNull @NotNull org.bukkit.Material material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.isSafeNotSolid(Material)
.Checks if the given material is not solid and is safe (i.e., not lava).- Parameters:
material
- The material to check.- Returns:
- True if the material is not solid and safe, false otherwise.
-
isSafeSolid
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isSafeSolid(@NotNull @NotNull org.bukkit.Material material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.isSafeSolid(Material)
.Checks if the given material is solid and safe (i.e., not lava).- Parameters:
material
- The material to check.- Returns:
- True if the material is solid and safe, false otherwise.
-
isWater
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isWater(@NotNull @NotNull org.bukkit.Material material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.isWater(Material)
.Checks if the given material is water.- Parameters:
material
- The material to check.- Returns:
- True if the material is water, false otherwise.
-
isPlayerHead
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isPlayerHead(@NotNull @NotNull org.bukkit.Material material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.isPlayerHead(Material)
.Checks if the given material is a player head.- Parameters:
material
- The material to check.- Returns:
- True if the material is a player head, false otherwise.
-
isPlayerHead
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isPlayerHead(@NotNull @NotNull String material) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.isPlayerHead(String)
.Checks if the given material is a player head.- Parameters:
material
- The material to check via string.- Returns:
- True if the material is a player head, false otherwise.
-
postLog
@Deprecated(forRemoval=true, since="4.9.9.1") public String postLog(@NotNull @NotNull String content) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.postLog(String)
.Posts the given log content to mclo.gs and returns the URL of the posted log.- Parameters:
content
- The log content to be posted.- Returns:
- The URL of the posted log, or null if the post was unsuccessful.
-
getHighestInt
@Deprecated(forRemoval=true, since="4.9.9.1") public int getHighestInt(@NotNull @NotNull org.bukkit.entity.Player player, @Nullable @Nullable String permission) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.highestInt(Player, String)
.Gets the highest integer value associated with a specific permission prefix for the player.- Parameters:
player
- The player whose permissions are being checked.permission
- The permission prefix to search for.- Returns:
- The highest integer value found for the specified permission prefix. Returns 0 if no such permission is found.
-
getHighestDouble
@Deprecated(forRemoval=true, since="4.9.9.1") public double getHighestDouble(@NotNull @NotNull org.bukkit.entity.Player player, String permission) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.highestDouble(Player, String)
.Gets the highest double value associated with a specific permission prefix for the player.- Parameters:
player
- The player whose permissions are being checked.permission
- The permission prefix to search for.- Returns:
- The highest double value found for the specified permission prefix. Returns 0 if no such permission is found.
-
swingMainHand
@Deprecated(forRemoval=true, since="4.9.9.1") public void swingMainHand(@NotNull @NotNull org.bukkit.entity.Player player) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.swingMainHand(Player)
.Triggers the main hand swing animation for the specified player.- Parameters:
player
- The player whose main hand swing animation is to be triggered.
-
copyResources
@Deprecated(forRemoval=true, since="4.9.9.1") public void copyResources(@NotNull @NotNull String inputPath, @NotNull @NotNull String outputPath) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.copyResources(String, String)
.Copies resources from the plugin's JAR file to the specified output path.- Parameters:
inputPath
- The path inside the JAR file to copy from.outputPath
- The path on the file system to copy to.
-
copyResources
@Deprecated(forRemoval=true, since="4.9.9.1") public void copyResources(@NotNull @NotNull String inputPath, @NotNull @NotNull String outputPath, boolean overwrite) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.copyResources(String, String, boolean)
.Copies resources from the plugin's JAR file to the specified output path, with an option to overwrite existing files.- Parameters:
inputPath
- The path inside the JAR file to copy from.outputPath
- The path on the file system to copy to.overwrite
- Whether to overwrite existing files.
-
getSkinSignature
@Deprecated(forRemoval=true, since="4.9.9.1") public String getSkinSignature(@NotNull @NotNull org.bukkit.entity.Entity entity) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseSkinAPI.getSkinSignature(Entity)
.Gets the skin signature of the specified entity if it is a player.- Parameters:
entity
- The entity whose skin signature is to be retrieved.- Returns:
- The skin signature of the player, or null if the entity is not a player or the signature could not be retrieved.
-
setSkullTexture
@Deprecated(forRemoval=true, since="4.9.9.1") public void setSkullTexture(@NotNull @NotNull org.bukkit.block.Skull skull, @NotNull @NotNull String name, @NotNull @NotNull String base64) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseSkinAPI.setSkullTexture(Skull, String, String)
.Sets the texture of a Skull block.- Parameters:
skull
- The Skull block.name
- The name associated with the texture.base64
- The Base64 encoded texture.
-
setSkullTexture
@Deprecated(forRemoval=true, since="4.9.9.1") public void setSkullTexture(@NotNull @NotNull org.bukkit.inventory.meta.SkullMeta skullMeta, @NotNull @NotNull String name, @NotNull @NotNull String base64) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseSkinAPI.setSkullTexture(SkullMeta, String, String)
.Sets the texture of a Skull item stack.- Parameters:
skullMeta
- The SkullMeta item meta.name
- The name associated with the texture.base64
- The Base64 encoded texture.
-
getTexture
@Deprecated(forRemoval=true, since="4.9.9.1") public String getTexture(@NotNull @NotNull org.bukkit.entity.Entity entity) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseSkinAPI.getTexture(Entity)
.Retrieves the texture of the specified entity.- Parameters:
entity
- The entity from which to get the texture.- Returns:
- The Base64 encoded texture string, or null if not found.
-
getPlayerGameProfile
@Deprecated(forRemoval=true, since="4.9.9.1") public com.mojang.authlib.GameProfile getPlayerGameProfile(@NotNull @NotNull org.bukkit.entity.Player player) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseSkinAPI.getPlayerGameProfile(Player)
.Retrieves the GameProfile of the specified player.- Parameters:
player
- The player from which to get the GameProfile.- Returns:
- The GameProfile of the player, or null if not found.
-
getUUID
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.uuidOf(String)
.Converts a string to a UUID.- Parameters:
string
- The string to convert to a UUID.- Returns:
- The UUID if the string is a valid UUID format, otherwise null.
-
getLatestVersion
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.latestSpigotVersion(int)
.Gets the latest version of a resource from SpigotMC.- Parameters:
resourceId
- The ID of the resource on SpigotMC.- Returns:
- The latest version of the resource as a String, or null if an error occurs.
-
isValidYAML
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isValidYAML(@NotNull @NotNull File file) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseUtilAPI.isValidYaml(File)
.Checks if a given file is a valid YAML file.- Parameters:
file
- The file to check.- Returns:
- True if the file is a valid YAML file, otherwise false.
-
isGrave
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.isGrave(Grave)
.This code is added for debugging purposes. Checks if the specified location is a grave's location.- Parameters:
grave
- the grave to check. This always returns true for the provided grave's death location. For more precise checking, useisGrave(Grave, Location)
with a specific location.- Returns:
- true if the location matches the grave's death location, false otherwise.
-
isGrave
@Deprecated(forRemoval=true, since="4.9.9.1") public boolean isGrave(@NotNull @NotNull Grave grave, @NotNull @NotNull org.bukkit.Location location) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.isGrave(Grave, Location)
.Checks if a given location matches the death location of a specific grave.- Parameters:
grave
- the grave to checklocation
- the location to compare with the grave's death location- Returns:
- true if the location matches the grave's death location, false otherwise.
-
getGraveAmount
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.getGraveAmount()
.Returns the total number of graves for all players.This method calls
getGraveAmount(Player)
with anull
argument to count graves without filtering by any specific player.- Returns:
- the total count of graves for all players.
-
getGraveAmount
@Deprecated(forRemoval=true, since="4.9.9.1") public long getGraveAmount(@Nullable @Nullable org.bukkit.entity.Player targetPlayer) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseGraveManagementAPI.getGraveAmount(Player)
.Returns the number of graves associated with a specified player.If
targetPlayer
is provided, only graves owned by this player will be counted. IftargetPlayer
isnull
, all graves are counted.- Parameters:
targetPlayer
- the player whose graves should be counted; ifnull
, counts graves for all players.- Returns:
- the number of graves associated with
targetPlayer
, or the total count of all graves iftargetPlayer
isnull
.
-
downloadAndReplacePlugin
@Deprecated(forRemoval=true, since="4.9.9.1") public static void downloadAndReplacePlugin(long pluginId, String pluginName, String pluginsFolder, org.bukkit.command.CommandSender commandSender) throws IOException Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. CallPluginDownloadUtil
directly from your code.Downloads a plugin from Spiget and saves it to the plugins folder, replacing it if it exists.- Parameters:
pluginId
- The Spigot resource ID of the plugin.pluginName
- The name of the plugin file (without the ".jar" extension).pluginsFolder
- The path to the plugins' folder.commandSender
- The sender to message about progress/result.- Throws:
IOException
- If the download or file operations fail.
-
downloadAndReplacePlugin
@Deprecated(forRemoval=true, since="4.9.9.1") public static void downloadAndReplacePlugin(String pluginId, String pluginName, String pluginsFolder, org.bukkit.command.CommandSender commandSender) throws IOException Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. CallPluginDownloadUtil
directly from your code.Downloads a plugin from Spiget and saves it to the plugins folder, replacing it if it exists.- Parameters:
pluginId
- The Spigot resource ID of the plugin.pluginName
- The name of the plugin file (without the ".jar" extension).pluginsFolder
- The path to the plugins' folder.commandSender
- The sender to message about progress/result.- Throws:
IOException
- If the download or file operations fail.
-
ensureGravesXAddonFolder
@Deprecated(forRemoval=true, since="4.9.9.1") public void ensureGravesXAddonFolder(org.bukkit.plugin.Plugin addon) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseAddonAPI.ensureAddonFolder(Plugin)
.Ensures creation of an addon folder.- Parameters:
addon
- The addon to register
-
exportAddonConfigs
@Deprecated(forRemoval=true, since="4.9.9.1") public int exportAddonConfigs(org.bukkit.plugin.Plugin addon) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseAddonAPI.exportAddonConfigs(Plugin)
.Exports addon configs- Parameters:
addon
- the addon to get configs from- Returns:
- the addons exported
-
exportAddonConfigs
@Deprecated(forRemoval=true, since="4.9.9.1") public int exportAddonConfigs(org.bukkit.plugin.Plugin addon, boolean replaceIfExists) Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. UseAddonAPI.exportAddonConfigs(Plugin, boolean)
.Exports addon configs- Parameters:
addon
- the addon to get configs fromreplaceIfExists
- replace configs even if they exist- Returns:
- the addons exported
-
getGravesX
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Prefer using the typed sub-APIs fromGravesXAPI
.Retrieves the instance of theGraves
class.Warning: Using this method can have undesirable results. Unless you know what you are doing, we recommend using other methods.
- Returns:
- the
Graves
instance.
-
getInstance
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. This self-reference is obsolete; holdGravesXAPI
instead.Gets the instance of the GravesXAPI.- Returns:
- The instance of the API.
-
register
Deprecated, for removal: This API element is subject to removal in a future version.Since 4.9.9.1. Register your own listeners where needed; this API class is being removed.Registers the API as an event listener in the plugin manager.
-
GravesXAPI
. Use:GravesXApi#gravesCreate
for grave creationGravesXApi#gravesManage
for management actionsGravesXApi#world
for location/block-face helpersGravesXApi#inventory
for inventory helpersGravesXApi#skin
for textures and profilesGravesXApi#addon
for addon folder/config exportGravesXApi#util
for utilities (permissions, XP, colors, files, YAML, paste, etc.)