/* MephistBot Script Written by Sheppard ToDo List: - Stashing */ include("Helper.d2l"); include("SnagIt.d2l"); function Precast() { // Call to Arms oldweap = me.weaponswitch; while(oldweap==me.weaponswitch) { switchweapon(); sleep(350); } if(me.getSkill(155)) { me.setSkill(155,1); clickMap(3,me.x,me.y,8); WaitTillReady(); } if(me.getSkill(149)) { me.setSkill(149,1); clickMap(3,me.x,me.y,8); WaitTillReady(); } oldweap = me.weaponswitch; while(oldweap==me.weaponswitch) { switchweapon(); sleep(350); } // We Have ES? //if(me.getSkill(58)) { // me.setSkill(58,1); // clickMap(3,me.x,me.y,8); WaitTillReady(); //} } function main() { var file = fileOpen("scripts/libs/Mephbot/Config/MB_Config_" + me.name + ".d2l",0); if(file) { include("Mephbot/Config/MB_Config_" + me.name + ".d2l"); file.close(); } else { print("ÿc1Character config file not found! "); print("ÿc1Creating default config..."); var templateFile = fileOpen("scripts/libs/Mephbot/Config_Template.d2l", 0); var newCharFile = fileOpen("scripts/libs/Mephbot/Config/MB_Config_" + me.name + ".d2l",1); print(templateFile.eof); while(!templateFile.eof) { var _line = templateFile.readLine(); newCharFile.writeLine(_line); } newCharFile.close(); templateFile.close(); print("ÿc2Please set up the following file: libs/Mephbot/Config/MB_Config_" + me.name + ".d2l"); return; } load("tools/Chicken.d2l"); // Check if A3 if(me.act!=3) { print("Error: We are not in A3 :<"); return FALSE; } // From start to WP MoveTo(5131,5166); MoveTo(5132,5160); MoveTo(5133,5139); MoveTo(5133,5115); MoveTo(5133,5097); MoveTo(5147,5094); MoveTo(5148,5075); MoveTo(5158,5055); sleep(100); // Take WP :> WP = getUnit(2,"Waypoint") if(!WP) { print("Error: Can't take WP :<"); return FALSE; } WP.interact(101); // Take WP to Durance Level 2 sleep(1000); Precast(); sleep(100); path.DefinePathList("67/68,-1"); path.StartTeleport(); sleep(500); TeleportTo(17686,8040); TeleportTo(17659,8037); TeleportTo(17656,8059); TeleportTo(17637,8067); TeleportTo(17619,8071); TeleportTo(17609,8086); TeleportTo(17586,8081); TeleportTo(17568,8074); print("ÿc4",me.name,"ÿc0: I'm here to Slay you Mephisto!"); Mephisto = getUnit(1,"Mephisto"); print("** Mephisto Life ",Mephisto.hp,"/",Mephisto.hpmax); print("** Attacking Mephisto!"); while(Mephisto.hp!=0) { AttackTo(Mephisto.x,Mephisto.y,MB_AttackSkill); sleep(100); } print("** Mephisto got pwnd!"); TeleportTo(Mephisto.x,Mephisto.y); print("Snagged Items: ",SnagItems(15)); delay(500); quit(); }