Removed unused event.

Fixed sound issue on levelup.
Crops on a lower level will now work just as well as crops on a higher level.
Version increment.
Hoppers now function with farms as designed.
This commit is contained in:
Brianna O'Keefe 2018-09-19 12:42:09 -04:00
parent e63276429e
commit 076e762f4e
5 changed files with 6 additions and 6 deletions

View File

@ -10,7 +10,6 @@ import com.songoda.epicfarming.api.utils.ClaimableProtectionPluginHook;
import com.songoda.epicfarming.api.utils.ProtectionPluginHook;
import com.songoda.epicfarming.command.CommandManager;
import com.songoda.epicfarming.listeners.BlockListeners;
import com.songoda.epicfarming.listeners.EntityListeners;
import com.songoda.epicfarming.listeners.InteractListeners;
import com.songoda.epicfarming.listeners.InventoryListeners;
import com.songoda.epicfarming.farming.EFarm;
@ -143,7 +142,6 @@ public class EpicFarmingPlugin extends JavaPlugin implements EpicFarming {
pluginManager.registerEvents(new BlockListeners(this), this);
pluginManager.registerEvents(new InteractListeners(this), this);
pluginManager.registerEvents(new InventoryListeners(this), this);
pluginManager.registerEvents(new EntityListeners(), this);
// Register default hooks
if (pluginManager.isPluginEnabled("ASkyBlock")) this.register(HookASkyBlock::new);

View File

@ -216,7 +216,7 @@ public class EFarm implements Farm {
player.playSound(player.getLocation(), org.bukkit.Sound.ENTITY_PLAYER_LEVELUP, 0.6F, 15.0F);
} else {
player.playSound(player.getLocation(), org.bukkit.Sound.valueOf("LEVEL_UP"), 2F, 25.0F);
player.playSound(player.getLocation(), org.bukkit.Sound.ENTITY_PLAYER_LEVELUP, 2F, 25.0F);
}
}
tillLand(location);

View File

@ -98,8 +98,9 @@ public class BlockListeners implements Listener {
int bx = block.getX();
int by = block.getY();
int bz = block.getZ();
for (int fx = -radius; fx <= radius; fx++) {
for (int fy = -2; fy <= 1; fy++) {
for (int fy = -2; fy <= 2; fy++) {
for (int fz = -radius; fz <= radius; fz++) {
Block b2 = block.getWorld().getBlockAt(bx + fx, by + fy, bz + fz);
if (b2.getType() == Material.valueOf(instance.getConfig().getString("Main.Farm Block Material"))) {

View File

@ -4,6 +4,7 @@ import com.songoda.epicfarming.EpicFarmingPlugin;
import com.songoda.epicfarming.api.farming.Farm;
import com.songoda.epicfarming.api.farming.FarmManager;
import com.songoda.epicfarming.farming.Crop;
import org.bukkit.Bukkit;
import org.bukkit.CropState;
import org.bukkit.Location;
import org.bukkit.Material;
@ -47,7 +48,7 @@ public class HopperTask extends BukkitRunnable {
Block block = farm.getLocation().getBlock();
if (block.getRelative(BlockFace.DOWN).getType() != Material.HOPPER)
return;
continue;
Inventory inventory = farm.getInventory();
Inventory hopperInventory = ((Hopper) block.getRelative(BlockFace.DOWN).getState()).getInventory();

View File

@ -1,7 +1,7 @@
name: EpicFarming
description: EpicFarming
main: com.songoda.epicfarming.EpicFarming
version: 1.4
version: 2
depend: [Arconix]
soft-depend: [Multiverse-Core]
author: Songoda