Remove unused fields, imports, warning suppressions.

Just a bit of spring cleaning!
This commit is contained in:
Andreas Troelsen 2020-04-09 11:31:46 +02:00
parent 299a16ca8c
commit c9b0f85bee
4 changed files with 1 additions and 19 deletions

View File

@ -859,7 +859,6 @@ public class ArenaImpl implements Arena
}
@Override
@SuppressWarnings("deprecation")
public void revivePlayer(Player p) {
removePermissionAttachments(p);
removePotionEffects(p);

View File

@ -264,10 +264,6 @@ public class MobArena extends JavaPlugin
return lastFailureCause;
}
public File getPluginFile() {
return getFile();
}
@Override
public FileConfiguration getConfig() {
if (config == null) {

View File

@ -5,7 +5,6 @@ import com.garbagemule.MobArena.things.Thing;
import org.bukkit.entity.Player;
import java.util.ArrayList;
import java.util.Collections;
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
@ -14,16 +13,10 @@ import java.util.Set;
public class RewardManager
{
@SuppressWarnings("unused")
private MobArena plugin;
@SuppressWarnings("unused")
private Arena arena;
private Map<Player,List<Thing>> players;
private Set<Player> rewarded;
public RewardManager(Arena arena) {
this.plugin = arena.getPlugin();
this.arena = arena;
this.players = new HashMap<>();
this.rewarded = new HashSet<>();
}
@ -39,12 +32,7 @@ public class RewardManager
}
players.get(p).add(thing);
}
public List<Thing> getRewards(Player p) {
List<Thing> rewards = players.get(p);
return (rewards == null ? new ArrayList<>(1) : Collections.unmodifiableList(rewards));
}
public void grantRewards(Player p) {
if (rewarded.contains(p)) return;

View File

@ -1,6 +1,5 @@
package com.garbagemule.MobArena.util.config;
import com.garbagemule.MobArena.ConfigError;
import org.bukkit.Bukkit;
import org.bukkit.Location;
import org.bukkit.World;