Code: Select all
Program Inscription;
var
i: Integer;
t: Integer;
a: Integer;
b: Integer;
c: Integer;
blanku: cardinal;
knura: cardinal;
regs : Array[1..3] of word;
stime :TDateTime;
{$Include 'all.inc'}
procedure checkregs;
begin
If Connected then begin
for i:= 1 to 3 do
begin
FindDistance:=1;
waitconnection(3000);
Findtype (regs[i],backpack);
If (FindCount=0) then begin
Findtype(regs[i],ground);
If (FindCount>0) then begin Grab(finditem,30);
wait(700)
CheckSave;
end
else
begin
AddToSystemJournal('Не нашел регов, перезаходим!');
Disconnect;
waitconnection(3000);
wait(7000);
end;
end
end
end
end;
procedure pucovka;
begin
{==================================}
blanku:=$692E9AA7;
knura:=$6BA66622;
{==================================}
If (Mana>=50) then begin
stime := Now;
CheckTargetError(2, 2);
WaitTargetObject(blanku);
AutoMenu('circle','8');
AutoMenu('spell','Resurrection');
CheckSave;
UseSkill('Inscription');
repeat
CheckSave;
a := InJournalBetweenTimes('spellbook', stime, Now);
b := InJournalBetweenTimes('already|perform|You can''t inscribe', stime, Now);
c := InJournalBetweenTimes('you do not have all of this spell''s reagents', stime, Now);
wait(100);
until (a >= 0) or (b >= 0) or (c >= 0) or (Now > stime + (1.0/1440));
if (b >= 0) or (c >= 0) then Exit;
stime := Now;
CheckTargetError(2, 2);
WaitTargetObject(knura);
repeat
CheckSave;
InJournalBetweenTimes('create|fail|reach|already|perform', stime, Now);
wait(100);
until (LineCount > 0) or (Now > stime + (1.0/1440));
end
end;
Begin
ClearJournal;
SetARStatus(true);
regs[1]:=$0F7B;
regs[2]:=$0F85;
regs[3]:=$0F84;
FindDistance:=1;
While not Dead do
begin
//waitconnection(3000);
If Connected then begin
For t:= 1 to 5 do begin
checkregs;
wait(200);
stime:=Now;
pucovka;
begin
If (Mana<=43) then begin
wait(1000);
While (Mana<Int) do begin
Useskill('Meditation');
repeat
InJournalBetweenTimes('Your mana is full|You lose|You cant focus', stime, Now);
wait(500);
until (LineCount >= 1) or (Now > stime + (1.0/1440));
Hungry(1,ground);
stack($1F67,$0000);
end
If (InJournalBetweenTimes('Your mana is full',stime,now)>=0) then
pucovka; end
else
begin
pucovka;
end
end
end
Hungry(1,ground);
t:=1;
end
wait(2000);
end
End.