Понедельник, 29.04.2024, 16:19
Приветствую Вас Гость | RSS
Обитель неприкаянных душ
Главная | Каталог файлов | Регистрация | Вход
Меню сайта
Категории каталога
Скрипты [43]
Мини-чат
Главная » Файлы » Скрипты

БС с переплавкой
[ ] 30.10.2010, 10:04
VAR chest2 = '0x403A8377' #Основной сундук
VAR chest = '0x403A8377' #ID сундука с ингами
VAR forge = '0x4020D347' #ID форжи

VAR TypeFood = '0x097B' #Тип Еды
VAR ing = '0x1BEF' #Тип ингов

sub Blacksmith()

VAR i, m = 0
DIM cvet[5]
cvet[0] = '0x0000' #Iron
cvet[1] = '0x0750' #Rusty
cvet[2] = '0x0590' #Old Copper
cvet[3] = '0x060A' #Dull Copper
cvet[4] = '0x0488' #Bronze

uo.Exec('terminate Reconnector')
wait(1000)
uo.Exec('exec Reconnector')
wait(1000)
uo.useobject('backpack')
wait(1000)

UO.CancelMenu()
wait(200)

UO.UseObject(chest2)
wait(1000)
UO.UseObject(chest)
wait(1000)

while not UO.Dead()
for i = 0 to 4
MenuColor(i)
wait(2000)
UO.FindType(ing, cvet[i], chest)
While UO.GetQuantity('finditem') > 10
ChekLag()
UO.Grab('50', 'finditem')
wait(2000)
EatingFood()
ChekLag()
Blacksmithy(cvet[i], forge)
wait(500)
EatingFood()
wait(500)
cheklag()
UO.FindType(ing, cvet[i], chest)
wend
next
#UO.asmLogAdd('smelt.log', 'Ковка закончена ' + str(UO.asmGetDate('dd/mm/yy')) + ' в ' + str(UO.asmGetTime('hh:nn:ss')))
wait(100)
UO.Exec('terminate Blacksmith')
wend
#UO.asmLogAdd('smelt.log', 'Ковка закончена, тебя убили ' + str(UO.asmGetDate('dd/mm/yy')) + ' в ' + str(UO.asmGetTime('hh:nn:ss')))
wait(100)
UO.Exec('terminate Blacksmith')
endsub

Sub MenuColor(num)
If num == 0 then
uo.cancelmenu()
UO.AutoMenu('Blacksmithing','Weapons')
UO.AutoMenu('Weapons','Swords & Blades')
UO.AutoMenu('Swords & Blades','dagger')
wait(500)
else
uo.cancelmenu()
UO.AutoMenu('Blacksmithing','Colored Armor & Weapons')
UO.AutoMenu('Colored Armor & Weapons','Weapons')
UO.AutoMenu('Weapons','Swords & Blades')
UO.AutoMenu('Swords & Blades','Dagger')
wait(500)
end if
end sub

Sub Blacksmithy(ccvet, fforge)
VAR Exit=0, LastTimer
VAR skil
UO.FindType('0x1BEF', ccvet, 'backpack')
If UO.GetQuantity('finditem') >= 10 then
repeat
UO.DeleteJournal()
LastTimer=UO.Timer()
wait(500)
ChekLag()
ToHide()

UO.UseObject('finditem') ;Инги айрона

while NOT UO.InJournal("You put") AND NOT UO.InJournal("You have failed")
wait(100)
wend
wait(500)

If UO.InJournal("You have failed") then
repeat
wait(100)
until UO.Timer()>=LastTimer+100 ;Время создания дагера
EndIf

If UO.InJournal('You put') then
UO.FindType('0x0F51','-1','backpack') #Ищем Дагер
#UO.FindType('0x1B73',-1,'backpack') ## ищем щит
#UO.FindType('0x13E3',-1,'backpack') ##Хаммер
#UO.FindType('0x13FE','-1','backpack') #Ищем Катану
#UO.FindType('0x1404','-1','backpack') #Ищем Вилку
If UO.FindCount() > 0 then
repeat
wait(500)
UO.WaitTargetObject('finditem')
wait(1000)
UO.UseObject(fforge) ; Форж
wait(2000)
repeat
wait(100)
until UO.InJournal('You put') or UO.InJournal('It is consumed')
UO.DeleteJournal()
UO.FindType('0x0F51','-1','backpack') #Ищем Дагер
#UO.FindType('0x1B73',-1,'backpack') ## ищем щит
#UO.FindType('0x13E3',-1,'backpack') ##Хаммер
#UO.FindType('0x13FE','-1','backpack') #Ищем Катану
#UO.FindType('0x1404','-1','backpack') #Ищем Вилку
until not UO.FindCount()
else
wait(50)
endif
endif
UO.FindType('0x1BEF', ccvet, 'backpack')
wait(1000)

until UO.GetQuantity('finditem') < 10
endif
end sub

