# SpawnStash
SpawnStash is a Paper plugin for Minecraft 1.21.x that places a fake stash at a player's location with a spawner, chest, and shulker box. The stash can overwrite normal blocks in its footprint, the loot is configurable, and staff can receive alerts when players mine near or break a tracked stash.
## Features
## Build
Build the plugin jar with:
The built jar is created at:
## Installation
1. Build the jar with Maven, or use the jar from
2. Stop your Paper server.
3. Put
4. Start the server.
5. Edit
6. Restart the server or reload the plugin through your normal server-management workflow.
## Command
-
- Spawns one fake stash centered on the block at the player's feet.
## Permissions
-
- Allows a player to use
- Default:
-
- Receives mining and grief alerts for tracked stashes
- Default:
## How It Works
When a player runs
Each placed stash is tracked in
Default config:
### Config Options
-
- The mob type used for the spawner
- Example:
-
- The shulker box block type to place
- Example:
-
- A list of items for the chest
- Format:
-
- A list of items for the shulker
- Format:
-
- Turns stash alerts on or off
-
- Sends alerts to the server console
-
- Permission node used to receive player-facing alerts
-
- How close a broken block must be to count as "mining near" a stash
-
- Per-player, per-stash cooldown to prevent alert spam
-
- MiniMessage alert format for nearby mining
-
- MiniMessage alert format for directly breaking a tracked stash block
## Example Config 1: Rich PvP Bait
## Example Config 2: Quiet Admin Honeypot
## Tutorial
### Create a fake stash
1. Join the server with permission to use
2. Stand where you want the stash to appear.
3. Run
4. Check the placed spawner, chest, and shulker box.
### Customize the loot
1. Open
2. Edit
3. Use
4. Save the file and restart the plugin or server.
### Change the shulker box color
1. Open
2. Set
3. Restart and spawn a new stash.
### Turn alerts up or down
1. Set
2. Change
3. Change
4. Give trusted staff the
## Troubleshooting
- The command works but loot is wrong
- Check that item names are valid Bukkit
- Example: use
- The stash does not spawn
- Make sure the footprint is not blocked by protected blocks like
- There are no alerts
- Make sure
- Make sure the receiving staff member has
- Make sure the broken block is either part of the stash or within the configured nearby radius
- A stash stops alerting after it is griefed
- Directly broken stash blocks are removed from tracking once destroyed
## Notes
SpawnStash is a Paper plugin for Minecraft 1.21.x that places a fake stash at a player's location with a spawner, chest, and shulker box. The stash can overwrite normal blocks in its footprint, the loot is configurable, and staff can receive alerts when players mine near or break a tracked stash.
## Features
- Spawns a 3-block fake stash with
/spawnstash - Replaces most blocks in the way instead of failing on occupied space
- Protects special blocks like
BEDROCK, portal blocks, barriers, and command blocks from being overwritten - Lets you customize the chest loot
- Lets you customize the shulker box type and shulker loot
- Lets you customize the spawned mob type in the spawner
- Tracks placed stashes across restarts in
stashes.yml - Sends alerts when players mine near a tracked stash or break part of one
- Java
21 - Maven
3.9+recommended for local builds - A Paper server compatible with
1.21.x - Paper API dependency used by this project:
io.papermc.paper:paper-api:1.21.1-R0.1-SNAPSHOT## Build
Build the plugin jar with:
Code:
mvn -q -DskipTests package
target/SpawnStash-1.0.0.jar## Installation
1. Build the jar with Maven, or use the jar from
target/.2. Stop your Paper server.
3. Put
SpawnStash-1.0.0.jar into your server's plugins folder.4. Start the server.
5. Edit
plugins/SpawnStash/config.yml if you want to change loot, alerts, or the spawner mob.6. Restart the server or reload the plugin through your normal server-management workflow.
## Command
-
/spawnstash- Spawns one fake stash centered on the block at the player's feet.
## Permissions
-
spawnstash.use- Allows a player to use
/spawnstash- Default:
true-
spawnstash.alerts- Receives mining and grief alerts for tracked stashes
- Default:
op## How It Works
When a player runs
/spawnstash, the plugin places:- A spawner at the player's current block
- A chest one block to the east
- A shulker box two blocks to the east
Each placed stash is tracked in
plugins/SpawnStash/stashes.yml. That tracking is used for alerts:nearbyalert: a player breaks a block near a tracked stashgriefalert: a player breaks one of the stash's tracked blocks directly
Default config:
Code:
stash:
spawner-entity: ZOMBIE
shulker-material: SHULKER_BOX
chest-items:
- NETHERITE_INGOT:5
shulker-items:
- DIAMOND:3
- GOLD_INGOT:5
- IRON_INGOT:10
- EMERALD:2
alerts:
enabled: true
notify-console: true
permission: spawnstash.alerts
near-stash-radius: 1
cooldown-seconds: 10
messages:
nearby: "<yellow><player></yellow> is mining near a tracked SpawnStash at <gold><world> <x> <y> <z></gold>. Owner: <aqua><owner></aqua>"
grief: "<red><player></red> broke part of a tracked SpawnStash at <gold><world> <x> <y> <z></gold>. Owner: <aqua><owner></aqua>"
-
stash.spawner-entity- The mob type used for the spawner
- Example:
ZOMBIE, SKELETON, SPIDER-
stash.shulker-material- The shulker box block type to place
- Example:
SHULKER_BOX, RED_SHULKER_BOX, BLACK_SHULKER_BOX-
stash.chest-items- A list of items for the chest
- Format:
MATERIAL:AMOUNT-
stash.shulker-items- A list of items for the shulker
- Format:
MATERIAL:AMOUNT-
alerts.enabled- Turns stash alerts on or off
-
alerts.notify-console- Sends alerts to the server console
-
alerts.permission- Permission node used to receive player-facing alerts
-
alerts.near-stash-radius- How close a broken block must be to count as "mining near" a stash
-
alerts.cooldown-seconds- Per-player, per-stash cooldown to prevent alert spam
-
alerts.messages.nearby- MiniMessage alert format for nearby mining
-
alerts.messages.grief- MiniMessage alert format for directly breaking a tracked stash block
## Example Config 1: Rich PvP Bait
Code:
stash:
spawner-entity: ZOMBIE
shulker-material: RED_SHULKER_BOX
chest-items:
- NETHERITE_INGOT:8
- ENCHANTED_GOLDEN_APPLE:2
shulker-items:
- DIAMOND:16
- GOLD_INGOT:32
- IRON_INGOT:64
- ENDER_PEARL:16
alerts:
enabled: true
notify-console: true
permission: spawnstash.alerts
near-stash-radius: 2
cooldown-seconds: 15
messages:
nearby: "<yellow><player></yellow> is closing in on a fake stash at <gold><world> <x> <y> <z></gold>. Owner: <aqua><owner></aqua>"
grief: "<red><player></red> is griefing a fake stash at <gold><world> <x> <y> <z></gold>. Owner: <aqua><owner></aqua>"
Code:
stash:
spawner-entity: SKELETON
shulker-material: BLACK_SHULKER_BOX
chest-items:
- ANCIENT_DEBRIS:3
shulker-items:
- DIAMOND_BLOCK:2
- EMERALD_BLOCK:4
- TOTEM_OF_UNDYING:1
alerts:
enabled: true
notify-console: true
permission: spawnstash.alerts
near-stash-radius: 1
cooldown-seconds: 30
messages:
nearby: "<gray>Tracked stash disturbance by <white><player></white> at <gold><world> <x> <y> <z></gold>. Owner: <aqua><owner></aqua>"
grief: "<dark_red>Tracked stash block broken by <white><player></white> at <gold><world> <x> <y> <z></gold>. Owner: <aqua><owner></aqua>"
### Create a fake stash
1. Join the server with permission to use
/spawnstash.2. Stand where you want the stash to appear.
3. Run
/spawnstash.4. Check the placed spawner, chest, and shulker box.
### Customize the loot
1. Open
plugins/SpawnStash/config.yml.2. Edit
stash.chest-items and stash.shulker-items.3. Use
MATERIAL:AMOUNT values such as DIAMOND:12.4. Save the file and restart the plugin or server.
### Change the shulker box color
1. Open
config.yml.2. Set
stash.shulker-material to a valid shulker material like BLUE_SHULKER_BOX.3. Restart and spawn a new stash.
### Turn alerts up or down
1. Set
alerts.enabled to true or false.2. Change
alerts.near-stash-radius to decide how close mining has to be.3. Change
alerts.cooldown-seconds if alerts are too noisy.4. Give trusted staff the
spawnstash.alerts permission.## Troubleshooting
- The command works but loot is wrong
- Check that item names are valid Bukkit
Material names- Example: use
GOLD_INGOT, not gold_ingot with spaces or display names- The stash does not spawn
- Make sure the footprint is not blocked by protected blocks like
BEDROCK or portal blocks- There are no alerts
- Make sure
alerts.enabled is true- Make sure the receiving staff member has
spawnstash.alerts- Make sure the broken block is either part of the stash or within the configured nearby radius
- A stash stops alerting after it is griefed
- Directly broken stash blocks are removed from tracking once destroyed
## Notes
- Current stash layout is fixed to a straight 3-block line.
- Alerts track spawned stashes by saved block positions, not by chest contents or metadata.
- Existing tracked stashes are stored in
stashes.ymlinside the plugin data folder.
