Merge branch 'development'

This commit is contained in:
Fernando Pettinelli 2021-01-08 15:24:21 -03:00
commit c1f5fc1ea1
4 changed files with 7 additions and 9 deletions

View File

@ -5,7 +5,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>com.songoda</groupId>
<artifactId>skyblock</artifactId>
<version>2.3.22</version>
<version>2.3.23</version>
<packaging>jar</packaging>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
@ -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>

View File

@ -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;

View File

@ -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();
}
}

View File

@ -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();