SimpleNoCropTrample
1.0.0[1.7-1.19] A very simple Spigot Plugin that stops players/mobs from trampling crops.
A very simple Spigot Plugin that stops players/mobs from trampling crops.
I created this because i wasn't able to find an AntiCropTrample/NoCropTrample plugin, which doesn't have tons of useless features like permissions, commands etc. My plugin doesn't require any configuration, just put it in your plugins folder and you're good to go.
This plugin should work with every version from 1.7-1.19. You can use every spigot based server version (Thermos, Magma, ...).
Config
// If true, mobs won't be able to trample crops
disable-mob-trampling: true
// If true, player won't be able to trample crops
disable-player-trampling: true
// List of blocks that count as farmland (FARMLAND for 1.13+ and SOIL for <1.13)
farmlands-blocks:
- FARMLAND
- SOIL
API
This plugin has a simple API that can be used to manipulate crop trampeling for different players/mobs.
You can listen to the CropTrampleEvent and implement your custom logic to add features like permissions or bypasses.
The plugin also uses the event to disable crop trample if the config settings are enabled.
Example
@EventHandler
public void onTrample(CropTrampleEvent event) {
if (event.getCause() == CropTrampleEvent.TrampleCause.PLAYER) {
Player player = (Player) event.getTrampler();
player.sendMessage("You're not able to destroy " + event.getBlock().getType() + "!");
}
}
TrampleCause can either be MOB or PLAYER, depending on what entity tries to destroy the farmland.
Similar projects
Plugin →Let Me Despawn
Improves performance by tweaking mob despawn rules. Say bye to pesky unintentional persistent mobs.
26.2MSueta
JourneyMap
Real-time map used for mapping in-game or your browser as you explore.
15.6MSueta
Emotecraft
Create your own emotes in Minecraft.
7.9MSueta
Simple Tpa
A simple tpa plugin which sends requests
5.4MSueta
Common Network
Forge and Fabric Unified Networking Solution
4.7MSueta
Set Home
A lightweight plugin for players to set their homes.
3.8MSueta