SilkySpawnersX
Claim this plugin
This plugin was imported from Spiget and is currently unclaimed.
Plugin Information
Description
SilkySpawnersX API
The SilkySpawnersX API provides a set of events that allow other plugins to listen to and react to various spawner-related actions handled by SilkySpawnersX. All events are informational only and cannot be cancelled.
Events
⛏️ SpawnerBreakEvent
Fired whenever SilkySpawnersX handles a player breaking a spawner.
Fields:
result(Result enum): SUCCESS or FAILUREplayer(Player): The player who broke the spawnerblock(Block): The spawner blockspawnerType(EntityType): The type of entity the spawner spawnslocation(Location): The location of the spawnerquantity(int): The quantity of spawners droppedwasSpawnerAlreadyTagged(boolean): Whether the spawner was already taggedcontext(Map<String, Object>): Additional context information
Context Keys:
reason(String)world-name(String, e.g. world_the_nether)drop-rate(double)base-rate(double)drop-bonus(double)roll(double)xp-awarded(int)held-tool-name(String)held-tool-enchantments(String)eligible-tools(String)eligible-enchantments(String)is-operator(boolean)
🛠️ SpawnerCraftEvent
Fired whenever a player attempts to craft a spawner through SilkySpawnersX logic.
Fields:
result(Result enum): SUCCESS or FAILUREplayer(Player): The player crafting the spawnerlocation(Location): The location of crafting (may be null)spawnerType(EntityType): The type of entity the spawner spawnsquantity(int): The quantity of spawners craftedtotalCharge(double): The total charge amountcharged(boolean): Whether the player was chargedcontext(Map<String, Object>): Additional context information
Context Keys:
reason(String)world-name(String e.g. world_the_nether)unit-price(double)order-amount(int)formated-total-charge(String, e.g. <$>50)remaining-balance(double)is-operator(boolean)is-creative(boolean)price-modifier(double)
💥 SpawnerExplosionEvent
Fired when a spawner is affected by an explosion and SilkySpawnersX processes a drop outcome.
Fields:
result(Result enum): SUCCESS or FAILUREspawnerType(EntityType): The type of entity the spawner spawnslocation(Location): The location of the spawnerquantity(int): The quantity of spawners droppedcause(String): The entity that triggered the explosioncontext(Map<String, Object>): Additional context information
Context Keys:
reason(String)world-name(String, e.g. world_the_nether)drop-rate(double)roll(double)was-spawner-already-tagged(boolean)
📦 SpawnerPlaceEvent
Fired whenever SilkySpawnersX handles a player placing a spawner item.
Fields:
result(Result enum): SUCCESS or FAILUREreason(String): The reason for the resultplayer(Player): The player placing the spawnerworldName(String, e.g. world_the_nether): The name of the worldlocation(Location): The location where the spawner was placedspawnerType(EntityType): The type of entity the spawner spawnswasTagApplied(boolean): Whether a tag was appliedwasSpawnerAlreadyTagged(boolean): Whether the spawner was already taggedgameMode(GameMode): The player's game modeisOperator(boolean): Whether the player is an operator
🧬 SpawnerTransformEvent
Fired when a player attempts to transform an existing spawner using a spawn egg.
Fields:
result(Result enum): SUCCESS or FAILUREplayer(Player): The player transforming the spawnerlocation(Location): The location of the spawnerentityFromSpawner(EntityType): The original entity type of the spawnerentityFromEgg(EntityType): The new entity type from the spawn eggfinalPrice(double): The final price charged for the transformationcontext(Map<String, Object>): Additional context information
Context Keys:
reason(String)world-name(String, e.g. world_the_nether)monster-name-from-egg(String, e.g. magma cube)monster-name-from-clicked-spawner(String, e.g. magma cube)final-price(double)charged-amount(Double)was-player-charged(boolean)base-price(double)modifier(double)remaining-balance(String)is-operator(boolean)is-creative(boolean)is-spawner-tagged(boolean)
⚙️ SpawnerTransformCommandEvent
Fired when a player attempts to transform a spawner via the transform command.
Fields:
result(Result enum): SUCCESS or FAILUREplayer(Player): The player executing the transform commandlocation(Location): The location where the transformation was attemptedrequestedEntity(EntityType): The entity type requested by the commandspawnerInHandEntity(EntityType): The entity type of the spawner held in handfinalPrice(double): The final price calculated for the command transformationcontext(Map<String, Object>): Additional context information
Context Keys:
reason(String)world-name(String, e.g. world_the_nether)monster-name-from-requested-type(String, e.g. magma cube)monster-name-from-held-spawner(String, e.g. magma cube)final-price(double)charged-amount(Double)was-player-charged(boolean)base-price(double)modifier(double)remaining-balance(String)is-operator(boolean)is-creative(boolean)is-spawner-tagged(boolean)
Usage
To use these events in your plugin, register listeners for the desired events. For example:
@EventHandler
public void onSpawnerBreak(SpawnerBreakEvent event) {
if (event.getResult().isSuccess()) {
// Handle successful spawner break
Player player = event.getPlayer();
EntityType type = event.getSpawnerType();
// Your logic here
}
}
All events extend org.bukkit.event.Event and follow standard Bukkit event patterns.
Minecraft Plugin Badges
Use these badge images in docs, README files, or forum posts.