Skip to content

Instantly share code, notes, and snippets.

#!/bin/bash
cleanup() {
if [ -n "$MYSQL_CONTAINER_ID" ]; then
echo "Stopping MySQL container..."
sudo docker stop $MYSQL_CONTAINER_ID > /dev/null
fi
if [ -n "$WORDPRESS_CONTAINER_ID" ]; then
echo "Stopping WordPress container..."
@algj
algj / java
Created February 18, 2021 12:31
Spigot Mob Spawner head for resource packs
// don't forget to add craftbukkit.jar of your server version. seriously.
Location loc = player.getLocation();
World world = player.getWorld();
Block block = world.getBlockAt(loc);
BlockState state = block.getState();
state.setType(Material.SPAWNER);
state.update(true);
CreatureSpawner data = (CreatureSpawner) block.getState();
data.setRequiredPlayerRange(0);