Optimize even more things.

This commit is contained in:
GJ
2012-02-23 23:04:41 -05:00
parent 19ab8b89f5
commit bdb74d4719
5 changed files with 31 additions and 57 deletions

View File

@ -41,20 +41,14 @@ import org.getspout.spoutapi.sound.SoundEffect;
public class Excavation
{
public static void gigaDrillBreakerActivationCheck(Player player, Block block)
public static void gigaDrillBreakerActivationCheck(Player player)
{
PlayerProfile PP = Users.getProfile(player);
if(m.isShovel(player.getItemInHand()))
{
if(block != null)
{
if(!m.abilityBlockCheck(block))
return;
}
if(PP.getShovelPreparationMode())
{
PP.setShovelPreparationMode(false);
}
int ticks = 2;
int x = PP.getSkillLevel(SkillType.EXCAVATION);
while(x >= 50)

View File

@ -37,20 +37,13 @@ import com.gmail.nossr50.locale.mcLocale;
public class Herbalism
{
public static void greenTerraCheck(Player player, Block block)
public static void greenTerraCheck(Player player)
{
PlayerProfile PP = Users.getProfile(player);
if(m.isHoe(player.getItemInHand()))
{
if(block != null)
{
if(!m.abilityBlockCheck(block))
return;
}
if(PP.getHoePreparationMode())
{
PP.setHoePreparationMode(false);
}
int ticks = 2;
int x = PP.getSkillLevel(SkillType.HERBALISM);
while(x >= 50)

View File

@ -39,20 +39,13 @@ import com.gmail.nossr50.locale.mcLocale;
public class Mining
{
public static void superBreakerCheck(Player player, Block block)
public static void superBreakerCheck(Player player)
{
PlayerProfile PP = Users.getProfile(player);
if(m.isMiningPick(player.getItemInHand()))
{
if(block != null)
{
if(!m.abilityBlockCheck(block))
return;
}
if(PP.getPickaxePreparationMode())
{
PP.setPickaxePreparationMode(false);
}
int ticks = 2;
int x = PP.getSkillLevel(SkillType.MINING);

View File

@ -194,23 +194,16 @@ public class WoodCutting
}
}
public static void treeFellerCheck(Player player, Block block)
public static void treeFellerCheck(Player player)
{
PlayerProfile PP = Users.getProfile(player);
if(m.isAxes(player.getItemInHand()))
{
if(block != null)
{
if(!m.abilityBlockCheck(block))
return;
}
/*
* CHECK FOR AXE PREP MODE
*/
if(PP.getAxePreparationMode())
{
PP.setAxePreparationMode(false);
}
int ticks = 2;
int x = PP.getSkillLevel(SkillType.WOODCUTTING);