mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2025-06-28 03:34:43 +02:00
Clean up some of our messes.
This commit is contained in:
@ -13,9 +13,7 @@ import com.gmail.nossr50.util.Misc;
|
||||
import com.gmail.nossr50.util.skills.SkillUtils;
|
||||
|
||||
public class TeleportationWarmup extends BukkitRunnable {
|
||||
private static Player teleportingPlayer;
|
||||
private McMMOPlayer mcMMOPlayer;
|
||||
private static Player targetPlayer;
|
||||
private McMMOPlayer mcMMOTarget;
|
||||
|
||||
public TeleportationWarmup(McMMOPlayer mcMMOPlayer, McMMOPlayer mcMMOTarget) {
|
||||
@ -25,12 +23,8 @@ public class TeleportationWarmup extends BukkitRunnable {
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
checkPartyTeleport();
|
||||
}
|
||||
|
||||
private void checkPartyTeleport() {
|
||||
teleportingPlayer = mcMMOPlayer.getPlayer();
|
||||
targetPlayer = mcMMOTarget.getPlayer();
|
||||
Player teleportingPlayer = mcMMOPlayer.getPlayer();
|
||||
Player targetPlayer = mcMMOTarget.getPlayer();
|
||||
Location previousLocation = mcMMOPlayer.getTeleportCommenceLocation();
|
||||
Location newLocation = mcMMOPlayer.getPlayer().getLocation();
|
||||
long recentlyHurt = mcMMOPlayer.getRecentlyHurt();
|
||||
|
@ -17,7 +17,6 @@ public class AlchemyBrewCheckTask extends BukkitRunnable {
|
||||
private Player player;
|
||||
private Block brewingStand;
|
||||
private ItemStack[] oldInventory;
|
||||
private ItemStack[] newInventory;
|
||||
|
||||
public AlchemyBrewCheckTask(Player player, BrewingStand brewingStand) {
|
||||
this.player = player;
|
||||
@ -27,7 +26,7 @@ public class AlchemyBrewCheckTask extends BukkitRunnable {
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
this.newInventory = Arrays.copyOfRange(((BrewingStand) brewingStand.getState()).getInventory().getContents(), 0, 4);
|
||||
ItemStack[] newInventory = Arrays.copyOfRange(((BrewingStand) brewingStand.getState()).getInventory().getContents(), 0, 4);
|
||||
|
||||
if (Alchemy.brewingStandMap.containsKey(brewingStand)) {
|
||||
if (oldInventory[INGREDIENT_SLOT] == null || newInventory[INGREDIENT_SLOT] == null || !oldInventory[INGREDIENT_SLOT].isSimilar(newInventory[INGREDIENT_SLOT]) || !AlchemyPotionBrewer.isValidBrew(player, newInventory)) {
|
||||
|
@ -28,7 +28,7 @@ public class BleedTimerTask extends BukkitRunnable {
|
||||
continue;
|
||||
}
|
||||
|
||||
int damage = 0;
|
||||
int damage;
|
||||
|
||||
if (entity instanceof Player) {
|
||||
damage = 1;
|
||||
|
Reference in New Issue
Block a user