mirror of
https://github.com/songoda/FabledSkyBlock.git
synced 2024-11-22 10:15:54 +01:00
Added support for EpicSpawners 7.
This commit is contained in:
parent
ca8a314656
commit
c74ce51fee
2
pom.xml
2
pom.xml
@ -206,7 +206,7 @@
|
||||
<dependency>
|
||||
<groupId>com.songoda</groupId>
|
||||
<artifactId>epicspawners</artifactId>
|
||||
<version>6-pre4</version>
|
||||
<version>7.0.1</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
|
@ -22,11 +22,9 @@ import org.bukkit.block.BlockFace;
|
||||
import org.bukkit.block.CreatureSpawner;
|
||||
import org.bukkit.configuration.Configuration;
|
||||
import org.bukkit.configuration.ConfigurationSection;
|
||||
import org.bukkit.configuration.file.FileConfiguration;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.plugin.PluginManager;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.*;
|
||||
import java.util.Map.Entry;
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
package com.songoda.skyblock.levelling.calculator.impl;
|
||||
|
||||
import com.songoda.epicspawners.EpicSpawners;
|
||||
import com.songoda.epicspawners.spawners.spawner.Spawner;
|
||||
import com.songoda.epicspawners.spawners.spawner.PlacedSpawner;
|
||||
import com.songoda.skyblock.levelling.calculator.SpawnerCalculator;
|
||||
import org.bukkit.block.CreatureSpawner;
|
||||
|
||||
@ -9,8 +9,8 @@ public class EpicSpawnerCalculator implements SpawnerCalculator {
|
||||
|
||||
@Override
|
||||
public long getSpawnerAmount(CreatureSpawner spawner) {
|
||||
final Spawner epic = EpicSpawners.getInstance().getSpawnerManager().getSpawnerFromWorld(spawner.getLocation());
|
||||
return epic == null ? 0 : epic.getFirstStack().getStackSize();
|
||||
final PlacedSpawner epic = EpicSpawners.getInstance().getSpawnerManager().getSpawnerFromWorld(spawner.getLocation());
|
||||
return epic.getStackSize();
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -39,7 +39,7 @@ public class EpicSpawners implements Listener {
|
||||
|
||||
Island island = islandManager.getIslandAtLocation(location);
|
||||
|
||||
int amount = event.getSpawner().getFirstStack().getStackSize();
|
||||
int amount = event.getSpawner().getStackSize();
|
||||
EntityType spawnerType = event.getSpawner().getCreatureSpawner().getSpawnedType();
|
||||
|
||||
FileConfiguration configLoad = plugin.getConfiguration();
|
||||
@ -107,7 +107,7 @@ public class EpicSpawners implements Listener {
|
||||
|
||||
Island island = islandManager.getIslandAtLocation(location);
|
||||
|
||||
int amount = event.getSpawner().getFirstStack().getStackSize();
|
||||
int amount = event.getSpawner().getStackSize();
|
||||
EntityType spawnerType = event.getSpawner().getCreatureSpawner().getSpawnedType();
|
||||
|
||||
FileConfiguration configLoad = plugin.getConfiguration();
|
||||
|
Loading…
Reference in New Issue
Block a user