Sub EatingFood()
var Time,Space
Time=Time()
Space=' '
MovingItems(TypeFood,'-1',20,1)
repeat
ChekLag()
uo.UseType(TypeFood)
while not uo.InJournal('full') and not uo.InJournal('stuffed') and not uo.InJournal('hungry') and not uo.InJournal('satiated') and not uo.Dead()
wait(100)
wend
until uo.InJournal('too full') or uo.Dead()
MovingItems(TypeFood,'-1',-1,0)
end sub

Sub MovingItems(tItem,cItem,qItem,FromBackPack)
var idResivCont
var idSendCont
if FromBackPack==1 then
idResivCont=uo.GetSerial('backpack')
idSendCont=chest
else
idSendCont=uo.GetSerial('backpack')
idResivCont=chest
end if
ChekLag()
uo.FindType(tItem,cItem,idSendCont)
while uo.GetQuantity('finditem')>0
uo.MoveItem('finditem',qItem,idResivCont)
wait(1000)
ChekLag()
if qItem>0 then
return
end if
uo.FindType(tItem,cItem,idSendCont)
wend
end sub

Sub Time()
var hh,mm,ss,hms,t=str(uo.Time())
if len(t)<=2 then
hh="0"
mm="0"
ss=t
endif
if len(t)==3 then
hh="0"
mm=left(t,len(t)-2)
ss=right(t,len(t)-1)
endif
if len(t)==4 then
hh="0"
mm=left(t,len(t)-2)
ss=right(t,len(t)-2)
endif
if len(t)==5 then
hh=left(t,len(t)-4)
hms=left(t,len(t)-2)
mm=right(hms,len(hms)-1)
ss=right(t,len(t)-3)
endif
if len(t)==6 then
hh=left(t,len(t)-4)
hms=left(t,len(t)-2)
mm=right(hms,len(hms)-2)
ss=right(t,len(t)-4)
endif
return hh+":"+mm+":"+ss
end sub

Sub ToHide()
while not uo.hidden()
uo.exec("warmode 0")
uo.DeleteJournal()
uo.useskill("Hiding")
repeat
wait(10)
until uo.InJournal("You have hidden yourself well") or uo.InJournal("You can't seem to hide here.") or uo.InJournal("You are preoccupied with thoughts of battle.")
if uo.InJournal("You are preoccupied with thoughts of battle.") then
uo.exec("warmode 0")
end if
wend
end sub

Sub ChekLag()
if uo.Waiting()>0 then
uo.Exec('canceltarget')
end if
uo.DeleteJournal()
uo.Click('backpack')
repeat
wait(50)
until uo.InJournal('backpack')
end sub

Sub Reconnector()
var ReconnectTime, RFlag
ReconnectTime = '0'
RFlag = 1
Repeat
While (uo.ObjAtLayer('Bpack') == '')
if RFlag Then
ReconnectTime = MakeTime()
RFlag = 0
endif
Wait(70000) # WorldSave Protection
uo.Say('')
Wait(5000)
uo.Say('')
Wait(5000)
uo.Say('')
Wait(5000)
uo.LDblClick(357,164)
uo.LClick(616,459)
Wait(5000)
WEnd
Wait(3000)
if (RFlag == 0) and (ReconnectTime <> '0') Then
uo.TextOpen()
uo.TextPrint('Disconnected & Reconnected @ '+ReconnectTime)
uo.useobject('self')
wait(2000)
uo.useobject('backpack')
wait(2000)
uo.Exec('terminate Blacksmith')
wait(5000)
uo.Exec('exec Blacksmith')
wait(5000)
RFlag = 1
ReconnectTime = '0'
endif
Until false
end sub

Sub MakeTime()
VAR D, T, Ret, i
Ret = STR(uo.Time())
T = ""
For i = 0 To Len(Ret)
T = Ret[Len(Ret)-i] + T
If (I == 2) OR (I == 4) Then
T = ":" + T
EndIf
Next
Ret = STR(uo.Date())
D = ""
For i = 0 To Len(Ret)
D = Ret[Len(Ret)-i] + D
If (I == 2) OR (I == 4) Then
D = "." + D
EndIf
Next
Ret = T + " @ " + D
RETURN Ret
end sub

Sub ToHide()
while not uo.hidden()
uo.exec("warmode 0")
uo.DeleteJournal()
uo.useskill("Hiding")
repeat
wait(10)
until uo.InJournal("You have hidden yourself well") or uo.InJournal("You can't seem to hide here.") or uo.InJournal("You are preoccupied with thoughts of battle.")
if uo.InJournal("You are preoccupied with thoughts of battle.") then
uo.exec("warmode 0")
end if
wend
end sub

Категория: Скрипты | Добавил: BUDWAIZER
Просмотров: 1723 | Загрузок: 5
Всего комментариев: 0
Добавлять комментарии могут только зарегистрированные пользователи.
[ Регистрация | Вход ]
Форма входа
Поиск
Друзья сайта

    Статистика

    Онлайн всего: 1
    Гостей: 1
    Пользователей: 0

    Copyright MyCorp © 2024

    Бесплатный хостинг uCoz