Описание

# GetSpawners
Ever wanted to move a mob spawner? With GetSpawners, you can now pick up and move monster spawners.
When a player mines a spawner with a Silk Touch pickaxe, the spawner drops as an item and keeps its mob type.
With this mod, you can give yourself a spawner containing any mob that has a spawn egg in Minecraft using a simple command.
---
## ✨ Features
- Mine and move spawners.
- Spawner item keeps its mob type.
- `/gs give` gives working spawners with a selected type.
- `/gs set` retunes the spawner stack in your active slot to a selected type.
- `/gs types` lists all available types.
- Optional LuckPerms integration (config toggle).
- Optional Mod Menu + Cloth Config integration for an in-game config screen on the client.
---
## ⚙️ Configuration
Config path:
- `config/getspawners.json`
Options:
- `useLuckPerms` (default: `false`)
- `noSilkTouchSpawners` (default: `false`)
- `allowEveryoneGiveCommand` (default: `false`)
- `allowEveryoneTypesCommand` (default: `false`)
- `allowEveryoneSetCommand` (default: `false`)
If you install [Mod Menu](https://modrinth.com/mod/modmenu) and [Cloth Config API](https://modrinth.com/mod/cloth-config) on the client, GetSpawners exposes a full config screen in-game.
Behavior:
- `useLuckPerms=false`: Everyone can mine/place spawners with Silk Touch.
- `noSilkTouchSpawners=false`: Without Silk Touch, spawners break with normal vanilla behavior (destroyed + XP).
- `noSilkTouchSpawners=true`: Bypass the Silk Touch requirement for everyone.
- `allowEveryoneGiveCommand=true`: Everyone can use `/gs give` when LuckPerms is disabled or unavailable.
- `allowEveryoneTypesCommand=true`: Everyone can use `/gs types` when LuckPerms is disabled or unavailable.
- `allowEveryoneSetCommand=true`: Everyone can use `/gs set` when LuckPerms is disabled or unavailable.
- `useLuckPerms=true`: Permission nodes are checked with LuckPerms.
- `getspawners.nosilk` controls the Silk Touch bypass.
- `getspawners.give` controls `/gs give`.
- `getspawners.types` controls `/gs types`.
- `getspawners.set` controls `/gs set`.
- If LuckPerms is not installed, GetSpawners automatically falls back to the non-LuckPerms config behavior and logs a warning.
Example config:
```json
{
// When true, GetSpawners checks LuckPerms permission nodes if LuckPerms is installed.
// If false, GetSpawners uses the config-based behavior instead.
"useLuckPerms": false,
// When true, everyone can bypass the Silk Touch requirement and still collect spawners.
// When false, mining a spawner without Silk Touch uses normal vanilla behavior.
"noSilkTouchSpawners": false,
// When true and LuckPerms is disabled or unavailable, everyone can use /gs give.
// When false, /gs give stays OP-only in config mode.
"allowEveryoneGiveCommand": false,
// When true and LuckPerms is disabled or unavailable, everyone can use /gs types.
// When false, /gs types stays OP-only in config mode.
"allowEveryoneTypesCommand": false,
// When true and LuckPerms is disabled or unavailable, everyone can use /gs set.
// When false, /gs set stays OP-only in config mode.
"allowEveryoneSetCommand": false
}
```
---
## 🎮 Commands
Main command aliases:
- `/getspawners`
- `/gs`
Subcommands:
- `/gs give [amount]`
- `/gs set `
- `/gs types`
- `/gs reload`
Notes:
- `amount` defaults to `1`
- max `amount` is `64`
- `type` includes all mobs with a spawn egg
---
## 🔨 Server-side
This mod runs fully server-side. Clients do not need to install the mod.
Also works in single-player (without LuckPerms support).
Without active LuckPerms permission checks, `/gs give`, `/gs types`, and `/gs set` are OP-only unless their config toggles are enabled.
---
## 🔄 LuckPerms permissions
| Node | Description |
|---|---|
| `getspawners.give` | Access to `/gs give` |
| `getspawners.mine` | Mine and place spawners |
| `getspawners.nosilk` | Bypass Silk Touch requirement |
| `getspawners.set` | Access to `/gs set` |
| `getspawners.types` | Access to `/gs types` |
| `getspawners.reload` | Access to `/gs reload` |
---
### 🌍 LuckPerms quick start
If `useLuckPerms` is enabled, assign nodes like this:
```text
/lp user permission set getspawners.mine true
/lp user permission set getspawners.types true
/lp user permission set getspawners.give true
/lp user permission set getspawners.set true
/lp user permission set getspawners.nosilk true
/lp user permission set getspawners.reload true
```
LuckPerms docs:
- Official wiki: [https://luckperms.net/wiki](https://luckperms.net/wiki)
- Command usage: [https://luckperms.net/wiki/Command-Usage](https://luckperms.net/wiki/Command-Usage)
- GitHub wiki mirror: [https://github.com/LuckPerms/LuckPerms/wiki/Command-Usage](https://github.com/LuckPerms/LuckPerms/wiki/Command-Usage)
---
## 🏜️ Test Server
Feel free to join my Minecraft server to test my mods: `play.swordfishbe.eu`