Code: Select all
Program New;
const	
	shovel = $0F39; 
	box_1 = $40311147;        //ingot_box
	box_2 = $401B777E;
	shovel_box_1 = $401EF50F;  //shovel_box
	shovel_box_2 = $4070BC0D;   
	ingot = $1BF2;
	tinker_tool = $1EB8;
var 
	shovel_box : integer;
	box : integer;
begin
	repeat
	movexy(1202,1545,true,0,false);
	shovel_box := shovel_box_1;
	box := box_1;
	MakeShovel;
	movexy(1202,1528,true,0,false);
	shovel_box := shovel_box_2;
	box := box_2;
	MakeShovel;
             until Dead;
end.
procedure MakeShovel;
begin
     
        findtype(shovel,backpack);     
        if findcount > 10 then
        repeat
            findtype(shovel,backpack);     
            moveitem(finditem, 1, shovel_box, 0,0,0 ); 
            wait(500);
        until findcount = 0 ;   
       
        findtype(ingot ,backpack);  
        if FindQuantity < 10 then
            begin   
                useobject(box);    
                wait(1000);
                useobject(shovel_box);
                FindTypeEx(ingot,$0000,box,false);  
                grab(finditem,100);
            end;  
     
        findtype(tinker_tool ,backpack);      
        //addtosystemjournal(inttostr(findcount));
        if findcount < 3 then  
            begin              
                findtype(tinker_tool ,box); 
                if findcount < 3 then
                    begin     
                    findtype(tinker_tool ,backpack)
                    UseObject(finditem); 
                    wait(500); 
                    numgumpbutton(getgumpscount-1,8);
                    wait(500);
                    NumGumpButton(getgumpscount-1,23);   //make tinker_tool
                    wait(1000); 
                    end;
                if findcount >= 3 then
                    begin
                    grab(finditem,1);
                    end;
            end;     
        
        UseObject(finditem); 
        wait(500); 
        numgumpbutton(getgumpscount-1,8);
        wait(500);
        NumGumpButton(getgumpscount-1,72);   //make shovel  
        wait(1000);                            
 
        if not hidden then
            useskill('hiding');
  
        repeat
        	findtype(shovel,shovel_box); 
        	if findcount = 0 then
           	   useobject(box);
        	if findcount > 150 then
           	   wait(1000);
        	wait(1000); 
        until findcount >= 140
  
    
end;


