Class CraftEngine
java.lang.Object
com.ranull.graves.manager.EntityDataManager
dev.cwhead.GravesX.integration.CraftEngine
- All Implemented Interfaces:
CustomItemStorageProvider
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcreateBlock(org.bukkit.Location location, Grave grave) voidcreateFurniture(org.bukkit.Location location, Grave grave) org.bukkit.plugin.PlugingetCustomBlockId(org.bukkit.block.Block block) getCustomItemId(org.bukkit.inventory.ItemStack itemStack) Returns the custom item identifier for an item.org.bukkit.entity.EntitygetFurnitureBaseEntity(org.bukkit.entity.Entity entity) getFurnitureId(org.bukkit.entity.Entity entity) getGrave(org.bukkit.entity.Entity entity) Retrieves a grave for a specified entity.Unique identifier used as the serialization prefix.booleanbooleanhasFurniture(Grave grave) booleanisCustomBlock(org.bukkit.block.Block block) booleanisCustomBlock(org.bukkit.Location location) booleanisCustomItem(org.bukkit.inventory.ItemStack itemStack) booleanisFurnitureEntity(org.bukkit.entity.Entity entity) org.bukkit.inventory.ItemStackrebuildCustomItem(String id, int amount) Rebuilds an item from a previously stored custom item id.voidvoidremoveBlock(org.bukkit.Location location) voidremoveFurniture(EntityData entityData) voidremoveFurniture(Grave grave) voidremoveFurniture(Map<EntityData, org.bukkit.entity.Entity> entityDataMap) voidMethods inherited from class EntityDataManager
createEntityData, createEntityData, getEntityData, getEntityDataMap, getGrave, getLoadedEntityDataList, removeEntityData, removeEntityData
-
Constructor Details
-
CraftEngine
public CraftEngine(Graves plugin, org.bukkit.plugin.Plugin craftEnginePlugin) throws ReflectiveOperationException - Throws:
ReflectiveOperationException
-
-
Method Details
-
getProviderId
Description copied from interface:CustomItemStorageProviderUnique identifier used as the serialization prefix. Example:CRAFTENGINE ORAXEN ITEMSADDER MMOITEMS
Serialized format:PROVIDER_ID:encoded-item-id:base64-item
- Specified by:
getProviderIdin interfaceCustomItemStorageProvider- Returns:
- provider identifier
-
getCraftEnginePlugin
public org.bukkit.plugin.Plugin getCraftEnginePlugin() -
registerListeners
public void registerListeners() -
unregisterListeners
public void unregisterListeners() -
isCustomItem
public boolean isCustomItem(org.bukkit.inventory.ItemStack itemStack) -
getCustomItemId
Description copied from interface:CustomItemStorageProviderReturns the custom item identifier for an item. Returningnullindicates the item is not handled by this provider.- Specified by:
getCustomItemIdin interfaceCustomItemStorageProvider- Parameters:
itemStack- item to inspect- Returns:
- custom item identifier or null
-
rebuildCustomItem
Description copied from interface:CustomItemStorageProviderRebuilds an item from a previously stored custom item id.- Specified by:
rebuildCustomItemin interfaceCustomItemStorageProvider- Parameters:
id- custom item identifieramount- desired amount- Returns:
- rebuilt item or null if restoration failed
-
createBlock
-
isCustomBlock
public boolean isCustomBlock(org.bukkit.Location location) -
isCustomBlock
public boolean isCustomBlock(org.bukkit.block.Block block) -
getCustomBlockId
-
removeBlock
public void removeBlock(org.bukkit.Location location) -
createFurniture
-
removeFurniture
-
removeFurniture
-
removeFurniture
-
getGrave
Description copied from class:EntityDataManagerRetrieves a grave for a specified entity.- Overrides:
getGravein classEntityDataManager- Parameters:
entity- the entity for which to retrieve the grave.- Returns:
- the grave, or null if not found.
-
getFurnitureBaseEntity
public org.bukkit.entity.Entity getFurnitureBaseEntity(org.bukkit.entity.Entity entity) -
isFurnitureEntity
public boolean isFurnitureEntity(org.bukkit.entity.Entity entity) -
getFurnitureId
-
hasFurniture
-
hasBlock
-