var repair = 15; var damageGet = 1; var itemID = 278; var maxDamage = 1560;
var power = 9+Math.sqrt(mining_lvl*4); var breakSpeech = "I can't believe I didn't noticed that!!";
var tool = [15, 15, 15, 15, 6, 95, 5]; itemUsed = true; mainSkill = mining_lvl;

if (pinv.getCurrentItem() != null)
{if (pinv.getCurrentItem().itemID == itemID) {var ent = pinv.getCurrentItem(); player.swingMainHand();}}
if (pinv.getOffhandItem() != null) 
{if (pinv.getOffhandItem().itemID == itemID) {var ent = pinv.getOffhandItem(); player.swingOffHand();}}

if (hitBlock != null) {time.sleep(0.05);
script.runScript("destructable blocks.js");}